List of usage examples for org.bouncycastle.asn1.cryptopro CryptoProObjectIdentifiers gostR3410_94
ASN1ObjectIdentifier gostR3410_94
To view the source code for org.bouncycastle.asn1.cryptopro CryptoProObjectIdentifiers gostR3410_94.
Click Source Link
From source file:org.xwiki.crypto.internal.asymmetric.keyfactory.DefaultKeyFactory.java
License:Open Source License
private String getKeyFactoryHint(ASN1Object keyInfo) { ASN1ObjectIdentifier algId = getAlgorithmId(keyInfo); String hint = null;//w w w . j a va 2 s. c o m if (RSAUtil.isRsaOid(algId)) { hint = "RSA"; } else if (DSAUtil.isDsaOid(algId)) { hint = "DSA"; } else if (algId.equals(PKCSObjectIdentifiers.dhKeyAgreement) || algId.equals(X9ObjectIdentifiers.dhpublicnumber)) { hint = "DH"; } else if (algId.equals(OIWObjectIdentifiers.elGamalAlgorithm)) { hint = "ElGamal"; } else if (algId.equals(CryptoProObjectIdentifiers.gostR3410_94)) { hint = "GOST3410"; } if (hint == null) { throw new UnsupportedOperationException("Asymmetric key algorithm not supported: " + algId.getId()); } return hint; }