foo.addElement(new OCTET_STRING.Template());
SEQUENCE ecPrivateKey = (SEQUENCE) foo.decode(new ByteArrayInputStream(
pki.getEncoded()));
OCTET_STRING arrhh = (OCTET_STRING) ecPrivateKey.elementAt(1);
return new EcPrivateKeyImpl(new BigInteger(1, arrhh.toByteArray()),
params);
} catch (Exception e) {
throw new InvalidKeySpecException("Invalid key encoding", e);
}
}