E-MailRelay
Public Member Functions | List of all members
GAuth::SaslServerSecrets Class Referenceabstract

An interface used by GAuth::SaslServer to obtain authentication secrets. More...

#include <gsaslserversecrets.h>

+ Inheritance diagram for GAuth::SaslServerSecrets:

Public Member Functions

virtual ~SaslServerSecrets ()=default
 Destructor.
 
virtual bool valid () const =0
 Returns true if the secrets are valid.
 
virtual Secret serverSecret (std::string_view type, std::string_view id) const =0
 Returns the server secret for the given client id. More...
 
virtual std::pair< std::string, std::string > serverTrust (const std::string &address_range) const =0
 Returns a non-empty trustee name if the server trusts the given address range (eg. More...
 
virtual std::string source () const =0
 Returns the source identifier (eg. file name).
 
virtual bool contains (std::string_view type, std::string_view id) const =0
 Returns true if there is a secret of the given type either for one user in particular or for any user if the id is empty.
 

Detailed Description

An interface used by GAuth::SaslServer to obtain authentication secrets.

See also
GAuth::Secret

Definition at line 39 of file gsaslserversecrets.h.

Member Function Documentation

◆ serverSecret()

virtual Secret GAuth::SaslServerSecrets::serverSecret ( std::string_view  type,
std::string_view  id 
) const
pure virtual

Returns the server secret for the given client id.

The type is "plain" or the CRAM hash algorithm. Returns an invalid secret if not found.

◆ serverTrust()

virtual std::pair< std::string, std::string > GAuth::SaslServerSecrets::serverTrust ( const std::string &  address_range) const
pure virtual

Returns a non-empty trustee name if the server trusts the given address range (eg.

"192.168.0.0/24"), together with context information for logging purposes.


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