Package org.apache.syncope.core.logic
Class SAML2SP4UILogic
- java.lang.Object
-
- org.apache.syncope.core.logic.AbstractLogic<T>
-
- org.apache.syncope.core.logic.AbstractTransactionalLogic<EntityTO>
-
- org.apache.syncope.core.logic.SAML2SP4UILogic
-
public class SAML2SP4UILogic extends AbstractTransactionalLogic<EntityTO>
-
-
Field Summary
Fields Modifier and Type Field Description protected AccessTokenDataBinder
accessTokenDataBinder
protected AuthDataAccessor
authDataAccessor
protected static Encryptor
ENCRYPTOR
protected SAML2SP4UIIdPDAO
idpDAO
protected static String
JWT_CLAIM_IDP_ENTITYID
protected static String
JWT_CLAIM_NAMEID_FORMAT
protected static String
JWT_CLAIM_NAMEID_VALUE
protected static String
JWT_CLAIM_SESSIONINDEX
protected SAML2SP4UILoader
loader
protected Map<String,String>
metadataCache
protected Map<String,RequestedAuthnContextProvider>
perContextRACP
protected SAML2ClientCache
saml2ClientCache
protected SAML2SP4UIUserManager
userManager
-
Fields inherited from class org.apache.syncope.core.logic.AbstractLogic
LOG
-
-
Constructor Summary
Constructors Constructor Description SAML2SP4UILogic(SAML2SP4UILoader loader, AccessTokenDataBinder accessTokenDataBinder, SAML2ClientCache saml2ClientCache, SAML2SP4UIUserManager userManager, SAML2SP4UIIdPDAO idpDAO, AuthDataAccessor authDataAccessor)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static SAML2Request
buildRequest(String idpEntityID, org.pac4j.core.exception.http.RedirectionAction action)
SAML2Request
createLoginRequest(String spEntityID, String urlContext, String idpEntityID)
SAML2Request
createLogoutRequest(String accessToken, String spEntityID, String urlContext)
protected static String
getCallbackUrl(String spEntityID, String urlContext)
void
getMetadata(String spEntityID, String urlContext, OutputStream os)
protected Optional<RequestedAuthnContextProvider>
getRequestedAuthnContextProvider(SAML2SP4UIIdP idp)
protected org.pac4j.saml.client.SAML2Client
getSAML2Client(String idpEntityID, String spEntityID, String urlContext)
protected org.pac4j.saml.client.SAML2Client
getSAML2Client(SAML2SP4UIIdP idp, String spEntityID, String urlContext)
protected EntityTO
resolveReference(Method method, Object... args)
SAML2LoginResponse
validateLoginResponse(SAML2Response saml2Response)
void
validateLogoutResponse(SAML2Response saml2Response)
protected static String
validateUrl(String url)
-
Methods inherited from class org.apache.syncope.core.logic.AbstractLogic
resolveBeanReference
-
-
-
-
Field Detail
-
JWT_CLAIM_IDP_ENTITYID
protected static final String JWT_CLAIM_IDP_ENTITYID
- See Also:
- Constant Field Values
-
JWT_CLAIM_NAMEID_FORMAT
protected static final String JWT_CLAIM_NAMEID_FORMAT
- See Also:
- Constant Field Values
-
JWT_CLAIM_NAMEID_VALUE
protected static final String JWT_CLAIM_NAMEID_VALUE
- See Also:
- Constant Field Values
-
JWT_CLAIM_SESSIONINDEX
protected static final String JWT_CLAIM_SESSIONINDEX
- See Also:
- Constant Field Values
-
ENCRYPTOR
protected static final Encryptor ENCRYPTOR
-
loader
protected final SAML2SP4UILoader loader
-
accessTokenDataBinder
protected final AccessTokenDataBinder accessTokenDataBinder
-
saml2ClientCache
protected final SAML2ClientCache saml2ClientCache
-
userManager
protected final SAML2SP4UIUserManager userManager
-
idpDAO
protected final SAML2SP4UIIdPDAO idpDAO
-
authDataAccessor
protected final AuthDataAccessor authDataAccessor
-
perContextRACP
protected final Map<String,RequestedAuthnContextProvider> perContextRACP
-
-
Constructor Detail
-
SAML2SP4UILogic
public SAML2SP4UILogic(SAML2SP4UILoader loader, AccessTokenDataBinder accessTokenDataBinder, SAML2ClientCache saml2ClientCache, SAML2SP4UIUserManager userManager, SAML2SP4UIIdPDAO idpDAO, AuthDataAccessor authDataAccessor)
-
-
Method Detail
-
getMetadata
@PreAuthorize("isAuthenticated()") public void getMetadata(String spEntityID, String urlContext, OutputStream os)
-
getSAML2Client
protected org.pac4j.saml.client.SAML2Client getSAML2Client(SAML2SP4UIIdP idp, String spEntityID, String urlContext)
-
getSAML2Client
protected org.pac4j.saml.client.SAML2Client getSAML2Client(String idpEntityID, String spEntityID, String urlContext)
-
buildRequest
protected static SAML2Request buildRequest(String idpEntityID, org.pac4j.core.exception.http.RedirectionAction action)
-
getRequestedAuthnContextProvider
protected Optional<RequestedAuthnContextProvider> getRequestedAuthnContextProvider(SAML2SP4UIIdP idp)
-
createLoginRequest
@PreAuthorize("hasRole(\'ANONYMOUS\')") public SAML2Request createLoginRequest(String spEntityID, String urlContext, String idpEntityID)
-
validateLoginResponse
@PreAuthorize("hasRole(\'ANONYMOUS\')") public SAML2LoginResponse validateLoginResponse(SAML2Response saml2Response)
-
createLogoutRequest
@PreAuthorize("isAuthenticated() and not(hasRole(\'ANONYMOUS\'))") public SAML2Request createLogoutRequest(String accessToken, String spEntityID, String urlContext)
-
validateLogoutResponse
@PreAuthorize("hasRole(\'ANONYMOUS\')") public void validateLogoutResponse(SAML2Response saml2Response)
-
resolveReference
protected EntityTO resolveReference(Method method, Object... args) throws UnresolvedReferenceException
- Specified by:
resolveReference
in classAbstractLogic<EntityTO>
- Throws:
UnresolvedReferenceException
-
-