All Packages Class Hierarchy This Package Previous Next Index
Interface sun.server.realm.User
- public interface User
- extends Principal
All users are principals ... perhaps in the native OS, perhaps
not. (Groups and ACLs don't map to the native OS concepts.)
All users have a "home" file storage area.
Users always have authentication information, which is used
to validate a user's proferred credentials. Different kinds of
realms use different kinds of authentication information. For
example, realms could use X.509 public key certificates, shared
passphrases, encrypted passwords, smart cards, or biometric data
to figure out if the user's credentials are valid.
Users also have a variety of attributes. These are identified
by strings, such as "fullname" to identify their full
name, and "home" to identify the URL for the directory
where their personal data is stored. Attributes may be gotten and
set in groups.
NOTE: this interface is still in development.
-
getAttribute(String)
- Returns the single requested attribute for the user.
-
getAttributes(String[])
- Returns the requested set of attributes for the user.
-
getAuthInfo()
- Returns authentication information associated with the user.
-
getRealm()
- Returns the realm with which this user is associated.
-
setAttributes(String[], Object[])
- Assigns values to a set of attributes for the user.
-
setAuthInfo(Object)
- Sets the authentication information associated with the user.
getRealm
public abstract Realm getRealm()
- Returns the realm with which this user is associated.
getAuthInfo
public abstract Object getAuthInfo() throws NoSuchUserException
- Returns authentication information associated with the user.
- Returns:
- s implementation-specific authentication information
- Throws: NoSuchUserException
- if the user no longer exists
setAuthInfo
public abstract void setAuthInfo(Object info) throws BadRealmException
- Sets the authentication information associated with the user.
- Parameters:
- info - implementation-specific authentication information
- Throws: BadRealmException
- if realm data structures are no good
getAttribute
public abstract Object getAttribute(String key)
- Returns the single requested attribute for the user.
- Parameters:
- key - string identifying the attribute.
- Returns:
- value of that attribute
getAttributes
public abstract Object[] getAttributes(String keys[])
- Returns the requested set of attributes for the user.
- Parameters:
- keys - strings identifying the attributes.
- Returns:
- values of those attributes
setAttributes
public abstract void setAttributes(String keys[],
Object values[])
- Assigns values to a set of attributes for the user.
- Parameters:
- keys - strings identifying the attributes.
- values - values to be assigned to those attributes
All Packages Class Hierarchy This Package Previous Next Index