org.apache.openejb.resource.jdbc
Class StaticDESPasswordCipher
java.lang.Object
org.apache.openejb.resource.jdbc.StaticDESPasswordCipher
- All Implemented Interfaces:
- PasswordCipher
public class StaticDESPasswordCipher
- extends Object
- implements PasswordCipher
This PasswordCipher
implementation uses a the Triple-DES encryption
algorithm.
Method Summary |
String |
decrypt(char[] encodedPassword)
Decodes an encoded password and returns a plain text password. |
char[] |
encrypt(String plainPassword)
Encodes a given plain text password and returns the encoded password. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StaticDESPasswordCipher
public StaticDESPasswordCipher()
encrypt
public char[] encrypt(String plainPassword)
- Description copied from interface:
PasswordCipher
- Encodes a given plain text password and returns the encoded password.
- Specified by:
encrypt
in interface PasswordCipher
- Parameters:
plainPassword
- The password to encode. May not be null
, nor empty.
- Returns:
- The encoded password.
- Throws:
RuntimeException
- in any case of error.- See Also:
PasswordCipher.encrypt(java.lang.String)
decrypt
public String decrypt(char[] encodedPassword)
- Description copied from interface:
PasswordCipher
- Decodes an encoded password and returns a plain text password.
- Specified by:
decrypt
in interface PasswordCipher
- Parameters:
encodedPassword
- The ciphered password to decode. May not be null
,
nor empty.
- Returns:
- The plain text password.
- Throws:
RuntimeException
- in any case of error.- See Also:
PasswordCipher.decrypt(char[])
Copyright © 1999-2013 The Apache OpenEJB development community. All Rights Reserved.