public class EcKeyUtil extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
EC |
protected String |
provider |
protected SecureRandom |
secureRandom |
| Constructor and Description |
|---|
EcKeyUtil() |
EcKeyUtil(String provider,
SecureRandom secureRandom) |
| Modifier and Type | Method and Description |
|---|---|
PublicKey |
fromPemEncoded(String pem) |
KeyPair |
generateKeyPair(ECParameterSpec spec) |
protected KeyFactory |
getKeyFactory() |
protected KeyPairGenerator |
getKeyPairGenerator() |
boolean |
isAvailable() |
static String |
pemEncode(PublicKey publicKey) |
ECPrivateKey |
privateKey(BigInteger d,
ECParameterSpec spec) |
ECPublicKey |
publicKey(BigInteger x,
BigInteger y,
ECParameterSpec spec) |
public static final String EC
protected String provider
protected SecureRandom secureRandom
public EcKeyUtil()
public EcKeyUtil(String provider, SecureRandom secureRandom)
public ECPublicKey publicKey(BigInteger x, BigInteger y, ECParameterSpec spec) throws JoseException
JoseExceptionpublic ECPrivateKey privateKey(BigInteger d, ECParameterSpec spec) throws JoseException
JoseExceptionpublic KeyPair generateKeyPair(ECParameterSpec spec) throws JoseException
JoseExceptionprotected KeyFactory getKeyFactory() throws JoseException
JoseExceptionprotected KeyPairGenerator getKeyPairGenerator() throws JoseException
JoseExceptionpublic PublicKey fromPemEncoded(String pem) throws JoseException, InvalidKeySpecException
JoseExceptionInvalidKeySpecExceptionpublic boolean isAvailable()
Copyright © 2019. All rights reserved.