Class IdpHandler
java.lang.Object
org.codice.ddf.security.idp.client.IdpHandler
- All Implemented Interfaces:
org.codice.ddf.security.handler.api.AuthenticationHandler
public class IdpHandler
extends Object
implements org.codice.ddf.security.handler.api.AuthenticationHandler
Handler for SAML 2.0 IdP based authentication. Unauthenticated clients will be redirected to the
configured IdP for authentication.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringIdP type to use when configuring context policy.static final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringfinal Stringfinal Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Constructor Summary
ConstructorsConstructorDescriptionIdpHandler(ddf.security.samlp.impl.SimpleSign simpleSign, IdpMetadata metadata, ddf.security.samlp.impl.RelayStates<String> relayStates) -
Method Summary
Modifier and TypeMethodDescriptionorg.codice.ddf.security.handler.api.HandlerResultgetNormalizedToken(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, org.codice.ddf.platform.filter.SecurityFilterChain chain, boolean resolve) Handler implementing SAML 2.0 IdP authentication.org.codice.ddf.security.handler.api.HandlerResulthandleError(javax.servlet.ServletRequest servletRequest, javax.servlet.ServletResponse servletResponse, org.codice.ddf.platform.filter.SecurityFilterChain chain) voidsetAuthContextClasses(List<String> authContextClasses) voidsetSamlSecurity(org.codice.ddf.security.jaxrs.SamlSecurity samlSecurity) voidsetSecurityLogger(ddf.security.audit.SecurityLogger securityLogger) voidsetUserAgentCheck(boolean userAgentCheck)
-
Field Details
-
AUTH_TYPE
IdP type to use when configuring context policy.- See Also:
-
SOURCE
- See Also:
-
UNABLE_TO_ENCODE_SAML_AUTHN_REQUEST
- See Also:
-
UNABLE_TO_SIGN_SAML_AUTHN_REQUEST
- See Also:
-
PAOS
- See Also:
-
PAOS_MIME
- See Also:
-
PAOS_NS
- See Also:
-
ECP_NS
- See Also:
-
HTTPS
- See Also:
-
SAML_REQUEST
- See Also:
-
PAOS_REQUEST
- See Also:
-
PAOS_RESPONSE
- See Also:
-
ECP_REQUEST
- See Also:
-
ECP_RELAY_STATE
- See Also:
-
HTTP_SCHEMAS_XMLSOAP_ORG_SOAP_ACTOR_NEXT
- See Also:
-
TLS_SERVER_END_POINT
- See Also:
-
soapMessageTemplate
-
soapfaultMessageTemplate
-
-
Constructor Details
-
IdpHandler
public IdpHandler(ddf.security.samlp.impl.SimpleSign simpleSign, IdpMetadata metadata, ddf.security.samlp.impl.RelayStates<String> relayStates) throws IOException - Throws:
IOException
-
-
Method Details
-
getAuthenticationType
- Specified by:
getAuthenticationTypein interfaceorg.codice.ddf.security.handler.api.AuthenticationHandler
-
getNormalizedToken
public org.codice.ddf.security.handler.api.HandlerResult getNormalizedToken(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, org.codice.ddf.platform.filter.SecurityFilterChain chain, boolean resolve) throws org.codice.ddf.platform.filter.AuthenticationFailureException Handler implementing SAML 2.0 IdP authentication. Supports HTTP-Redirect and HTTP-POST bindings.- Specified by:
getNormalizedTokenin interfaceorg.codice.ddf.security.handler.api.AuthenticationHandler- Parameters:
request- http request to obtain attributes from and to pass into any local filter chains requiredresponse- http response to return http responses or redirectschain- original filter chain (should not be called from your handler)resolve- flag with true implying that credentials should be obtained, false implying return if no credentials are found.- Returns:
- result of handling this request - status and optional tokens
- Throws:
org.codice.ddf.platform.filter.AuthenticationFailureException
-
handleError
public org.codice.ddf.security.handler.api.HandlerResult handleError(javax.servlet.ServletRequest servletRequest, javax.servlet.ServletResponse servletResponse, org.codice.ddf.platform.filter.SecurityFilterChain chain) throws org.codice.ddf.platform.filter.AuthenticationFailureException - Specified by:
handleErrorin interfaceorg.codice.ddf.security.handler.api.AuthenticationHandler- Throws:
org.codice.ddf.platform.filter.AuthenticationFailureException
-
setUserAgentCheck
public void setUserAgentCheck(boolean userAgentCheck) -
getAuthContextClasses
-
setAuthContextClasses
-
setSamlSecurity
public void setSamlSecurity(org.codice.ddf.security.jaxrs.SamlSecurity samlSecurity) -
setSecurityLogger
public void setSecurityLogger(ddf.security.audit.SecurityLogger securityLogger)
-