Class AuthDataAccessor
java.lang.Object
org.apache.syncope.core.spring.security.AuthDataAccessor
Domain-sensible (via
@Transactional
) access to authentication / authorization data.- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionprotected final AccessTokenDAO
protected static final Set
<SyncopeGrantedAuthority> protected final AnySearchDAO
protected final AuditManager
protected final ConfParamOps
protected final ConnectorManager
protected final DelegationDAO
protected static final Encryptor
protected final GroupDAO
protected static final Logger
protected final MappingManager
protected static final Set
<SyncopeGrantedAuthority> protected final RealmSearchDAO
protected final ExternalResourceDAO
protected final RoleDAO
protected final SecurityProperties
protected final UserDAO
-
Constructor Summary
ConstructorDescriptionAuthDataAccessor
(SecurityProperties securityProperties, RealmSearchDAO realmSearchDAO, UserDAO userDAO, GroupDAO groupDAO, AnySearchDAO anySearchDAO, AccessTokenDAO accessTokenDAO, ConfParamOps confParamOps, RoleDAO roleDAO, DelegationDAO delegationDAO, ExternalResourceDAO resourceDAO, ConnectorManager connectorManager, AuditManager auditManager, MappingManager mappingManager, List<JWTSSOProvider> jwtSSOProviders) -
Method Summary
Modifier and TypeMethodDescriptionvoid
audit
(String domain, String username, String delegationKey, OpEvent.Outcome outcome, Object output, Object... input) authenticate
(String domain, Authentication authentication) Attempts to authenticate the given credentials against internal storage and pass-through resources (if configured): the first succeeding causes global success.protected boolean
authenticate
(User user, String password) authenticate
(JWTAuthentication authentication) protected Set
<SyncopeGrantedAuthority> buildAuthorities
(Map<String, Set<String>> entForRealms) protected Set
<SyncopeGrantedAuthority> getAuthorities
(String username, String delegationKey) protected Set
<SyncopeGrantedAuthority> getDelegatedAuthorities
(Delegation delegation) protected String
getDelegationKey
(SyncopeAuthenticationDetails details, String delegatedKey) getJWTSSOProvider
(String issuer) protected Set
<ExternalResource> getPassthroughResources
(User user) protected Set
<SyncopeGrantedAuthority> getUserAuthorities
(User user) void
removeExpired
(String tokenKey)
-
Field Details
-
LOG
-
ENCRYPTOR
-
ANONYMOUS_AUTHORITIES
-
MUST_CHANGE_PASSWORD_AUTHORITIES
-
securityProperties
-
realmSearchDAO
-
userDAO
-
groupDAO
-
anySearchDAO
-
accessTokenDAO
-
confParamOps
-
roleDAO
-
delegationDAO
-
resourceDAO
-
connectorManager
-
auditManager
-
mappingManager
-
-
Constructor Details
-
AuthDataAccessor
public AuthDataAccessor(SecurityProperties securityProperties, RealmSearchDAO realmSearchDAO, UserDAO userDAO, GroupDAO groupDAO, AnySearchDAO anySearchDAO, AccessTokenDAO accessTokenDAO, ConfParamOps confParamOps, RoleDAO roleDAO, DelegationDAO delegationDAO, ExternalResourceDAO resourceDAO, ConnectorManager connectorManager, AuditManager auditManager, MappingManager mappingManager, List<JWTSSOProvider> jwtSSOProviders)
-
-
Method Details
-
getJWTSSOProvider
-
getDelegationKey
-
authenticate
@Transactional(noRollbackFor=org.springframework.security.authentication.DisabledException.class) public Triple<User,Boolean, authenticateString> (String domain, Authentication authentication) Attempts to authenticate the given credentials against internal storage and pass-through resources (if configured): the first succeeding causes global success.- Parameters:
domain
- domainauthentication
- given credentials- Returns:
null
if no matching user was found, authentication result otherwise
-
authenticate
-
getPassthroughResources
-
getAdminAuthorities
-
buildAuthorities
-
getUserAuthorities
-
getDelegatedAuthorities
-
getAuthorities
@Transactional public Set<SyncopeGrantedAuthority> getAuthorities(String username, String delegationKey) -
authenticate
@Transactional public Pair<String,Set<SyncopeGrantedAuthority>> authenticate(JWTAuthentication authentication) -
removeExpired
-
audit
@Transactional(readOnly=true) public void audit(String domain, String username, String delegationKey, OpEvent.Outcome outcome, Object output, Object... input)
-