| org.apache.catalina.Realm
All known Subclasses: org.apache.catalina.realm.JAASMemoryLoginModule, org.apache.catalina.realm.RealmBase,
Realm | public interface Realm (Code) | | A Realm is a read-only facade for an underlying security realm
used to authenticate individual users, and identify the security roles
associated with those users. Realms can be attached at any Container
level, but will typically only be attached to a Context, or higher level,
Container.
author: Craig R. McClanahan version: $Revision: 1.4 $ $Date: 2001/07/30 20:04:04 $ |
Method Summary | |
public void | addPropertyChangeListener(PropertyChangeListener listener) Add a property change listener to this component. | public Principal | authenticate(String username, String credentials) Return the Principal associated with the specified username and
credentials, if there is one; otherwise return null . | public Principal | authenticate(String username, byte[] credentials) Return the Principal associated with the specified username and
credentials, if there is one; otherwise return null . | public Principal | authenticate(String username, String digest, String nonce, String nc, String cnonce, String qop, String realm, String md5a2) Return the Principal associated with the specified username, which
matches the digest calculated using the given parameters using the
method described in RFC 2069; otherwise return null . | public Principal | authenticate(X509Certificate certs) Return the Principal associated with the specified chain of X509
client certificates. | public Container | getContainer() Return the Container with which this Realm has been associated. | public String | getInfo() Return descriptive information about this Realm implementation and
the corresponding version number, in the format
<description>/<version> . | public boolean | hasRole(Principal principal, String role) Return true if the specified Principal has the specified
security role, within the context of this Realm; otherwise return
false . | public void | removePropertyChangeListener(PropertyChangeListener listener) Remove a property change listener from this component. | public void | setContainer(Container container) Set the Container with which this Realm has been associated. |
addPropertyChangeListener | public void addPropertyChangeListener(PropertyChangeListener listener)(Code) | | Add a property change listener to this component.
Parameters: listener - The listener to add |
authenticate | public Principal authenticate(String username, String credentials)(Code) | | Return the Principal associated with the specified username and
credentials, if there is one; otherwise return null .
Parameters: username - Username of the Principal to look up Parameters: credentials - Password or other credentials to use inauthenticating this username |
authenticate | public Principal authenticate(String username, byte[] credentials)(Code) | | Return the Principal associated with the specified username and
credentials, if there is one; otherwise return null .
Parameters: username - Username of the Principal to look up Parameters: credentials - Password or other credentials to use inauthenticating this username |
authenticate | public Principal authenticate(String username, String digest, String nonce, String nc, String cnonce, String qop, String realm, String md5a2)(Code) | | Return the Principal associated with the specified username, which
matches the digest calculated using the given parameters using the
method described in RFC 2069; otherwise return null .
Parameters: username - Username of the Principal to look up Parameters: digest - Digest which has been submitted by the client Parameters: nonce - Unique (or supposedly unique) token which has been usedfor this request Parameters: realm - Realm name Parameters: md5a2 - Second MD5 digest used to calculate the digest :MD5(Method + ":" + uri) |
authenticate | public Principal authenticate(X509Certificate certs)(Code) | | Return the Principal associated with the specified chain of X509
client certificates. If there is none, return null .
Parameters: certs - Array of client certificates, with the first one inthe array being the certificate of the client itself. |
getContainer | public Container getContainer()(Code) | | Return the Container with which this Realm has been associated.
|
getInfo | public String getInfo()(Code) | | Return descriptive information about this Realm implementation and
the corresponding version number, in the format
<description>/<version> .
|
hasRole | public boolean hasRole(Principal principal, String role)(Code) | | Return true if the specified Principal has the specified
security role, within the context of this Realm; otherwise return
false .
Parameters: principal - Principal for whom the role is to be checked Parameters: role - Security role to be checked |
removePropertyChangeListener | public void removePropertyChangeListener(PropertyChangeListener listener)(Code) | | Remove a property change listener from this component.
Parameters: listener - The listener to remove |
setContainer | public void setContainer(Container container)(Code) | | Set the Container with which this Realm has been associated.
Parameters: container - The associated Container |
|
|