public class CloudFoundryDataflowAuthoritiesMapper extends Object implements org.springframework.cloud.common.security.support.AuthoritiesMapper
AuthoritiesMapper
will assign all
CoreSecurityRoles
to the authenticated OAuth2 user IF the user is a "Space
Developer" in Cloud Foundry.Constructor and Description |
---|
CloudFoundryDataflowAuthoritiesMapper(CloudFoundrySecurityService cloudFoundrySecurityService) |
Modifier and Type | Method and Description |
---|---|
Set<org.springframework.security.core.GrantedAuthority> |
mapScopesToAuthorities(String providerId,
Set<String> scopes,
String token)
|
public CloudFoundryDataflowAuthoritiesMapper(CloudFoundrySecurityService cloudFoundrySecurityService)
public Set<org.springframework.security.core.GrantedAuthority> mapScopesToAuthorities(String providerId, Set<String> scopes, String token)
List
of GrantedAuthority
s contains all roles from
CoreSecurityRoles
. The roles are prefixed with the value specified in
GrantedAuthorityDefaults
.mapScopesToAuthorities
in interface org.springframework.cloud.common.security.support.AuthoritiesMapper
providerId
- Not usedscopes
- Not usedtoken
- Must not be null or empty.Copyright © 2020 Pivotal Software, Inc.. All rights reserved.