Class SAML2SP4UIServiceImpl
- java.lang.Object
-
- org.apache.syncope.core.rest.cxf.service.AbstractService
-
- org.apache.syncope.core.rest.cxf.service.SAML2SP4UIServiceImpl
-
- All Implemented Interfaces:
JAXRSService,SAML2SP4UIService
@Service public class SAML2SP4UIServiceImpl extends AbstractService implements SAML2SP4UIService
-
-
Field Summary
Fields Modifier and Type Field Description protected SAML2SP4UILogiclogic-
Fields inherited from class org.apache.syncope.core.rest.cxf.service.AbstractService
LOG, messageContext, OPTIONS_ALLOW, searchContext, uriInfo
-
Fields inherited from interface org.apache.syncope.common.rest.api.service.JAXRSService
CRLF, DOUBLE_DASH, PARAM_ANYTYPE_KIND, PARAM_ANYTYPEKEY, PARAM_CONNID_PAGED_RESULTS_COOKIE, PARAM_DETAILS, PARAM_ENTITY_KEY, PARAM_FIQL, PARAM_KEYWORD, PARAM_MAX, PARAM_NOTIFICATION, PARAM_ORDERBY, PARAM_PAGE, PARAM_REALM, PARAM_RECURSIVE, PARAM_RESOURCE, PARAM_SIZE, PARAM_USER
-
-
Constructor Summary
Constructors Constructor Description SAML2SP4UIServiceImpl(SAML2SP4UILogic logic)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SAML2RequestcreateLoginRequest(String spEntityID, String urlContext, String idpEntityID, boolean reauth)Generates SAML 2.0 authentication request for the IdP matching the provided entity ID.SAML2RequestcreateLogoutRequest(String spEntityID, String urlContext)Generates SAML 2.0 logout request for the IdP matching the requesting access token.javax.ws.rs.core.ResponsegetMetadata(String spEntityID, String urlContext)Returns the XML metadata for the provided SAML 2.0 Service Provider.SAML2LoginResponsevalidateLoginResponse(SAML2Response reponse)Validates the received SAML 2.0 authentication response and creates JWT for the matching user, if found.voidvalidateLogoutResponse(SAML2Response response)Validates the received SAML 2.0 logout response.-
Methods inherited from class org.apache.syncope.core.rest.cxf.service.AbstractService
applyPreference, buildPagedResult, checkETag, createResponse, findActualKey, getOrderByClauses, getPreference, isNullPriorityAsync, modificationResponse
-
-
-
-
Field Detail
-
logic
protected final SAML2SP4UILogic logic
-
-
Constructor Detail
-
SAML2SP4UIServiceImpl
public SAML2SP4UIServiceImpl(SAML2SP4UILogic logic)
-
-
Method Detail
-
getMetadata
public javax.ws.rs.core.Response getMetadata(String spEntityID, String urlContext)
Description copied from interface:SAML2SP4UIServiceReturns the XML metadata for the provided SAML 2.0 Service Provider.- Specified by:
getMetadatain interfaceSAML2SP4UIService- Parameters:
spEntityID- SAML 2.0 SP entity ID.urlContext- SAML 2.0 SP agent URL context- Returns:
- XML metadata for the provided SAML 2.0 Service Provider
-
createLoginRequest
public SAML2Request createLoginRequest(String spEntityID, String urlContext, String idpEntityID, boolean reauth)
Description copied from interface:SAML2SP4UIServiceGenerates SAML 2.0 authentication request for the IdP matching the provided entity ID.- Specified by:
createLoginRequestin interfaceSAML2SP4UIService- Parameters:
spEntityID- SAML 2.0 SP entity IDurlContext- SAML 2.0 SP agent URL contextidpEntityID- SAML 2.0 IdP entity IDreauth- whether ForceAuthn shall be set on the request- Returns:
- SAML 2.0 authentication request
-
validateLoginResponse
public SAML2LoginResponse validateLoginResponse(SAML2Response reponse)
Description copied from interface:SAML2SP4UIServiceValidates the received SAML 2.0 authentication response and creates JWT for the matching user, if found.- Specified by:
validateLoginResponsein interfaceSAML2SP4UIService- Parameters:
reponse- SAML response and relay state- Returns:
- JWT for the matching user plus attributes returned in the response
-
createLogoutRequest
public SAML2Request createLogoutRequest(String spEntityID, String urlContext)
Description copied from interface:SAML2SP4UIServiceGenerates SAML 2.0 logout request for the IdP matching the requesting access token.- Specified by:
createLogoutRequestin interfaceSAML2SP4UIService- Parameters:
spEntityID- SAML 2.0 SP entity ID.urlContext- SAML 2.0 SP agent URL context- Returns:
- SAML 2.0 logout request
-
validateLogoutResponse
public void validateLogoutResponse(SAML2Response response)
Description copied from interface:SAML2SP4UIServiceValidates the received SAML 2.0 logout response.- Specified by:
validateLogoutResponsein interfaceSAML2SP4UIService- Parameters:
response- SAML response and relay state
-
-