| 
 | JavaTM 2 Platform Standard Ed. 5.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.security.KeyStore.PasswordProtection
public static class KeyStore.PasswordProtection
A password-based implementation of ProtectionParameter.
| Constructor Summary | |
|---|---|
| KeyStore.PasswordProtection(char[] password)Creates a password parameter. | |
| Method Summary | |
|---|---|
|  void | destroy()Clears the password. | 
|  char[] | getPassword()Gets the password. | 
|  boolean | isDestroyed()Determines if password has been cleared. | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
|---|
public KeyStore.PasswordProtection(char[] password)
 The specified password is cloned before it is stored
 in the new PasswordProtection object.
password - the password, which may be null| Method Detail | 
|---|
public char[] getPassword()
Note that this method returns a reference to the password. If a clone of the array is created it is the caller's responsibility to zero out the password information after it is no longer needed.
null
IllegalStateException - if the password has
                been cleared (destroyed)destroy()
public void destroy()
             throws DestroyFailedException
destroy in interface DestroyableDestroyFailedException - if this method was unable
        to clear the passwordpublic boolean isDestroyed()
isDestroyed in interface Destroyable| 
 | JavaTM 2 Platform Standard Ed. 5.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.