net.ripe.rpki.commons.crypto.util
Class KeyPairFactory
java.lang.Object
net.ripe.rpki.commons.crypto.util.KeyPairFactory
public class KeyPairFactory
- extends Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ALGORITHM
public static final String ALGORITHM
- See Also:
- Constant Field Values
RPKI_KEY_PAIR_SIZE
public static final int RPKI_KEY_PAIR_SIZE
- See Also:
- Constant Field Values
PUBLIC_EXPONENT
public static final BigInteger PUBLIC_EXPONENT
- F4 Public Exponent
KeyPairFactory
public KeyPairFactory(String provider)
generate
public KeyPair generate()
decodePublicKey
public static PublicKey decodePublicKey(byte[] encoded)
- Decodes an X.509 encoded public key.
- Parameters:
encoded - the encoded public key.
- Returns:
- the PublicKey.
decodePrivateKey
public static PrivateKey decodePrivateKey(byte[] encoded)
- Decodes a PKCS#8 encoded private key. This is the default encoding for
the private key getEncoded method.
- Parameters:
encoded - the encoded data.
- Returns:
- the PrivateKey.
withProvider
public KeyPairFactory withProvider(String provider)
Copyright © 2008-2013 RIPE NCC, the Netherlands. All Rights Reserved.