public class AuthScopeStoreImpl extends Object implements AuthScopeStore
AuthScopeStore to provide database based auth scope store .| Constructor and Description |
|---|
AuthScopeStoreImpl(BrokerAuthConfiguration brokerAuthConfiguration,
DataSource dataSource) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
authorize(String authScopeName,
Set<String> userGroups)
Authorize user for given resource and action
|
AuthScope |
read(String authScopeName)
Read authScope for given scope key.
|
List<AuthScope> |
readAll()
Read all authScopes.
|
void |
update(String authScopeName,
List<String> userGroups)
Update auth
|
public AuthScopeStoreImpl(BrokerAuthConfiguration brokerAuthConfiguration, DataSource dataSource)
public boolean authorize(String authScopeName, Set<String> userGroups) throws AuthNotFoundException
AuthScopeStoreauthorize in interface AuthScopeStoreauthScopeName - an authScopeNameuserGroups - set of user groups of userAuthNotFoundExceptionpublic void update(String authScopeName, List<String> userGroups) throws AuthServerException
AuthScopeStoreupdate in interface AuthScopeStoreauthScopeName - an authScopeNameuserGroups - set of user groups of userAuthServerException - throws if error occurs while granting scope.public AuthScope read(String authScopeName) throws AuthServerException
AuthScopeStoreread in interface AuthScopeStoreauthScopeName - an authScopeNameAuthServerException - throws if error occurs while reading scope.public List<AuthScope> readAll() throws AuthServerException
AuthScopeStorereadAll in interface AuthScopeStoreAuthServerException - throws if error occurs while reading scope.Copyright © 2018 WSO2. All rights reserved.