public class KeyTools
extends java.lang.Object
| Constructor and Description |
|---|
KeyTools() |
| Modifier and Type | Method and Description |
|---|---|
static java.security.PrivateKey |
decodeRsaPrivateKey(byte[] encoded)
Decoding PKCS#8 Encoded private auth
|
static java.security.PublicKey |
decodeRsaPublicKey(byte[] encoded)
Decode X.509 encoded public auth
|
static byte[] |
encodeRsaPrivateKey(java.security.PrivateKey privateKey)
Build PKCS#8 Encoded private auth
|
static byte[] |
encodeRsaPublicKey(java.security.PublicKey publicKey)
Build X.509 Encoded public auth
|
static java.security.KeyPair |
generateNewRsaKey()
Generation of 1024-bit RSA auth pair
|
public static byte[] encodeRsaPublicKey(java.security.PublicKey publicKey)
publicKey - public authpublic static java.security.PublicKey decodeRsaPublicKey(byte[] encoded)
encoded - encoded authpublic static byte[] encodeRsaPrivateKey(java.security.PrivateKey privateKey)
privateKey - private authpublic static java.security.PrivateKey decodeRsaPrivateKey(byte[] encoded)
encoded - encoded authpublic static java.security.KeyPair generateNewRsaKey()