|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.crowd.integration.springsecurity.user.CrowdUserDetailsServiceImpl
public class CrowdUserDetailsServiceImpl
Retrieves users from Crowd using Crowd's remote API.
| Constructor Summary | |
|---|---|
CrowdUserDetailsServiceImpl()
|
|
| Method Summary | |
|---|---|
String |
getAdminAuthority()
Return the name of the admin authority. |
String |
getAuthorityPrefix()
Return the authority prefix applied to group names the principal is a member of when generating the GrantedAuthority[] and no authorityMap is set. |
Iterable<Map.Entry<String,String>> |
getGroupToAuthorityMappings()
Return the group-to-authority mappings |
CrowdUserDetails |
loadUserByToken(String token)
Retrieve a user from Crowd by looking up the principal by their authenticated Crowd token. |
CrowdUserDetails |
loadUserByUsername(String username)
Retrieves the user from Crowd by looking up the principal by username. |
void |
setAdminAuthority(String adminAuthority)
Set the name of the admin authority. |
void |
setAuthenticationManager(AuthenticationManager authenticationManager)
|
void |
setAuthorityPrefix(String authorityPrefix)
Set the authority prefix applied to group names the principal is a member of when generating the GrantedAuthority[] and no authorityMap is set, e.g. |
void |
setGroupMembershipManager(GroupMembershipManager groupMembershipManager)
|
void |
setGroupToAuthorityMappings(Iterable<Map.Entry<String,String>> groupToAuthorityMappings)
Set the authority mappings. |
void |
setUserManager(UserManager userManager)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CrowdUserDetailsServiceImpl()
| Method Detail |
|---|
public CrowdUserDetails loadUserByUsername(String username)
throws org.springframework.security.core.userdetails.UsernameNotFoundException,
org.springframework.dao.DataAccessException
CrowdUserDetailsService
loadUserByUsername in interface CrowdUserDetailsServiceloadUserByUsername in interface org.springframework.security.core.userdetails.UserDetailsServiceusername - username of the principal.
org.springframework.dao.DataAccessException - thrown if there was an underlying problem while communicating with the Crowd server.
org.springframework.security.core.userdetails.UsernameNotFoundException
public CrowdUserDetails loadUserByToken(String token)
throws CrowdSSOTokenInvalidException,
org.springframework.dao.DataAccessException
CrowdUserDetailsService
loadUserByToken in interface CrowdUserDetailsServicetoken - Crowd SSO token string.
org.springframework.dao.DataAccessException - thrown if there was an underlying problem while communicating with the Crowd server.
CrowdSSOTokenInvalidExceptionpublic String getAuthorityPrefix()
CrowdUserDetailsService
getAuthorityPrefix in interface CrowdUserDetailsServicepublic void setAuthorityPrefix(String authorityPrefix)
CrowdUserDetailsService
setAuthorityPrefix in interface CrowdUserDetailsServiceauthorityPrefix - prefix to apply. The default
is no prefix.public Iterable<Map.Entry<String,String>> getGroupToAuthorityMappings()
CrowdUserDetailsService
getGroupToAuthorityMappings in interface CrowdUserDetailsServicepublic void setGroupToAuthorityMappings(Iterable<Map.Entry<String,String>> groupToAuthorityMappings)
CrowdUserDetailsService
setGroupToAuthorityMappings in interface CrowdUserDetailsServicegroupToAuthorityMappings - authority mappings. If absent, an authority prefix is used.public String getAdminAuthority()
CrowdUserDetailsService
getAdminAuthority in interface CrowdUserDetailsServicepublic void setAdminAuthority(String adminAuthority)
CrowdUserDetailsService
setAdminAuthority in interface CrowdUserDetailsServiceadminAuthority - name of the admin authority. The default is ROLE_ADMIN.public void setUserManager(UserManager userManager)
public void setGroupMembershipManager(GroupMembershipManager groupMembershipManager)
public void setAuthenticationManager(AuthenticationManager authenticationManager)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||