Package | Description |
---|---|
org.seedstack.seed.security |
Provides classes for securing an application.
|
Modifier and Type | Class and Description |
---|---|
class |
SimpleScope
A simple kind of scope that can be described as a String which matches in an all or nothing fashion (strict
equality).
|
Modifier and Type | Method and Description |
---|---|
<S extends Scope> |
Role.getScopesByType(Class<S> scopeType)
Filters the scopes corresponding to a type
|
Modifier and Type | Method and Description |
---|---|
Collection<Scope> |
Role.getScopes() |
Modifier and Type | Method and Description |
---|---|
void |
SecuritySupport.checkPermission(String permission,
Scope... scopes)
Checks if the connected user has the given permission on the given scopes : if the user does not have the
permission, throws an exception to
block execution.
The permission is given as a String in the form "object:action[:id]" (e.g. |
boolean |
SecuritySupport.hasRole(String roleIdentifier,
Scope... scopes)
Tells if the connected user has the given role on all the given scopes.
Note that it is discouraged to test for roles in your application as role names are prone to change in the life span of your application. |
boolean |
SimpleScope.includes(Scope scope)
Checks if the current simple scope equals the verified simple scope.
|
boolean |
Scope.includes(Scope scope)
Verifies if the current scope includes the given scope.
|
boolean |
SecuritySupport.isPermitted(String permission,
Scope... scopes)
Tells if the connected user has the given permission on the given scopes.
The permission is given as a String in the form "object:action[:id]" (e.g. |
Copyright © 2013-2018–2019 SeedStack. All rights reserved.