10Duke Scale C++ Client
Loading...
Searching...
No Matches
tenduke::http::HTTPRequestAuthenticator Class Referenceabstract

#include <HTTPRequestAuthenticator.h>

Detailed Description

This is a service, that can be added to tenduke::http::HTTPRequest to add authentication information to the request.

Typically this service adds "Authorization"-header with the authentication credentials.

You can get the same effect simply by adding headers to the request manually, but this service makes it possible to dynamically change the credentials at the execution time. For example, the service could refresh expired OAuth access token before executing the HTTP-request.

IMPLEMENTATION NOTE: The header(s) added by the authenticator will be added to the request first.

Inheritance diagram for tenduke::http::HTTPRequestAuthenticator:
tenduke::oauth::AccessTokenRequestAuthenticator tenduke::oidc::IdTokenSessionRequestAuthenticator tenduke::oidc::OIDCSessionRequestAuthenticator tenduke::test::mocks::HTTPRequestAuthenticatorMock

Public Member Functions

virtual std::multimap< std::string, std::string > authenticate (const tenduke::http::HTTPRequest &request) const =0
 Returns headers to authenticate the request.
 

Member Function Documentation

◆ authenticate()

virtual std::multimap< std::string, std::string > tenduke::http::HTTPRequestAuthenticator::authenticate ( const tenduke::http::HTTPRequest request) const
pure virtual

Returns headers to authenticate the request.

Parameters
request-
Returns
-

Implemented in tenduke::oauth::AccessTokenRequestAuthenticator, tenduke::oidc::IdTokenSessionRequestAuthenticator, and tenduke::oidc::OIDCSessionRequestAuthenticator.


The documentation for this class was generated from the following file: