You're Invited: Meet the Socket team at BSidesSF and RSAC - April 27 - May 1.RSVP
Socket
Sign inDemoInstall
Socket

@ledgerhq/hw-app-btc

Package Overview
Dependencies
Maintainers
20
Versions
449
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ledgerhq/hw-app-btc - npm Package Compare versions

Comparing version

to
6.27.2-nightly.0

.turbo/turbo-build.log

5

lib-es/newops/appClient.js

@@ -81,6 +81,3 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {

switch (_a.label) {
case 0: return [4 /*yield*/, this.transport.send(CLA_BTC, ins, 0, 0, data, [
0x9000,
0xe000,
])];
case 0: return [4 /*yield*/, this.transport.send(CLA_BTC, ins, 0, 0, data, [0x9000, 0xe000])];
case 1:

@@ -87,0 +84,0 @@ response = _a.sent();

@@ -84,6 +84,3 @@ "use strict";

switch (_a.label) {
case 0: return [4 /*yield*/, this.transport.send(CLA_BTC, ins, 0, 0, data, [
0x9000,
0xe000,
])];
case 0: return [4 /*yield*/, this.transport.send(CLA_BTC, ins, 0, 0, data, [0x9000, 0xe000])];
case 1:

@@ -90,0 +87,0 @@ response = _a.sent();

23

package.json
{
"name": "@ledgerhq/hw-app-btc",
"version": "6.27.1",
"version": "6.27.2-nightly.0",
"description": "Ledger Hardware Wallet Bitcoin Application API",

@@ -30,7 +30,8 @@ "keywords": [

"dependencies": {
"@ledgerhq/hw-transport": "^6.27.1",
"@ledgerhq/logs": "^6.10.0",
"@ledgerhq/hw-transport": "^6.27.2-nightly.0",
"@ledgerhq/logs": "^6.10.1-nightly.0",
"bip32-path": "^0.4.2",
"bitcoinjs-lib": "^5.2.0",
"bs58": "^4.0.1",
"bs58check": "^2.1.2",
"invariant": "^2.2.4",

@@ -43,2 +44,8 @@ "ripemd160": "2",

},
"devDependencies": {
"@ledgerhq/hw-transport-mocker": "^6.27.2-nightly.0",
"@ledgerhq/hw-transport-node-speculos": "^6.27.2-nightly.0",
"axios": "^0.25.0"
},
"gitHead": "dd0dea64b58e5a9125c8a422dcffd29e5ef6abec",
"scripts": {

@@ -48,5 +55,7 @@ "clean": "bash ../../script/clean.sh",

"watch": "bash ../../script/watch.sh",
"doc": "bash ../../script/doc.sh"
},
"gitHead": "9639f96a970e1f46e9e39d0c2c361ce2289923be"
}
"doc": "bash ../../script/doc.sh",
"lint": "eslint ./src --no-error-on-unmatched-pattern --ext .ts,.tsx",
"lint:fix": "pnpm lint --fix",
"test": "jest"
}
}

@@ -34,5 +34,7 @@ import bippath from "bip32-path";

export function getXpubComponents(
xpub: string
): { chaincode: Buffer; pubkey: Buffer; version: number } {
export function getXpubComponents(xpub: string): {
chaincode: Buffer;
pubkey: Buffer;
version: number;
} {
const xpubBuf: Buffer = bs58check.decode(xpub);

@@ -39,0 +41,0 @@ return {

@@ -39,10 +39,4 @@ import invariant from "invariant";

): Promise<string> {
const {
version,
inputs,
outputs,
locktime,
nExpiryHeight,
extraData,
} = transaction;
const { version, inputs, outputs, locktime, nExpiryHeight, extraData } =
transaction;

@@ -49,0 +43,0 @@ if (!outputs || !locktime) {

@@ -42,6 +42,10 @@ import Transport from "@ledgerhq/hw-transport";

): Promise<Buffer> {
let response: Buffer = await this.transport.send(CLA_BTC, ins, 0, 0, data, [
0x9000,
0xe000,
]);
let response: Buffer = await this.transport.send(
CLA_BTC,
ins,
0,
0,
data,
[0x9000, 0xe000]
);
while (response.readUInt16BE(response.length - 2) === 0xe000) {

@@ -48,0 +52,0 @@ if (!cci) {

@@ -430,5 +430,6 @@ /* eslint-disable @typescript-eslint/no-non-null-assertion */

}
private decodeBip32Derivation(
buffer: Buffer
): { masterFingerprint: Buffer; path: number[] } {
private decodeBip32Derivation(buffer: Buffer): {
masterFingerprint: Buffer;
path: number[];
} {
const buf = new BufferReader(buffer);

@@ -447,5 +448,6 @@ return this.readBip32Derivation(buf);

}
private readBip32Derivation(
buf: BufferReader
): { masterFingerprint: Buffer; path: number[] } {
private readBip32Derivation(buf: BufferReader): {
masterFingerprint: Buffer;
path: number[];
} {
const masterFingerprint = buf.readSlice(4);

@@ -471,5 +473,7 @@ const path: number[] = [];

}
private decodeTapBip32Derivation(
buffer: Buffer
): { hashes: Buffer[]; masterFingerprint: Buffer; path: number[] } {
private decodeTapBip32Derivation(buffer: Buffer): {
hashes: Buffer[];
masterFingerprint: Buffer;
path: number[];
} {
const buf = new BufferReader(buffer);

@@ -476,0 +480,0 @@ const hashCount = buf.readVarInt();

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet