com.sun.jdmk.security.sasl
Class AuthenticateCallback

java.lang.Object
  extended by com.sun.jdmk.security.sasl.AuthenticateCallback
All Implemented Interfaces:
Serializable, Callback

public class AuthenticateCallback
extends Object
implements Callback, Serializable

This callback is used by SaslServer to verify the authentication identity and password with the system authentication database.

See Also:
Serialized Form

Constructor Summary
AuthenticateCallback(String authenticationID, char[] password)
          Constructs an instance of AuthenticateCallback.
 
Method Summary
 void clearPassword()
          Clear the password to check.
 String getAuthenticationID()
          Returns the authentication identity to check.
 char[] getPassword()
          Returns the password to check.
 boolean isAuthenticated()
          Determines whether the authentication identity and password have been successfully verified by the system authentication database.
 void setAuthenticated(boolean ok)
          Sets whether the authentication succeeded.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AuthenticateCallback

public AuthenticateCallback(String authenticationID,
                            char[] password)
Constructs an instance of AuthenticateCallback.

Parameters:
authenticationID - The authentication identity.
password - The password. This method makes a copy of the input password before storing it.
Method Detail

getAuthenticationID

public String getAuthenticationID()
Returns the authentication identity to check.

Returns:
The authentication identity to check.

getPassword

public char[] getPassword()
Returns the password to check.

Returns:
The password to check. This method returns a copy of the retrieved password.

isAuthenticated

public boolean isAuthenticated()
Determines whether the authentication identity and password have been successfully verified by the system authentication database.

Returns:
true if authentication succeeded; false otherwise.
See Also:
setAuthenticated(boolean)

setAuthenticated

public void setAuthenticated(boolean ok)
Sets whether the authentication succeeded.

Parameters:
ok - true if authentication succeeded; false otherwise.
See Also:
isAuthenticated()

clearPassword

public void clearPassword()
Clear the password to check.


Open Source build 02
opendmk-1.0-b02 2007.10.01_19:17:46_MEST

Copyright 1998-2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.