Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ledgerhq/hw-app-btc

Package Overview
Dependencies
Maintainers
7
Versions
437
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 4.3.0-beta.79913151 to 4.3.0-beta.42bb5526

11

lib/Btc.js

@@ -7,2 +7,6 @@ "use strict";

var _extends2 = require("babel-runtime/helpers/extends");
var _extends3 = _interopRequireDefault(_extends2);
var _regenerator = require("babel-runtime/regenerator");

@@ -501,3 +505,4 @@

trustedInput: true,
value: Buffer.from(trustedInput, "hex")
value: Buffer.from(trustedInput, "hex"),
sequence: Buffer.alloc(4).writeUInt32LE(input.length >= 4 && typeof input[3] === "number" ? input[3] : DEFAULT_SEQUENCE, 0)
});

@@ -558,7 +563,7 @@ });

(0, _utils.foreach)(inputs, function (input, i) {
var script = inputs[i].length >= 3 && typeof inputs[i][2] === "string" ? Buffer.from(inputs[i][2], "hex") : !segwit ? regularOutputs[i].script : Buffer.concat([Buffer.from([OP_PUSHDATA1, OP_HASH160, HASH_SIZE]), _this5.hashPublicKey(publicKeys[i]), Buffer.from([OP_EQUALVERIFY, OP_CHECKSIG])]);
var pseudoTX = targetTransaction;
var pseudoTrustedInputs = segwit ? [trustedInputs[i]] : trustedInputs;
var script = inputs[i].length >= 3 && typeof inputs[i][2] === "string" ? Buffer.from(inputs[i][2], "hex") : !segwit ? regularOutputs[i].script : Buffer.concat([Buffer.from([OP_PUSHDATA1, OP_HASH160, HASH_SIZE]), _this5.hashPublicKey(publicKeys[i]), Buffer.from([OP_EQUALVERIFY, OP_CHECKSIG])]);
if (segwit) {
pseudoTX.inputs = [{ sequence: DEFAULT_SEQUENCE, script: script }];
pseudoTX.inputs = [(0, _extends3.default)({}, pseudoTX.inputs[i], { script: script })];
} else {

@@ -565,0 +570,0 @@ pseudoTX.inputs[i].script = script;

{
"name": "@ledgerhq/hw-app-btc",
"version": "4.3.0-beta.79913151",
"version": "4.3.0-beta.42bb5526",
"description": "Ledger Hardware Wallet Bitcoin Application API",

@@ -28,3 +28,3 @@ "keywords": [

"dependencies": {
"@ledgerhq/hw-transport": "^4.3.0-beta.79913151",
"@ledgerhq/hw-transport": "^4.3.0-beta.42bb5526",
"create-hash": "^1.1.3"

@@ -31,0 +31,0 @@ },

@@ -513,3 +513,9 @@ //@flow

trustedInput: true,
value: Buffer.from(trustedInput, "hex")
value: Buffer.from(trustedInput, "hex"),
sequence: Buffer.alloc(4).writeUInt32LE(
input.length >= 4 && typeof input[3] === "number"
? input[3]
: DEFAULT_SEQUENCE,
0
)
});

@@ -584,4 +590,2 @@ })

foreach(inputs, (input, i) => {
let pseudoTX = targetTransaction;
let pseudoTrustedInputs = segwit ? [trustedInputs[i]] : trustedInputs;
let script =

@@ -597,4 +601,6 @@ inputs[i].length >= 3 && typeof inputs[i][2] === "string"

]);
let pseudoTX = targetTransaction;
let pseudoTrustedInputs = segwit ? [trustedInputs[i]] : trustedInputs;
if (segwit) {
pseudoTX.inputs = [{ sequence: DEFAULT_SEQUENCE, script: script }];
pseudoTX.inputs = [{ ...pseudoTX.inputs[i], script }];
} else {

@@ -601,0 +607,0 @@ pseudoTX.inputs[i].script = script;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc