com.ibm.websphere.security
Interface CustomRegistry


Deprecated. As of WAS 5.0, replaced by UserRegistry interface. Implementations using CustomRegistry interface are supported by WAS 5.0 both at compile time and at runtime. UserRegistry interface is both the plug-in point for custom developed user registry, it is also the runtime user registry interface. Moreover, improvements have been made to the UserRegistry interface and all CustomRegistry implementation should be migrated to use the UserRegistry interface.

public interface CustomRegistry

The CustomRegistry interface provides an API that supports the following registry entry types:

Implementation of this interface must provide implementations for:


Method Summary
 java.lang.String checkPassword(java.lang.String userId, java.lang.String password)
          Deprecated. As of WAS 5.0, replaced by UserRegistry checkPassword(String, String).
 java.lang.String getGroupDisplayName(java.lang.String groupName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getGroupDisplayName(String).
 java.util.List getGroups()
          Deprecated. As of WAS 5.0, replaced by UserRegistry getGroups(String, int).
 java.util.List getGroups(java.lang.String pattern)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getGroups(String, int).
 java.lang.String getGroupSecurityName(java.lang.String uniqueGroupId)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getGroupSecurityName(String).
 java.util.List getGroupsForUser(java.lang.String userName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getGroupsForUser(String).
 java.lang.String getRealm()
          Deprecated. As of WAS 5.0, replaced by UserRegistry getRealm().
 java.lang.String getUniqueGroupId(java.lang.String groupName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUniqueGroupId(String).
 java.util.List getUniqueGroupIds(java.lang.String uniqueUserId)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUniqueGroupIds(String).
 java.lang.String getUniqueUserId(java.lang.String userName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUniqueUserId(String).
 java.util.List getUniqueUserIds(java.lang.String uniqueGroupId)
          Deprecated. As of WAS 5.0, UserRegistry has no corresponding function.
 java.lang.String getUserDisplayName(java.lang.String userName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUserDisplayName(String).
 java.util.List getUsers()
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUsers(String, int).
 java.util.List getUsers(java.lang.String pattern)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUsers(String, int).
 java.lang.String getUserSecurityName(java.lang.String uniqueUserId)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUserSecurityName(String).
 java.util.List getUsersForGroup(java.lang.String groupName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry getUsersForGroup(String, int).
 void initialize(java.util.Properties props)
          Deprecated. As of WAS 5.0, replaced by UserRegistry initialize(java.util.Properties).
 boolean isValidGroup(java.lang.String groupName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry isValidGroup(String).
 boolean isValidUser(java.lang.String userName)
          Deprecated. As of WAS 5.0, replaced by UserRegistry isValidUser(String).
 java.lang.String mapCertificate(java.security.cert.X509Certificate cert)
          Deprecated. As of WAS 5.0, replaced by UserRegistry mapCertificate(X509Certificate[]).
 

Method Detail

initialize

public void initialize(java.util.Properties props)
                throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry initialize(java.util.Properties).

Initializes the registry.
Parameters:
props - the registry-specific properties with which to initialize the registry object.
Throws:
CustomRegistryException - if there is any problem.

checkPassword

public java.lang.String checkPassword(java.lang.String userId,
                                      java.lang.String password)
                               throws PasswordCheckFailedException,
                                      CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry checkPassword(String, String).

Checks the password of the user.
Parameters:
userId - the username whose password needs to be checked.
password - the password of the userId.
Returns:
a valid username (this can be the same userId whose password was checked or it could be some other userId in the registry if the implementation was to do so).
Throws:
CheckPasswordFailedException - if userId/password combination does not exist in the registry.
CustomRegistryException - if there is any other problem.

mapCertificate

public java.lang.String mapCertificate(java.security.cert.X509Certificate cert)
                                throws CertificateMapNotSupportedException,
                                       CertificateMapFailedException,
                                       CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry mapCertificate(X509Certificate[]).

Maps a Certificate (of X509 format) to a valid userId in the Registry.
Parameters:
cert - the certificate that needs to be mapped.
Returns:
the mapped name of the user (userId).
Throws:
CertificateMapNotSupportedException - if the particular certificate is not supported.
CertificateMapFailedException - if the mapping of the certificate fails.
CustomRegistryException - if there is any other problem.

getRealm

public java.lang.String getRealm()
                          throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getRealm().

Returns the realm of the registry.
Returns:
the realm. The realm is a registry-specific string indicating the realm or domain for which this registry applies. E.g. for OS400 or AIX this would be the host name of the system whose user registry * this object represents. If null is returned by this method realm defaults to the value of "customRealm".
Throws:
CustomRegistryException - if there is any problem.

getUsers

public java.util.List getUsers()
                        throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUsers(String, int).

Returns names of all the users in the registry.
Returns:
a List of the names of all the users.
Throws:
CustomRegistryException - if there is any problem.

getUsers

public java.util.List getUsers(java.lang.String pattern)
                        throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUsers(String, int).

Returns names of the users in the registry that match a pattern.
Parameters:
pattern - the pattern to match. (For e.g., a* will match all userNames starting with a)
Returns:
a List of the names of all the users that match the pattern.
Throws:
CustomRegistryException - if there is any problem.

getUsersForGroup

public java.util.List getUsersForGroup(java.lang.String groupName)
                                throws EntryNotFoundException,
                                       CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUsersForGroup(String, int).

Returns the names of the all the users in a group.
Parameters:
groupName - the name of the group.
Returns:
a List of all the names of the users in the group.
Throws:
EntryNotFoundException - if groupName does not exist.
CustomRegistryException - if there is any other problem.

getUserDisplayName

public java.lang.String getUserDisplayName(java.lang.String userName)
                                    throws EntryNotFoundException,
                                           CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUserDisplayName(String).

Returns the display name for the user specified by userName.
Parameters:
userName - the name of the user.
Returns:
the display name for the user. The display name is a registry-specific string that represents a descriptive, not necessarily unique, name for a user. If a display name does not exist return null.
Throws:
EntryNotFoundException - if userName does not exist.
CustomRegistryException - if there is any other problem.

getUniqueUserId

public java.lang.String getUniqueUserId(java.lang.String userName)
                                 throws EntryNotFoundException,
                                        CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUniqueUserId(String).

Returns the UniqueId for a userName.
Parameters:
userName - the name of the user.
Returns:
the UniqueId of the user. The UniqueId for an user is the stringified form of some unique, registry-specific, data that serves to represent the user. E.g. for the UNIX user registry, the UniqueId for a user can be the UID.
Throws:
EntryNotFoundException - if userName does not exist.
CustomRegistryException - if there is any other problem.

getUniqueUserIds

public java.util.List getUniqueUserIds(java.lang.String uniqueGroupId)
                                throws EntryNotFoundException,
                                       CustomRegistryException
Deprecated. As of WAS 5.0, UserRegistry has no corresponding function.

Returns the UniqueIds for all the users that belong to a group.
Parameters:
uniqueGroupId - the uniqueId of the group.
Returns:
a List of all the user Unique ids that are contained in the group whose Unique id matches the uniqueGroupId. The Unique id for an entry is the stringified form of some unique, registry-specific, data that serves to represent the entry. E.g. for the Unix user registry, the Unique id for a group could be the GID and the Unique Id for the user could be the UID.
Throws:
EntryNotFoundException - if uniqueGroupId does not exist.
CustomRegistryException - if there is any other problem.

getUserSecurityName

public java.lang.String getUserSecurityName(java.lang.String uniqueUserId)
                                     throws EntryNotFoundException,
                                            CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUserSecurityName(String).

Returns the name for a user given its uniqueId.
Parameters:
uniqueUserId - the UniqueId of the user.
Returns:
the name of the user.
Throws:
EntryNotFoundException - if the uniqueUserId does not exist.
CustomRegistryException - if there is any other problem.

isValidUser

public boolean isValidUser(java.lang.String userName)
                    throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry isValidUser(String).

Determines if a user exists.
Parameters:
userName - the name of the user.
Returns:
true if the user exists; false otherwise.
Throws:
CustomRegistryException - if there is any problem.

getGroups

public java.util.List getGroups()
                         throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getGroups(String, int).

Returns names of all the groups in the registry.
Returns:
a List of the names of all the groups.
Throws:
CustomRegistryException - if there is any problem.

getGroups

public java.util.List getGroups(java.lang.String pattern)
                         throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getGroups(String, int).

Returns names of the groups in the registry that match a pattern.
Parameters:
pattern - the pattern to match.
Returns:
a List of the names of the groups.
Throws:
CustomRegistryException - if there is any problem.

getGroupsForUser

public java.util.List getGroupsForUser(java.lang.String userName)
                                throws EntryNotFoundException,
                                       CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getGroupsForUser(String).

Returns the names of the groups to which userName belongs.
Parameters:
userName - the username of the user.
Returns:
a List of the names of all the groups that the user belongs to.
Throws:
EntryNotFoundException - if userName does not exist.
CustomRegistryException - if there is any other problem.

getGroupDisplayName

public java.lang.String getGroupDisplayName(java.lang.String groupName)
                                     throws EntryNotFoundException,
                                            CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getGroupDisplayName(String).

Returns the display name for a group.
Parameters:
groupName - the name of the group.
Returns:
the display name for the group. The display name is a registry-specific string that represents a descriptive, not necessarily unique, name for a group.
Throws:
EntryNotFoundException - if the groupName does not exist.
CustomRegistryException - if there is any other problem.

getUniqueGroupId

public java.lang.String getUniqueGroupId(java.lang.String groupName)
                                  throws EntryNotFoundException,
                                         CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUniqueGroupId(String).

Returns the Unique id for a group.
Parameters:
groupName - the name of the group.
Returns:
the Unique id of the group. The Unique id for a group is the stringified form of some unique, registry-specific, data that serves to represent the entry. E.g. for the Unix user registry, the Unique id could be the GID for the entry.
Throws:
EntryNotFoundException - if groupName does not exist.
CustomRegistryException - if there is any other problem.

getUniqueGroupIds

public java.util.List getUniqueGroupIds(java.lang.String uniqueUserId)
                                 throws EntryNotFoundException,
                                        CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getUniqueGroupIds(String).

Returns the Unique ids for all the groups that contain the UniqueId of a user.
Parameters:
uniqueUserId - the uniqueId of the user.
Returns:
a List of all the group Unique ids that uniqueUserId belongs to. The Unique id for an entry is the stringified form of some unique, registry-specific, data that serves to represent the entry. E.g. for the Unix user registry, the Unique id for a group could be the GID and the Unique Id for the user could be the UID.
Throws:
EntryNotFoundException - if uniqueUserId does not exist.
CustomRegistryException - if there is any other problem.

getGroupSecurityName

public java.lang.String getGroupSecurityName(java.lang.String uniqueGroupId)
                                      throws EntryNotFoundException,
                                             CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry getGroupSecurityName(String).

Returns the name for a group given its uniqueId.
Parameters:
uniqueGroupId - the UniqueId of the group.
Returns:
the name of the group.
Throws:
EntryNotFoundException - if the uniqueGroupId does not exist.
CustomRegistryException - if there is any other problem.

isValidGroup

public boolean isValidGroup(java.lang.String groupName)
                     throws CustomRegistryException
Deprecated. As of WAS 5.0, replaced by UserRegistry isValidGroup(String).

Determines if a group exists.
Parameters:
groupName - the name of the group.
Returns:
true if the group exists; false otherwise.
Throws:
CustomRegistryException - if there is any problem.