Github,
Ledger Devs Slack
@ledgerhq/hw-transport-webauthn
Allows to communicate with Ledger Hardware Wallets.
[Web] (WebAuthn) – WebAuthn api. check browser support.
Known limitation
There is a "blink" at each time there is a communication with the device due to WebAuthn. WebAuthn is meant for authentification and we use it for communication, ideally prefer WebUSB.
API
Table of Contents
TransportWebAuthn
Extends Transport
WebAuthn Transport implementation
Examples
import TransportWebAuthn from "@ledgerhq/hw-transport-webauthn";
...
TransportWebAuthn.create().then(transport => ...)
exchange
Exchange with the device using APDU protocol.
Parameters
Returns Promise<Buffer> a promise of apdu response
setScrambleKey
A scramble key is a string that xor the data exchanged.
It depends on the device app you need to exchange with.
For instance it can be "BTC" for the bitcoin app, "B0L0S" for the dashboard.
Parameters
Examples
transport.setScrambleKey("B0L0S")