public class ECDSAKeyPairX509Codec extends java.lang.Object implements IKeyPairCodec
RAW_FORMAT, X509_FORMAT
Constructor and Description |
---|
ECDSAKeyPairX509Codec() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object[] |
decodePriAndPubKey(byte[] aPriKey) |
java.security.PrivateKey |
decodePrivateKey(byte[] aInput)
Decodes an instance of an external private key into its native Java
representation.
|
java.security.PublicKey |
decodePublicKey(byte[] aInput)
Decodes an instance of an external public key into its native Java
representation.
|
byte[] |
encodePrivateKey(java.security.PrivateKey aKey)
Encodes an instance of a private key for storage or transmission purposes.
|
byte[] |
encodePrivateKey(java.security.PrivateKey aPriKey,
java.security.PublicKey aPubKey) |
byte[] |
encodePublicKey(java.security.PublicKey aKey)
Encodes an instance of a public key for storage or transmission purposes.
|
int |
getFormatID()
Returns the unique identifier (within this library) of the format used
to externalise public and private keys.
|
tr.gov.tubitak.uekae.esya.asn.x509.SubjectPublicKeyInfo |
getSubjectPublicKeyInfo(java.security.PublicKey aKey) |
tr.gov.tubitak.uekae.esya.asn.x509.AlgorithmIdentifier |
toAlgID(ECDomainParameter aDomainParameter) |
ECDomainParameter |
toDomainParameters(tr.gov.tubitak.uekae.esya.asn.x509.AlgorithmIdentifier aAlgID) |
tr.gov.tubitak.uekae.esya.asn.x509.AlgorithmIdentifier |
toUnCompressedAlgID(ECDomainParameter aDomainParameter) |
public int getFormatID()
IKeyPairCodec
Returns the unique identifier (within this library) of the format used to externalise public and private keys.
getFormatID
in interface IKeyPairCodec
public tr.gov.tubitak.uekae.esya.asn.x509.AlgorithmIdentifier toAlgID(ECDomainParameter aDomainParameter) throws com.objsys.asn1j.runtime.Asn1Exception, java.io.IOException
com.objsys.asn1j.runtime.Asn1Exception
java.io.IOException
public tr.gov.tubitak.uekae.esya.asn.x509.AlgorithmIdentifier toUnCompressedAlgID(ECDomainParameter aDomainParameter) throws com.objsys.asn1j.runtime.Asn1Exception, java.io.IOException
com.objsys.asn1j.runtime.Asn1Exception
java.io.IOException
public byte[] encodePublicKey(java.security.PublicKey aKey)
IKeyPairCodec
Encodes an instance of a public key for storage or transmission purposes.
encodePublicKey
in interface IKeyPairCodec
aKey
- the non-null key to encode.public tr.gov.tubitak.uekae.esya.asn.x509.SubjectPublicKeyInfo getSubjectPublicKeyInfo(java.security.PublicKey aKey) throws com.objsys.asn1j.runtime.Asn1Exception, java.io.IOException
com.objsys.asn1j.runtime.Asn1Exception
java.io.IOException
public byte[] encodePrivateKey(java.security.PrivateKey aKey)
IKeyPairCodec
Encodes an instance of a private key for storage or transmission purposes.
encodePrivateKey
in interface IKeyPairCodec
aKey
- the non-null key to encode.public byte[] encodePrivateKey(java.security.PrivateKey aPriKey, java.security.PublicKey aPubKey)
public ECDomainParameter toDomainParameters(tr.gov.tubitak.uekae.esya.asn.x509.AlgorithmIdentifier aAlgID) throws com.objsys.asn1j.runtime.Asn1Exception, java.io.IOException, EllipticCurveException
com.objsys.asn1j.runtime.Asn1Exception
java.io.IOException
EllipticCurveException
public java.security.PublicKey decodePublicKey(byte[] aInput)
IKeyPairCodec
Decodes an instance of an external public key into its native Java representation.
decodePublicKey
in interface IKeyPairCodec
aInput
- the source of the externalised key to decode.public java.security.PrivateKey decodePrivateKey(byte[] aInput)
IKeyPairCodec
Decodes an instance of an external private key into its native Java representation.
decodePrivateKey
in interface IKeyPairCodec
aInput
- the source of the externalised key to decode.public java.lang.Object[] decodePriAndPubKey(byte[] aPriKey)
Copyright © 2025. All rights reserved.