Method Summary |
|
public synchronized Subject | authenticate(String username, String credentials) Return the Principal associated with the specified username and
credentials, if there is one; otherwise return null .
If there are any errors with the JDBC connection, executing
the query or anything we return null (don't authenticate). |
protected boolean | bindAsUser(User user, String credentials) |
public void | checkCredentials(String userName, String credentials) Check whether the given User can be authenticated with the
given credentials. |
public void | closeContext() Close any open connection to the directory server for this Realm. |
protected boolean | compareCredentials(User info, String credentials) Check whether the credentials presented by the user match those
retrieved from the directory. |
protected String | digest(String credentials) |
protected Hashtable | getDirectoryContextEnvironment(String username, String credentials) Create our directory context configuration. |
public List | getRoles(User user) Return a List of roles associated with the given User. |
protected User | getUser(String username) Return a User object containing information about the user
with the specified username, if found in the directory;
otherwise return null .
If the userPassword configuration attribute is
specified, the value of that attribute is retrieved from the
user's directory entry. |
protected User | getUserByPattern(String username, String[] attrIds) Use the UserPattern configuration attribute to
locate the directory entry for the user with the specified
username and return a User object; otherwise return
null . |
protected User | getUserBySearch(String username, String[] attrIds) Search the directory to return a User object containing
information about the user with the specified username, if
found in the directory; otherwise return null . |
public boolean | isAnonymousConnection() |
public boolean | isFixedUserConnection() |
public void | logMap(Map options) |
public void | open() Open (if necessary) and return a connection to the configured
directory server for this Realm. |
public void | open(String username, String credentials) |
public void | setAuthentication(String authentication) |
public void | setConnectionPassword(String connectionPassword) |
public void | setConnectionURL(String connectionURL) |
public void | setConnectionUser(String connectionUser) |
public void | setContextFactory(String contextFactory) |
public void | setDebug(String debug) |
public void | setDigest(String algorithm) |
public void | setOptions(Map options) |
public void | setProtocol(String protocol) |
public void | setReferrals(String referrals) |
public void | setRoleBase(String roleBase) |
public void | setRoleName(String roleName) |
public void | setRoleSearch(String roleSearch) |
public void | setRoleSubtree(String roleSubtree) |
public void | setUserBase(String userBase) |
public void | setUserPassword(String userPassword) |
public void | setUserPattern(String userPattern) |
public void | setUserRoleName(String userRoleName) |
public void | setUserSearch(String userSearch) |
public void | setUserSubtree(String userSubtree) |