Class: LedgerSigner
Signs with the key at one derivation path on a Ledger device.
Before each signature it reads the public key again and fails with
KeyMismatch if it differs, which happens when another device is connected
or the device was unlocked with a different seed or passphrase.
Use TransactionSigner.from_ledger to sign with it through the transaction
builder, which passes it the transaction's objects so the device shows what
the transaction does.
Extends
UniffiAbstractObject
Implements
Properties
[destructorGuardSymbol]
readonly [destructorGuardSymbol]: UniffiGcObject;
[pointerLiteralSymbol]
readonly [pointerLiteralSymbol]: bigint;
[uniffiTypeNameSymbol]
readonly [uniffiTypeNameSymbol]: "LedgerSigner" = "LedgerSigner";
Methods
address()
address(): AddressLike;
The address of the signing key.
Returns
Implementation of
path()
path(): string;
The derivation path of the signing key.
Returns
string
Implementation of
publicKey()
publicKey(): Ed25519PublicKeyLike;
The public key that signs.
Returns
Implementation of
signPersonalMessage()
signPersonalMessage(message, asyncOpts_?): Promise<UserSignatureLike>;
Sign a personal message.
Parameters
message
asyncOpts_?
signal
AbortSignal
Returns
Promise<UserSignatureLike>
Implementation of
LedgerSignerLike.signPersonalMessage
signTransaction()
signTransaction(transaction, asyncOpts_?): Promise<UserSignatureLike>;
Sign a transaction without its input objects. Fails with
BlindSigningDisabled if blind signing is disabled in the IOTA app's
settings.
Parameters
transaction
asyncOpts_?
signal
AbortSignal
Returns
Promise<UserSignatureLike>
Implementation of
LedgerSignerLike.signTransaction
signTransactionWithObjects()
signTransactionWithObjects(
transaction,
objects,
asyncOpts_?
): Promise<UserSignatureLike>;
Sign a transaction, passing its input objects so the device can clear-sign it. Falls back to blind signing with an IOTA app older than 1.0.
Parameters
transaction
objects
asyncOpts_?
signal
AbortSignal
Returns
Promise<UserSignatureLike>
Implementation of
LedgerSignerLike.signTransactionWithObjects
uniffiDestroy()
uniffiDestroy(): void;
Explicitly tell Rust to destroy the native peer that backs this object.
Once this method has been called, any following method calls will throw an error.
Can be called more than once.
Returns
void
Overrides
UniffiAbstractObject.uniffiDestroy
uniffiUse()
uniffiUse<T>(block): T;
A convenience method to use this object, then destroy it after its use.
Type Parameters
T
T
Parameters
block
(obj) => T
Returns
T
Inherited from
UniffiAbstractObject.uniffiUse
instanceOf()
static instanceOf(obj_): obj_ is LedgerSigner;
Parameters
obj_
any
Returns
obj_ is LedgerSigner