public interface IuSamlSessionVerifier
SAML session verifier interface
-
Method Summary
Modifier and TypeMethodDescriptionstatic IuSamlSessionVerifier
Creates a newIuSamlSessionVerifier
for managing interactions with a locally deployed Service Provider.getPrincipalIdentity
(IuSession preAuthSession, IuSession postAuthSession) Gets the authenticated SAML principal.initRequest
(IuSession session, URI returnUri) Initiate request using session and return LocationURI
for the configured Identity Provider with the appropriate SAMLSAMLRequest
andRelayState
HTTP query parameters.verifyResponse
(IuSession session, String remoteAddr, String samlResponse, String relayState) Decodes a SAML Response, performs Subject Confirmation validation logic, and validates assertions to authenticate aIuPrincipalIdentity
as valid for the local Service Provider.
-
Method Details
-
create
Creates a newIuSamlSessionVerifier
for managing interactions with a locally deployed Service Provider.- Parameters:
postUri
- HTTP POST Binding URI- Returns:
IuSamlSessionVerifier
-
initRequest
Initiate request using session and return LocationURI
for the configured Identity Provider with the appropriate SAMLSAMLRequest
andRelayState
HTTP query parameters.- Parameters:
session
- sessionreturnUri
- return URI- Returns:
URI
-
verifyResponse
URI verifyResponse(IuSession session, String remoteAddr, String samlResponse, String relayState) throws IuAuthenticationException Decodes a SAML Response, performs Subject Confirmation validation logic, and validates assertions to authenticate aIuPrincipalIdentity
as valid for the local Service Provider.- Parameters:
session
- sessionremoteAddr
- IP address to validate against allowed listsamlResponse
- SAML response that received back from identity provider after user has been authenticaterelayState
- state value that received back from identity provider after successful authentication.- Returns:
- returnUri from related
initRequest(IuSession, URI)
- Throws:
IuAuthenticationException
- when relay state is invalid or verification failed
-
getPrincipalIdentity
IuPrincipalIdentity getPrincipalIdentity(IuSession preAuthSession, IuSession postAuthSession) throws IuAuthenticationException Gets the authenticated SAML principal.- Parameters:
preAuthSession
- session used withverifyResponse(IuSession, String, String, String)
; null if authentication handshake is already completepostAuthSession
- session to bind principal attributes after completing authentication handshake- Returns:
IuPrincipalIdentity
; will include at least oneIuSamlAssertion
in itssubject's
public credentials
.- Throws:
IuAuthenticationException
- If not authenticated or authentication has expired
-