public interface SecurityRule
extends io.micronaut.core.order.Ordered
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DENY_ALL
The token to represent no security roles are allowed.
|
static java.lang.String |
IS_ANONYMOUS
The token to represent allowing anonymous access.
|
static java.lang.String |
IS_AUTHENTICATED
The token to represent allowing any authenticated access.
|
Modifier and Type | Method and Description |
---|---|
SecurityRuleResult |
check(io.micronaut.http.HttpRequest request,
io.micronaut.web.router.RouteMatch routeMatch,
java.util.Map<java.lang.String,java.lang.Object> claims)
Returns a security result based on any conditions.
|
static final java.lang.String IS_ANONYMOUS
static final java.lang.String IS_AUTHENTICATED
static final java.lang.String DENY_ALL
SecurityRuleResult check(io.micronaut.http.HttpRequest request, @Nullable io.micronaut.web.router.RouteMatch routeMatch, @Nullable java.util.Map<java.lang.String,java.lang.Object> claims)
request
- The current requestrouteMatch
- The matched route or empty if no route was matched. e.g. static resource.claims
- The claims from the token. Null if not authenticatedSecurityRuleResult