Module io.inverno.mod.security.http
Class BasicSessionCredentialsExtractor<A extends Authentication,B extends AuthSessionData<A>,C extends BasicSessionContext<B>,D extends Exchange<C>>
java.lang.Object
io.inverno.mod.security.http.session.BasicSessionCredentialsExtractor<A,B,C,D>
- Type Parameters:
A
- the authentication typeB
- the authentication session data typeC
- the basic session context typeD
- the exchange type
- All Implemented Interfaces:
CredentialsExtractor<SessionCredentials<A>,
C, D>
public class BasicSessionCredentialsExtractor<A extends Authentication,B extends AuthSessionData<A>,C extends BasicSessionContext<B>,D extends Exchange<C>>
extends Object
implements CredentialsExtractor<SessionCredentials<A>,C,D>
A credentials extractor that extracts session credentials from a basic session.
This basically looks for the Authentication
stored in an AuthSessionData
and returns a SessionCredentials
containing the authentication. The session data type must then
implement AuthSessionData
for the extractor to be able to resolve the authentication from the session.
- Since:
- 1.13
- Author:
- Jeremy Kuhn
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionExtracts credentials from the specified exchange.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.inverno.mod.security.http.CredentialsExtractor
or
-
Constructor Details
-
BasicSessionCredentialsExtractor
public BasicSessionCredentialsExtractor()
-
-
Method Details
-
extract
Description copied from interface:CredentialsExtractor
Extracts credentials from the specified exchange.
- Specified by:
extract
in interfaceCredentialsExtractor<A extends Authentication,
B extends AuthSessionData<A>, C extends BasicSessionContext<B>> - Parameters:
exchange
- the exchange- Returns:
- a mono emitting the credentials or an empty mono if the exchange didn't provide any credentials
- Throws:
MalformedCredentialsException
- if credentials in the exchange are malformed
-