public interface SecurityDomainContextA container independent security domain related facility
- [email protected]
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method and Description
cleanupSubjectContext()Cleans up the current association between thread and security context
doesUserHaveRole(Principal principal, Set<Principal> roles)Validates the application domain roles to which the operational environment Principal belongs.
getUserRoles(Principal principal)Return the set of domain roles the principal has been assigned.
isValid(Principal principal, Object credential, Subject activeSubject)The isValid method is invoked to see if a user identity and associated credentials as known in the operational environment are valid proof of the user identity.
pushSubjectContext(Subject subject, Principal principal, Object credential)Push the provided subject into the current security context; if that's not set yet, also creates a new security context and associates it with the current thread.
runAs(Callable<Void> action)Run action under this security context
principal- - the user identity in the operation environment
credential- - the proof of user identity as known in the operation environment
activeSubject- - the Subject which should be populated with the validated Subject contents. A JAAS based implementation would typically populate the activeSubject with the LoginContext.login result.
- true if the principal, credential pair is valid, false otherwise.
doesUserHaveRoleValidates the application domain roles to which the operational environment Principal belongs.
principal- the caller principal as known in the operation environment.
Set<java.security.Principal>for the application domain roles that the principal is to be validated against.
- true if the principal has at least one of the roles in the roles set, false otherwise.
getUserRolesReturn the set of domain roles the principal has been assigned.
Set<java.security.Principal>for the application domain roles that the principal has been assigned.
default void cleanupSubjectContext()Cleans up the current association between thread and security context
Copyright © 2020 JBoss, by Red Hat. All rights reserved.