Package net.handle.apps.simple
Class KeyConverter
java.lang.Object
net.handle.apps.simple.KeyConverter
-
Constructor Summary
ConstructorsConstructorDescriptionKeyConverter
(byte[] bytes, boolean encrypt, String outputFilename, byte[] passIn, byte[] passOut, String format) -
Method Summary
Modifier and TypeMethodDescriptionstatic PrivateKey
fromPkcs8Pem
(String pem, String passphrase) static PublicKey
fromX509Pem
(String pem) static void
static PrivateKey
privateKeyFromBytes
(byte[] bytes, boolean encrypted, String passphrase) static PublicKey
publicKeyFromBytes
(byte[] bytes) static String
toPkcs8EncryptedPem
(PrivateKey privateKey, String passphrase) static String
toPkcs8UnencryptedPem
(PrivateKey privateKey) static String
-
Constructor Details
-
KeyConverter
-
-
Method Details
-
toX509Pem
-
publicKeyFromBytes
- Throws:
Exception
-
fromX509Pem
- Throws:
Exception
-
toPkcs8UnencryptedPem
-
toPkcs8EncryptedPem
-
privateKeyFromBytes
public static PrivateKey privateKeyFromBytes(byte[] bytes, boolean encrypted, String passphrase) throws Exception - Throws:
Exception
-
fromPkcs8Pem
- Throws:
Exception
-
main
- Throws:
Exception
-