| Modifier and Type | Class and Description |
|---|---|
| protected static class |
| Modifier and Type | Field and Description |
|---|---|
| protected RealmBase. | allRolesMode
The all role mode. |
| protected Container | container
The Container with which this Realm is associated. |
| protected Log | containerLog
Container log |
| private CredentialHandler | |
| private static final List | |
| private static final Log | |
| protected String | |
| protected static final StringManager | sm
The string manager for this package.
|
| protected boolean | stripRealmForGss
When processing users authenticated via the GSS-API, should any "@... |
| protected final PropertyChangeSupport | support
The property change support for this component. |
| private int | |
| protected static final String | USER_ATTRIBUTES_DELIMITER
The character used for delimiting user attribute names. |
| protected static final String | USER_ATTRIBUTES_WILDCARD
The character used as wildcard in user attribute lists. |
| protected String | userAttributes
The comma separated names of user attributes to additionally query from the realm. |
| protected List | userAttributesList
The list of user attributes to additionally query from the realm. |
| protected boolean | validate
Should we validate client certificate chains when they are presented? |
| protected X509UsernameRetriever | x509UsernameRetriever
The object that will extract user names from X509 client certificates. |
| protected String | x509UsernameRetrieverClassName
The name of the class to use for retrieving user names from X509 certificates. |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | addPropertyChangeListener(PropertyChangeListener
The listener to add listener)Implements org. Add a property change listener to this component. |
| public Principal | authenticate(String
Username of the Principal to look up username)Implements org. Try to authenticate with the specified username. |
| public Principal | authenticate(String
Username of the Principal to look up username, String Password or other credentials to use in
authenticating this username credentials)Implements org. Try to authenticate using the specified username and credentials. |
| public Principal | authenticate(String
Username of the Principal to look up username, String Digest which has been submitted by the client clientDigest, String Unique (or supposedly unique) token which has been used
for this request nonce, String the nonce counter nc, String the client chosen nonce cnonce, String the "quality of protection" ( qop, String nc and cnonce
will only be used, if qop is not null).Realm name realm, String Second digest calculated as digest(Method + ":" + uri) digestA2)Implements org.
Deprecated
Try to authenticate with the specified username, which matches the digest calculated using the given parameters using the method described in RFC 2617 (which is a superset of RFC 2069). |
| public Principal | authenticate(String
Username of the Principal to look up username, String Digest which has been submitted by the client clientDigest, String Unique (or supposedly unique) token which has been used
for this request nonce, String the nonce counter nc, String the client chosen nonce cnonce, String the "quality of protection" ( qop, String nc and cnonce
will only be used, if qop is not null).Realm name realm, String Second digest calculated as digest(Method + ":" + uri) digestA2, String The message digest algorithm to use algorithm)Overrides default org. Try to authenticate with the specified username, which matches the digest calculated using the given parameters using the method described in RFC 7616. |
| public Principal | authenticate(X509Certificate[]
Array of client certificates, with the first one in
the array being the certificate of the client itself. certs)Implements org. Try to authenticate using a chain of |
| public Principal | authenticate(GSSContext
The gssContext processed by the gssContext, boolean Authenticator.Should the realm attempt to store the delegated
credentials in the returned Principal? storeCred)Implements org. Try to authenticate using a |
| public Principal | authenticate(GSSName
The gssName, GSSCredential GSSName of the principal to look upThe gssCredential)GSSCredential of the principal, may be
nullImplements org. Try to authenticate using a |
| public void | backgroundProcess()
Implements org. Execute a periodic task, such as reloading, etc. This method will be invoked inside the classloading context of this container. |
| private static X509UsernameRetriever | |
| public SecurityConstraint[] | findSecurityConstraints(Request
Request we are processing request, Context Context the Request is mapped to context)Implements org. Find the SecurityConstraints configured to guard the request URI for this request. |
| public String | Returns: A string representation of the current all roles modeReturn the all roles mode. |
| public Container | getContainer()
Implements org. Get the |
| public CredentialHandler | |
| protected String | Returns: the digest for the specified userThe user name username, String The realm name realmName)
Deprecated
Unused. Use
getDigest(String, String, String). Will be removed in Tomcat 11.
Return the digest associated with given principal's user name. |
| protected String | |
| private Charset | |
| private String | |
| public String | getDomainInternal()
Implements abstract org. Method implemented by sub-classes to identify the domain in which MBeans should be registered. |
| public String | getObjectNameKeyProperties()
Implements abstract org. Allow sub-classes to specify the key properties component of the
|
| protected abstract String | Returns: the password associated with the given principal's user name.The user name username)Get the password for the specified user. |
| protected Principal | Returns: the Principal associated with the given certificate.The user certificate usercert)Get the principal associated with the specified certificate. |
| protected abstract Principal | Returns: the Principal associated with the given user name.The user name username)Get the principal associated with the specified user. |
| protected Principal | Returns: the principal associated with the given user name.The GSS name gssName, GSSCredential the GSS credential of the principal gssCredential)Get the principal associated with the specified |
| public String | |
| protected String | |
| protected Server | Returns: the Server associated with the realmReturn the Server object that is the ultimate parent for the container with which this Realm is associated. |
| public int | Returns: The HTTP status code used when the container needs to issue an HTTP redirect to meet the requirements of a configured transport guarantee.
|
| public String | Returns: the comma separated names of user attributes to additionally query from realm
|
| public boolean | Returns: The value of the validate certificate chains flagReturn the "validate certificate chains" flag. |
| public String | Returns: The name of the class that will be used to extract user names from X509 client certificates.Gets the name of the class that will be used to extract user names from X509 client certificates. |
| protected boolean | |
| public boolean | hasResourcePermission(Request
Request we are processing request, Response Response we are creating response, SecurityConstraint[] Security constraint we are enforcing constraints, Context The Context to which client of this class is attached. context)Implements org. Perform access control based on the specified authorization constraint. |
| public boolean | hasRole(Wrapper
wrapper context for evaluating role wrapper, Principal Principal for whom the role is to be checked principal, String Security role to be checked role)Implements org. Check if the specified Principal has the specified security role, within the context of this Realm. |
| protected boolean | Returns: true if the specified Principal has the specified security role, within the context of this
Realm; otherwise return false.Principal for whom the role is to be checked principal, String Security role to be checked role)Check if the specified Principal has the specified security role, within the context of this Realm. |
| public boolean | hasUserDataPermission(Request
Request we are processing request, Response Response we are creating response, SecurityConstraint[] Security constraint being checked constraints)Implements org. Enforce any user data constraint required by the security constraint guarding this request URI. |
| protected void | initInternal()
Overrides org. Sub-classes wishing to perform additional initialization should override this method, ensuring that super.initInternal() is the first call in the overriding method. |
| public boolean | |
| public static void | |
| protected List | Returns: a list containing the parsed attribute names ornull, if no attributes have been specifiedcomma separated names of attributes to parse userAttributes)Parse the specified delimiter separated attribute names and return a list of that names or |
| public void | removePropertyChangeListener(PropertyChangeListener
The listener to remove listener)Implements org. Remove a property change listener from this component. |
| private SecurityConstraint[] | resultsToArray(ArrayList<SecurityConstraint> results)
Convert an ArrayList to a SecurityConstraint []. |
| public void | setAllRolesMode(String
A string representation of the new all roles mode allRolesMode)Set the all roles mode. |
| public void | setContainer(Container
The Container instance with which this instance is to
be associated, or container)null to disassociate this instance
from any ContainerImplements org. Set the |
| public void | setCredentialHandler(CredentialHandler
the credentialHandler)CredentialHandler to useImplements org. Set the CredentialHandler to be used by this Realm. |
| public void | |
| public void | |
| public void | setTransportGuaranteeRedirectStatus(int
The status to use. This value is not validated transportGuaranteeRedirectStatus)Set the HTTP status code used when the container needs to issue an HTTP redirect to meet the requirements of a configured transport guarantee. |
| public void | setUserAttributes(String
the comma separated names of user attributes userAttributes)Set the comma separated names of user attributes to additionally query from the realm. |
| public void | setValidate(boolean
The new validate certificate chains flag validate)Set the "validate certificate chains" flag. |
| public void | setX509UsernameRetrieverClassName(String
The name of the class that will be used to extract user names from X509 client certificates. className)Sets the name of the class that will be used to extract user names from X509 client certificates. |
| protected void | startInternal()
Implements abstract org. Prepare for the beginning of active use of the public methods of this component and implement the requirements of
|
| protected void | stopInternal()
Implements abstract org. Gracefully terminate the active use of the public methods of this component and implement the requirements of
|
| public String | |
| private static void |