Class Authenticator
- java.lang.Object
-
- io.micronaut.security.authentication.Authenticator
-
@Singleton public class Authenticator extends java.lang.ObjectAn Authenticator operates on severalAuthenticationProviderinstances returning the first authenticatedAuthenticationResponse.- Since:
- 1.0
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Collection<AuthenticationProvider>authenticationProviders
-
Constructor Summary
Constructors Constructor Description Authenticator(java.util.Collection<AuthenticationProvider> authenticationProviders, SecurityConfiguration securityConfiguration)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.reactivestreams.Publisher<AuthenticationResponse>authenticate(io.micronaut.http.HttpRequest<?> request, AuthenticationRequest<?,?> authenticationRequest)Authenticates the user with the provided credentials.
-
-
-
Field Detail
-
authenticationProviders
protected final java.util.Collection<AuthenticationProvider> authenticationProviders
-
-
Constructor Detail
-
Authenticator
public Authenticator(java.util.Collection<AuthenticationProvider> authenticationProviders, SecurityConfiguration securityConfiguration)
- Parameters:
authenticationProviders- A list of available authentication providerssecurityConfiguration- The security configuration
-
-
Method Detail
-
authenticate
public org.reactivestreams.Publisher<AuthenticationResponse> authenticate(io.micronaut.http.HttpRequest<?> request, AuthenticationRequest<?,?> authenticationRequest)
Authenticates the user with the provided credentials.- Parameters:
request- The HTTP requestauthenticationRequest- Represents a request to authenticate.- Returns:
- A publisher that emits
AuthenticationResponseobjects
-
-