Secp256k1KeyIdentity class
- Inheritance
-
- Object
- SignIdentity
- Secp256k1KeyIdentity
Constructors
- Secp256k1KeyIdentity(PublicKey publicKey, BinaryBlob _privateKey)
Properties
Methods
-
getAccountId(
) → Uint8List -
getKeyPair(
) → Secp256k1KeyPair - Return a copy of the key pair.
-
getPrincipal(
) → Principal -
Get the principal represented by this identity. Normally should be a
Principal.selfAuthenticating()
.inherited -
getPublicKey(
) → Secp256k1PublicKey -
Return the public key.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
sign(
Uint8List blob) → Future< Uint8List> -
Signs a blob of data, with this identity's private key.
@param blob - challenge to sign with this identity's secretKey, producing a signature
override
-
toJSON(
) → JsonableSecp256k1Identity - Serialize this key to JSON.
-
toString(
) → String -
A string representation of this object.
inherited
-
transformRequest(
HttpAgentRequest request) → Future -
Transform a request into a signed version of the request. This is done last
after the transforms on the body of a request. The returned object can be
anything, but must be serializable to CBOR.
@param request - internet computer request to transform
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromJSON(
String json) → Secp256k1KeyIdentity -
fromKeyPair(
BinaryBlob publicKey, BinaryBlob privateKey) → Secp256k1KeyIdentity -
fromParsedJson(
JsonableSecp256k1Identity obj) → Secp256k1KeyIdentity -
fromSecretKey(
Uint8List secretKey) → Secp256k1KeyIdentity