Package org.jboss.security.plugins
Class PBEUtils
- java.lang.Object
-
- org.jboss.security.plugins.PBEUtils
-
public class PBEUtils extends Object
Ecrypt a password using the JaasSecurityDomain password Usage: PBEUtils salt count domain-password password salt : the Salt attribute from the JaasSecurityDomain count : the IterationCount attribute from the JaasSecurityDomain domain-password : the plaintext password that maps to the KeyStorePass attribute from the JaasSecurityDomain password : the plaintext password that should be encrypted with the JaasSecurityDomain password- Version:
- $Revison:$
- Author:
- Scott.Stark@jboss.org
-
-
Constructor Summary
Constructors Constructor Description PBEUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static byte[]
decode(byte[] secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec)
static String
decode64(String secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec)
static byte[]
encode(byte[] secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec)
static String
encode64(byte[] secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec)
static void
main(String[] args)
-
-
-
Method Detail
-
encode
public static byte[] encode(byte[] secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec) throws Exception
- Throws:
Exception
-
encode64
public static String encode64(byte[] secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec) throws Exception
- Throws:
Exception
-
decode
public static byte[] decode(byte[] secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec) throws Exception
- Throws:
Exception
-
decode64
public static String decode64(String secret, String cipherAlgorithm, SecretKey cipherKey, PBEParameterSpec cipherSpec) throws Exception
- Throws:
Exception
-
-