public final class ECPrivateKey
extends com.ibm.security.pkcs8.PrivateKeyInfo
implements java.security.interfaces.ECPrivateKey, java.security.interfaces.ECKey, java.io.Serializable
EXPLICIT TAGS
ECPrivateKey ::= SEQUENCE {
version INTEGER { ecPrivkeyVer1(1) } (ecPrivkeyVer1),
privateKey OCTET STRING,
parameters [0] ECDomainParameters {{ SECGCurveNames }} OPTIONAL,
publicKey [1] BIT STRING OPTIONAL
}
We currently ignore the optional parameters and publicKey fields. We
require that the parameters are encoded as part of the AlgorithmIdentifier,
not in the private key structure.| Constructor and Description |
|---|
ECPrivateKey(java.math.BigInteger s,
java.security.spec.ECParameterSpec params)
Construct a key from its components.
|
ECPrivateKey(byte[] encoded)
Construct a key from its encoding.
|
| Modifier and Type | Method and Description |
|---|---|
java.security.spec.ECParameterSpec |
getParams() |
java.math.BigInteger |
getS() |
void |
zeroize()
This function zeroizes the key so that it isn't in memory
|
addAttribute, addAttributes, clone, encode, equals, getAlgorithm, getAlgorithmId, getAttribute, getAttributes, getEncoded, getFormat, getKeyBytes, hasAttribute, hasAttributes, hashCode, parseKey, parseKey, toStringpublic ECPrivateKey(byte[] encoded)
throws java.security.InvalidKeyException
encoded - java.security.InvalidKeyExceptionpublic ECPrivateKey(java.math.BigInteger s,
java.security.spec.ECParameterSpec params)
throws java.security.InvalidKeyException,
java.security.spec.InvalidParameterSpecException
s - params - java.security.InvalidKeyExceptionjava.security.spec.InvalidParameterSpecExceptionpublic java.math.BigInteger getS()
getS in interface java.security.interfaces.ECPrivateKeypublic java.security.spec.ECParameterSpec getParams()
getParams in interface java.security.interfaces.ECKeypublic void zeroize()
© Portions Copyright 2003, 2012 IBM Corporation. All rights reserved.
© Portions Copyright 2003, 2012, Oracle and/or its affiliates. All rights reserved.