MySQL 8.0.39
Source Code Documentation
HttpAuthChallenge Class Reference

Authentication Challenge. More...

#include <http_auth.h>

Public Member Functions

 HttpAuthChallenge (const std::string &scheme, const std::string &token, const std::vector< std::pair< std::string, std::string > > params)
 construct challenge message. More...
 
std::string str () const
 convert challenge message to payload of WWW-Authenticate. More...
 
std::string scheme () const
 authentication scheme. More...
 
std::string token () const
 token of the challenge message. More...
 
std::vector< std::pair< std::string, std::string > > params ()
 parameters of the challenge message. More...
 

Private Attributes

std::string scheme_
 
std::string token_
 
std::vector< std::pair< std::string, std::string > > params_
 

Detailed Description

Authentication Challenge.

sent by server to client when it asks client to authenticate.

payload of the WWW-Authenticate header.

See also
https://tools.ietf.org/html/rfc7235#section-4.1

Constructor & Destructor Documentation

◆ HttpAuthChallenge()

HttpAuthChallenge::HttpAuthChallenge ( const std::string &  scheme,
const std::string &  token,
const std::vector< std::pair< std::string, std::string > >  params 
)
inline

construct challenge message.

Member Function Documentation

◆ params()

std::vector< std::pair< std::string, std::string > > HttpAuthChallenge::params ( )
inline

parameters of the challenge message.

e.g.: realm="secret"

◆ scheme()

std::string HttpAuthChallenge::scheme ( ) const
inline

authentication scheme.

e.g.: Basic

◆ str()

std::string HttpAuthChallenge::str ( ) const

convert challenge message to payload of WWW-Authenticate.

Returns
{scheme} {token} {params}

◆ token()

std::string HttpAuthChallenge::token ( ) const
inline

token of the challenge message.

Note
valid according to RFC 7235, but usually unused.

Member Data Documentation

◆ params_

std::vector<std::pair<std::string, std::string> > HttpAuthChallenge::params_
private

◆ scheme_

std::string HttpAuthChallenge::scheme_
private

◆ token_

std::string HttpAuthChallenge::token_
private

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