[−][src]Trait parsec_service::authenticators::Authenticate
Authentication interface
Interface that must be implemented for each authentication type available for the service.
Required methods
fn describe(&self) -> Result<AuthenticatorInfo>
Return a description of the authenticator.
The descriptions are gathered in the Core Provider and returned for a ListAuthenticators operation.
fn authenticate(
&self,
auth: &RequestAuth,
meta: Option<ConnectionMetadata>
) -> Result<ApplicationName>
&self,
auth: &RequestAuth,
meta: Option<ConnectionMetadata>
) -> Result<ApplicationName>
Authenticates a RequestAuth payload and returns the ApplicationName if successful. A
optional ConnectionMetadata object is passed in too, since it is sometimes possible to
perform authentication based on the connection's metadata (i.e. as is the case for UNIX
domain sockets with Unix peer credentials).
Errors
If the authentification fails, returns a ResponseStatus::AuthenticationError.
Implementors
impl Authenticate for DirectAuthenticator[src]
fn describe(&self) -> Result<AuthenticatorInfo>[src]
fn authenticate(
&self,
auth: &RequestAuth,
_: Option<ConnectionMetadata>
) -> Result<ApplicationName>[src]
&self,
auth: &RequestAuth,
_: Option<ConnectionMetadata>
) -> Result<ApplicationName>
impl Authenticate for UnixPeerCredentialsAuthenticator[src]
fn describe(&self) -> Result<AuthenticatorInfo>[src]
fn authenticate(
&self,
auth: &RequestAuth,
meta: Option<ConnectionMetadata>
) -> Result<ApplicationName>[src]
&self,
auth: &RequestAuth,
meta: Option<ConnectionMetadata>
) -> Result<ApplicationName>