public class EcPpk extends Object
| Modifier and Type | Field and Description |
|---|---|
static Object |
cache |
String |
defaultPem |
protected EcPk |
defaultPk |
Object |
jwk |
CryptoKey |
key |
protected forge.ppk |
ppk |
CryptoKey |
signKey |
| Modifier | Constructor and Description |
|---|---|
protected |
EcPpk() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj)
Returns true iff the PEM forms of the public private keypair match.
|
static EcPpk |
fromPem(String pem)
Decodes a PEM encoded PrivateKeyInfo (PKCS#8) or RSAPrivateKey (PKCS#1) formatted RSA Public Key.
|
static EcPpk |
generateKey()
Generates an RSA Keypair synchronously.
|
static void |
generateKeyAsync(org.stjs.javascript.functions.Callback1<EcPpk> callback)
Generates an RSA Keypair using web workers.
|
boolean |
inArray(org.stjs.javascript.Array<EcPpk> ppks)
Returns true if this PPK is in an array of PPKs.
|
Object |
toJwk() |
String |
toPem()
Encodes the private key into a PEM encoded RSAPrivateKey (PKCS#1) formatted RSA Public Key.
|
EcPk |
toPk()
Extracts the public key portion from the public private keypair.
|
String |
toPkcs1Pem()
Encodes the private key into a PEM encoded RSAPrivateKey (PKCS#1) formatted RSA Public Key.
|
ArrayBuffer |
toPkcs8() |
String |
toPkcs8Pem()
Encodes the private key into a PEM encoded PrivateKeyInfo (PKCS#8) formatted RSA Public Key.
|
public static Object cache
public String defaultPem
public Object jwk
public CryptoKey key
public CryptoKey signKey
protected forge.ppk ppk
protected EcPk defaultPk
public static EcPpk fromPem(String pem)
{string} - pem PEM as a string.public static void generateKeyAsync(org.stjs.javascript.functions.Callback1<EcPpk> callback)
{function(EcPpk)} - callback Method called when the keypair is generated.public static EcPpk generateKey()
public boolean equals(Object obj)
public String toPem()
public String toPkcs1Pem()
public String toPkcs8Pem()
public Object toJwk()
public ArrayBuffer toPkcs8()
public EcPk toPk()
public boolean inArray(org.stjs.javascript.Array<EcPpk> ppks)
{Array} - ppks Array of ppksCopyright © 2019 Eduworks Corporation. All rights reserved.