public class RSAUtils extends Object
| Constructor and Description |
|---|
RSAUtils() |
| Modifier and Type | Method and Description |
|---|---|
static String |
getPEMFromPrivateKey(PrivateKey privateKey)
Return the private key in a PEM formatted String.
|
static String |
getPEMFromPublicKey(PublicKey publicKey)
Return the public key in a PEM formatted String.
|
static RSAPrivateKey |
getPrivateKeyFromPEM(String privateKey)
Return a Private Key from the provided private key in PEM format.
|
static RSAPublicKey |
getPublicKeyFromPEM(String publicKey)
Return a PublicKey from the public key pem string.
|
public static String getPEMFromPrivateKey(PrivateKey privateKey)
privateKey - The private key.public static String getPEMFromPublicKey(PublicKey publicKey)
publicKey - The publicKey key.public static RSAPrivateKey getPrivateKeyFromPEM(String privateKey)
privateKey - the private key in string format.public static RSAPublicKey getPublicKeyFromPEM(String publicKey)
publicKey - the public in PEM format.Copyright © 2017. All rights reserved.