![Incoming HIVE Ledger wallet](https://files.peakd.com/file/peakd-hive/engrave/EowF9ezqJkPjHhLKMx9NjA82sqpuhKVddGJHDgbd5zyo9TsVhKtGc1714xmomVXPeLL) It's been a couple of months since @netuoso [published the initial version of the Hive Ledger App](https://hive.blog/hive-139531/@netuoso/hive-application-for-the-ledger-nano-s-x-hardware-wallet). In order to get official support from Ledger (i.e. the possibility to install it from Ledger Live), we need to meet several requirements. And I'm trying to fulfill them all so we could benefit from the hardware wallet support. # Code review First, we need to make sure that the application is stable and secure. I already made a preliminary review of the app and created a Pull Request with some fixes. The next step will be to review the code from a security perspective, following the guidelines provided by Ledger. This requires a bit more work and knowledge than validating transactions serialization etc, but we will get there. * https://github.com/netuoso/ledger-app-hive/pull/5/ # Javascript library To simplify communication with the ledger app, I created a JavaScript/Typescript library. It's really easy to use it with NodeJS. The library covers every functionality supported by the app. Example usage: ```typescript import Hive from '@engrave/ledger-app-hive'; import TransportNodeHid from '@ledgerhq/hw-transport-node-hid'; import Transport from '@ledgerhq/hw-transport'; ( async () => { console.log('Unlock your ledger....'); const transport = await TransportNodeHid.create(); console.log(`Established connection with Ledger Nano S`); try { const hive = new Hive(transport); const {version, arbitraryData} = await hive.getAppConfiguration(); console.log("Current version:", version); console.log("Arbitary data enabled:", arbitraryData); const publicKey = await hive.getPublicKey(`48'/13'/0'/0'/0'`); console.log("Public key:", publicKey); } catch (e) { console.error(e); } finally { transport.close(); } })(); ``` ## API * [getAppConfiguration](#getappconfiguration) * [getPublicKey](#getpublickey) * [signTransaction](#signtransaction) ### getAppConfiguration Get current configuration for HIVE App installed on a Ledger. ```typescript async getAppConfiguration(): Promise<{version: string, arbitraryData: boolean}> ``` ### getPublicKey Retrieve public key from specified BIP32 path. You can set an additional parameter `confirm: boolean` which will ask the user to confirm the Public Key on his Ledger before returning it. ```typescript async getPublicKey(path: string, confirm?: boolean): Promise<{publicKey: string}> { ``` ### signTransaction Sign basic transactions with the specified key path. This method will return signed transactions (a transaction with additional `signatures` property). Please note that extensions are not yet supported for most transactions and operations (except `beneficiaries` for `comment_options`). ```typescript async signTransaction(tx: Transaction, path: string): Promise ``` Please be aware that the current implementation of the HIVE Ledger App does not support multisig. This could be also a cool feature and we might add it someday. For now, let's focus on publishing it. The library is open-source and available on Gitlab and NPM: * https://gitlab.com/engrave/ledger/ledger-app-hive # Ledger Companion App To prove that the application is working correctly, Ledger requires a sample Companion App. I prepared an initial design for a new wallet app and will start developing it soon. The plan is to make it as a wallet targeted at large stakeholders willing to invest in HIVE. It will be focused on governance (voting for witnesses and proposals) and the most significant chain news. ![It will be possible to create a new Hive account directly from app](https://files.peakd.com/file/peakd-hive/engrave/23wWk6s648pDWBsa1JoJunzjwiXRo9f49h5gbvBg2q65FmshLwjh7mpbHEcrqHRdQmJAg) ![Hive Ledger will display all significant parameters of your account](https://files.peakd.com/file/peakd-hive/engrave/23vsBhgnPDwTJcjG9YXJp5qfx6828bE9xVTzR6HsZW6XEskYJBs1bZoG99HkjsHBiau1W) ![It will be possible to vote on witnesses and perform other governance actions](https://files.peakd.com/file/peakd-hive/engrave/23wWnW3EENBacfW6UgsUncKqKVHKiQXRRNftBf1qpAp9GvXMJWu9x7ihqNU1wPktLyhdE) Follow me to be up to date with incoming development updates! ***
**Click on the image to vote for @engrave witness:** [![banner_engrave 100.png](https://images.hive.blog/DQmUghvic5TCPPvVkB4iB7eXmgQ3RQ4L8jkVizvuCBW8RMT/banner_engrave%20100.png)](https://hivesigner.com/sign/account-witness-vote?witness=engrave&approve=1)

See: JavaScript library for Ledger Nano S HIVE application by @engrave