PKCS5Scheme2UTF8PBEKeypublic class PKCS5Scheme2UTF8PBEKey extends CMSPBEKey PKCS5 scheme-2 - password converted to bytes using UTF-8. |
Constructors Summary |
---|
public PKCS5Scheme2UTF8PBEKey(char[] password, byte[] salt, int iterationCount)
super(password, salt, iterationCount);
| public PKCS5Scheme2UTF8PBEKey(char[] password, AlgorithmParameters pbeParams)
super(password, getParamSpec(pbeParams));
|
Methods Summary |
---|
byte[] | getEncoded(java.lang.String algorithmOid)
PKCS5S2ParametersGenerator gen = new PKCS5S2ParametersGenerator();
gen.init(PBEParametersGenerator.PKCS5PasswordToUTF8Bytes(this.getPassword()), this.getSalt(), this.getIterationCount());
return ((KeyParameter)gen.generateDerivedParameters(CMSEnvelopedHelper.INSTANCE.getKeySize(algorithmOid))).getKey();
|
|