use of org.bouncycastle.asn1.x509.DSAParameter in project robovm by robovm.
the class AlgorithmParametersSpi method engineInit.
protected void engineInit(byte[] params) throws IOException {
try {
DSAParameter dsaP = DSAParameter.getInstance(ASN1Primitive.fromByteArray(params));
currentSpec = new DSAParameterSpec(dsaP.getP(), dsaP.getQ(), dsaP.getG());
} catch (ClassCastException e) {
throw new IOException("Not a valid DSA Parameter encoding.");
} catch (ArrayIndexOutOfBoundsException e) {
throw new IOException("Not a valid DSA Parameter encoding.");
}
}
Aggregations