Class: SchnorrMultikey ​
Defined in: multikey/index.ts:28
SchnorrMultikey is an implementation of 2.1.1 Multikey. The publicKeyMultibase value of the verification method MUST be a base-58-btc Multibase encoding of a Multikey encoded secp256k1 public key. The secretKeyMultibase value of the verification method MUST be a Multikey encoding of a secp256k1 secret key. SchnorrMultikey
Implements ​
Constructors ​
Constructor ​
new SchnorrMultikey(
params):SchnorrMultikey
Defined in: multikey/index.ts:51
Creates an instance of SchnorrMultikey.
Parameters ​
params ​
MultikeyParams
The parameters to create the multikey
Returns ​
SchnorrMultikey
Throws ​
if neither a publicKey nor a privateKey is provided
Properties ​
controller ​
readonlycontroller:string
Defined in: multikey/index.ts:36
Implementation of ​
id ​
readonlyid:string
Defined in: multikey/index.ts:33
Implementation of ​
type ​
readonlystatictype:string='Multikey'
Defined in: multikey/index.ts:30
Accessors ​
keys ​
Get Signature ​
get keys():
SchnorrKeyPair
Defined in: multikey/index.ts:69
Returns ​
Implementation of ​
publicKey ​
Get Signature ​
get publicKey():
CompressedSecp256k1PublicKey
Defined in: multikey/index.ts:76
Returns ​
Implementation of ​
secretKey ​
Get Signature ​
get secretKey():
Secp256k1SecretKey
Defined in: multikey/index.ts:83
Returns ​
Implementation of ​
signer ​
Get Signature ​
get signer():
boolean
Defined in: multikey/index.ts:235
Returns ​
boolean
Implementation of ​
Methods ​
fromVerificationMethod() ​
fromVerificationMethod(
verificationMethod):Multikey
Defined in: multikey/index.ts:185
Convert a verification method to a multikey.
Parameters ​
verificationMethod ​
The verification method to convert.
Returns ​
Multikey instance.
Throws ​
if the verification method is missing required fields. if the verification method has an invalid type. if the publicKeyMultibase has an invalid prefix.
Implementation of ​
Multikey.fromVerificationMethod
fullId() ​
fullId():
string
Defined in: multikey/index.ts:157
Get the full id of the multikey
Returns ​
string
The full id of the multikey
Implementation of ​
json() ​
json():
MultikeyObject
Defined in: multikey/index.ts:243
Convert the multikey to a JSON object.
Returns ​
The multikey as a JSON object.
Implementation of ​
sign() ​
sign(
data,opts?):Bytes
Defined in: multikey/index.ts:111
Produce a signature over arbitrary data using schnorr or ecdsa.
Parameters ​
data ​
Data to be signed.
opts? ​
CryptoOptions
Options for signing.
Returns ​
Signature byte array.
Throws ​
if no private key is provided.
Implementation of ​
toCryptosuite() ​
toCryptosuite(
cryptosuite?):Cryptosuite
Defined in: multikey/index.ts:99
Constructs an instance of Cryptosuite from the current Multikey instance.
Parameters ​
cryptosuite? ​
"bip340-jcs-2025" | "bip340-rdfc-2025"
Returns ​
toVerificationMethod() ​
toVerificationMethod():
DidVerificationMethod
Defined in: multikey/index.ts:166
Convert the multikey to a verification method.
Returns ​
The verification method.
Implementation of ​
verify() ​
verify(
signature,data,opts?):boolean
Defined in: multikey/index.ts:141
Verify a signature using schnorr or ecdsa.
Parameters ​
signature ​
Signature for verification.
data ​
Data for verification.
opts? ​
CryptoOptions
Options for signing.
Returns ​
boolean
If the signature is valid against the public key.
Implementation of ​
create() ​
staticcreate(params):SchnorrMultikey
Defined in: multikey/index.ts:265
Static convenience method to create a new Multikey instance.
Parameters ​
params ​
MultikeyParams
The parameters to create the multikey
Returns ​
SchnorrMultikey
A new Multikey instance
Throws ​
if neither a publicKey nor a privateKey is provided
fromPrivateKey() ​
staticfromPrivateKey(params):SchnorrMultikey
Defined in: multikey/index.ts:277
Creates a Multikey instance from a private key
Parameters ​
params ​
The parameters to create the multikey
Returns ​
SchnorrMultikey
The new multikey instance
fromPublicKey() ​
staticfromPublicKey(params):Multikey
Defined in: multikey/index.ts:299
Creates a Multikey instance from a public key
Parameters ​
params ​
The parameters to create the multikey
Returns ​
The new multikey instance
fromPublicKeyMultibase() ​
staticfromPublicKeyMultibase(params):SchnorrMultikey
Defined in: multikey/index.ts:315
Creates a Multikey instance from a public key multibase.
Parameters ​
params ​
See FromPublicKeyMultibaseParams for details.
Returns ​
SchnorrMultikey
The new multikey instance.