public class AuthorizationConfigurationBuilder extends AbstractPathConfigurationChildBuilder
Provides a set of options to configure authorization for a specific path.
Modifier and Type | Method and Description |
---|---|
AuthorizationConfigurationBuilder |
authorizer(Class<? extends PathAuthorizer>... pathAuthorizer)
Specifies a custom
PathAuthorizer for the given path. |
AuthorizationConfigurationBuilder |
expression(String... expression)
Specified an EL Expression that will be used to enforce authorization when sending requests to a specific path.
|
AuthorizationConfigurationBuilder |
group(String... groupNames)
Specifies one or more groups that must be enforced when sending requests to a specific path.
|
AuthorizationConfigurationBuilder |
realm(String... realmNames)
Specifies one or more realms that must be enforced when sending requests to a specific path.
|
AuthorizationConfigurationBuilder |
role(String... roleNames)
Specifies one or more roles that must be enforced when sending requests to a specific path.
|
authenticateWith, authorizeWith, getBuilder, redirectTo, unprotected
allPaths, forGroup, forPath, forPath, restrictive
build, create, http, identity, idmConfig, readFrom, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
allPaths, forGroup, forPath, forPath, restrictive
build, http, identity, idmConfig
public AuthorizationConfigurationBuilder role(String... roleNames)
Specifies one or more roles that must be enforced when sending requests to a specific path.
Only users with all the specified roles are allowed to access.
roleNames
- public AuthorizationConfigurationBuilder group(String... groupNames)
Specifies one or more groups that must be enforced when sending requests to a specific path.
Only users members of all the specified groups are allowed to access.
groupNames
- public AuthorizationConfigurationBuilder realm(String... realmNames)
Specifies one or more realms that must be enforced when sending requests to a specific path.
Only users that belong to any of the given realms are allowed to access.
realmNames
- public AuthorizationConfigurationBuilder expression(String... expression)
Specified an EL Expression that will be used to enforce authorization when sending requests to a specific path.
expression
- An EL Expression. Expressions must always evaluate to a boolean. When defining expressions some important components are available for use
such as the Identity
instance. For instance, #{identity.isLoggedIn()}.public AuthorizationConfigurationBuilder authorizer(Class<? extends PathAuthorizer>... pathAuthorizer)
Specifies a custom PathAuthorizer
for the given path.
pathAuthorizer
- Copyright © 2018 JBoss by Red Hat. All rights reserved.