EcKeyPairData class
P-256 / P-384 / P-521 key pair.
There are many formats for storing elliptic curve key parameters. If you are encoding/decoding JWK (JSON Web Key) format, use package:jwk.
Related classes
Algorithms that use this class
- Inheritance
-
- Object
- KeyPair
- KeyPairData
- EcKeyPairData
- Implemented types
Constructors
-
EcKeyPairData({required List<
int> d, required List<int> x, required List<int> y, required KeyPairType<KeyPairData, PublicKey> type, String? debugLabel}) - Constructs a private key with elliptic curve parameters.
Properties
-
d
→ List<
int> -
Elliptic curve private key component
d
(confidential).no setter - debugLabel → String?
-
Debugging label.
final
- hasBeenDestroyed → bool
-
Whether destroy has been called.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setteroverride
- publicKey → EcPublicKey
-
Public key.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
type
→ KeyPairType<
KeyPairData, PublicKey> -
Type of the key pair.
finalinherited
-
x
→ List<
int> -
Elliptic curve public key component
x
(not confidential).final -
y
→ List<
int> -
Elliptic curve public key component
y
(not confidential).final
Methods
-
copy(
) → EcKeyPairData -
Copies the private key.
override
-
destroy(
) → void -
Overwrites sensitive parts of the private key data with zeroes and
prevents the private key from being used anymore.
override
-
extract(
) → Future< EcKeyPairData> -
Reads the private key into memory.
override
-
extractPublicKey(
) → Future< EcPublicKey> -
Reads the public key.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDer(
) → Uint8List - Constructs DER encoding of this public key.
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
parseDer(
Uint8List der, {required KeyPairType< KeyPairData, PublicKey> type}) → EcKeyPairData - Parses DER-encoded EC public key.