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 AccessTokenDataBinderaccessTokenDataBinderprotected AuthDataAccessorauthDataAccessorprotected static EncryptorENCRYPTORprotected SAML2SP4UIIdPDAOidpDAOprotected static StringJWT_CLAIM_IDP_ENTITYIDprotected static StringJWT_CLAIM_NAMEID_FORMATprotected static StringJWT_CLAIM_NAMEID_VALUEprotected static StringJWT_CLAIM_SESSIONINDEXprotected Map<String,String>metadataCacheprotected Map<String,RequestedAuthnContextProvider>perContextRACPprotected SAML2SP4UIPropertiespropsprotected ResourcePatternResolverresourceResolverprotected SAML2ClientCachesaml2ClientCacheLoginprotected SAML2ClientCachesaml2ClientCacheLogoutprotected SAML2SP4UIUserManageruserManager-
Fields inherited from class org.apache.syncope.core.logic.AbstractLogic
LOG
-
-
Constructor Summary
Constructors Constructor Description SAML2SP4UILogic(SAML2SP4UIProperties props, ResourcePatternResolver resourceResolver, AccessTokenDataBinder accessTokenDataBinder, SAML2ClientCache saml2ClientCacheLogin, SAML2ClientCache saml2ClientCacheLogout, SAML2SP4UIUserManager userManager, SAML2SP4UIIdPDAO idpDAO, AuthDataAccessor authDataAccessor)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static SAML2RequestbuildRequest(String idpEntityID, org.pac4j.core.exception.http.RedirectionAction action)SAML2RequestcreateLoginRequest(String spEntityID, String urlContext, String idpEntityID, boolean reauth)SAML2RequestcreateLogoutRequest(String accessToken, String spEntityID, String urlContext)protected static StringgetCallbackUrl(String spEntityID, String urlContext)voidgetMetadata(String spEntityID, String urlContext, OutputStream os)protected Optional<RequestedAuthnContextProvider>getRequestedAuthnContextProvider(SAML2SP4UIIdP idp)protected org.pac4j.saml.client.SAML2ClientgetSAML2Client(SAML2ClientCache saml2ClientCache, String idpEntityID, String spEntityID, String urlContext)protected org.pac4j.saml.client.SAML2ClientgetSAML2Client(SAML2ClientCache saml2ClientCache, SAML2SP4UIIdP idp, String spEntityID, String urlContext)protected org.pac4j.saml.config.SAML2ConfigurationnewSAML2Configuration()protected EntityTOresolveReference(Method method, Object... args)SAML2LoginResponsevalidateLoginResponse(SAML2Response saml2Response)voidvalidateLogoutResponse(SAML2Response saml2Response)protected static StringvalidateUrl(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
-
accessTokenDataBinder
protected final AccessTokenDataBinder accessTokenDataBinder
-
saml2ClientCacheLogin
protected final SAML2ClientCache saml2ClientCacheLogin
-
saml2ClientCacheLogout
protected final SAML2ClientCache saml2ClientCacheLogout
-
userManager
protected final SAML2SP4UIUserManager userManager
-
idpDAO
protected final SAML2SP4UIIdPDAO idpDAO
-
authDataAccessor
protected final AuthDataAccessor authDataAccessor
-
perContextRACP
protected final Map<String,RequestedAuthnContextProvider> perContextRACP
-
props
protected final SAML2SP4UIProperties props
-
resourceResolver
protected final ResourcePatternResolver resourceResolver
-
-
Constructor Detail
-
SAML2SP4UILogic
public SAML2SP4UILogic(SAML2SP4UIProperties props, ResourcePatternResolver resourceResolver, AccessTokenDataBinder accessTokenDataBinder, SAML2ClientCache saml2ClientCacheLogin, SAML2ClientCache saml2ClientCacheLogout, 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(SAML2ClientCache saml2ClientCache, SAML2SP4UIIdP idp, String spEntityID, String urlContext)
-
getSAML2Client
protected org.pac4j.saml.client.SAML2Client getSAML2Client(SAML2ClientCache saml2ClientCache, 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, boolean reauth)
-
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:
resolveReferencein classAbstractLogic<EntityTO>- Throws:
UnresolvedReferenceException
-
newSAML2Configuration
protected org.pac4j.saml.config.SAML2Configuration newSAML2Configuration()
-
-