String alg, algName;
byte encoding[] = keySpec.getEncoded();
PrivateKeyInfo privateKeyInfo = null;
try {
privateKeyInfo = (PrivateKeyInfo) PrivateKeyInfo.ASN1
.decode(encoding);
} catch (IOException e) {
throw new InvalidKeySpecException(Messages.getString(
"security.19A", e)); //$NON-NLS-1$
}
try {
x = new BigInteger((byte[]) ASN1Integer.getInstance().decode(
privateKeyInfo.getPrivateKey()));
} catch (IOException e) {
throw new InvalidKeySpecException(Messages.getString(
"security.19B", e)); //$NON-NLS-1$
}
ai = privateKeyInfo.getAlgorithmIdentifier();
try {
threeInts = (ThreeIntegerSequence) ThreeIntegerSequence.ASN1
.decode(ai.getParameters());
} catch (IOException e) {
throw new InvalidKeySpecException(Messages.getString(