Vapor Documentation Beta

Protocol Authenticator

public protocol Authenticator: Middleware

Helper for creating authentication middleware.

See RequestAuthenticator and SessionAuthenticator for more information.

%3 Authenticator Authenticator Middleware Middleware Authenticator->Middleware RequestAuthenticator RequestAuthenticator RequestAuthenticator->Authenticator SessionAuthenticator SessionAuthenticator SessionAuthenticator->Authenticator

Conforms To

Middleware

Middleware is placed between the server and your router. It is capable of mutating both incoming requests and outgoing responses. Middleware can choose to pass requests on to the next Middleware in a chain, or they can short circuit and return a custom Response if desired.

Types Conforming to Authenticator

RequestAuthenticator

Help for creating authentication middleware based on Request.

SessionAuthenticator

Helper for creating authentication middleware in conjunction with SessionsMiddleware.