Class RemoteAuthenticationContextManagement<T extends RemoteAuthnState>
- java.lang.Object
-
- pl.edu.icm.unity.engine.api.authn.remote.RemoteAuthenticationContextManagement<T>
-
public class RemoteAuthenticationContextManagement<T extends RemoteAuthnState> extends java.lang.Object
Maintains a map of remote authentication contexts matched by some string key. The contexts are matched by the random relay state. The in-memory store of contexts is purged, so the stale contexts are automatically removed after a timeout.This class is not anyhow persisted, so after restart all information is lost. This is intended.
Naturally this class is thread safe.
- Author:
- K. Benedyczak
-
-
Field Summary
Fields Modifier and Type Field Description static long
CLEANUP_INTERVAL
static long
MAX_TTL
-
Constructor Summary
Constructors Constructor Description RemoteAuthenticationContextManagement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAuthnContext(T context)
T
getAuthnContext(java.lang.String relayState)
void
removeAuthnContext(java.lang.String relayState)
-
-
-
Field Detail
-
MAX_TTL
public static final long MAX_TTL
- See Also:
- Constant Field Values
-
CLEANUP_INTERVAL
public static final long CLEANUP_INTERVAL
- See Also:
- Constant Field Values
-
-
Method Detail
-
addAuthnContext
public void addAuthnContext(T context)
-
getAuthnContext
public T getAuthnContext(java.lang.String relayState) throws pl.edu.icm.unity.exceptions.WrongArgumentException
- Throws:
pl.edu.icm.unity.exceptions.WrongArgumentException
-
removeAuthnContext
public void removeAuthnContext(java.lang.String relayState)
-
-