liquidjs-lib
Advanced tools
Comparing version 6.0.2-liquid.5 to 6.0.2-liquid.6
{ | ||
"name": "liquidjs-lib", | ||
"version": "6.0.2-liquid.5", | ||
"version": "6.0.2-liquid.6", | ||
"description": "Client-side Liquid JavaScript library", | ||
@@ -60,3 +60,3 @@ "main": "./src/index.js", | ||
"bitcoin-ops": "^1.4.0", | ||
"blech32": "^1.1.1", | ||
"blech32": "^1.1.2", | ||
"bs58check": "^2.0.0", | ||
@@ -63,0 +63,0 @@ "create-hash": "^1.2.0", |
@@ -61,7 +61,2 @@ 'use strict'; | ||
const FUTURE_SEGWIT_VERSION_DIFF = 0x50; | ||
const FUTURE_SEGWIT_VERSION_WARNING = | ||
'WARNING: Sending to a future segwit version address can lead to loss of funds. ' + | ||
'End users MUST be warned carefully in the GUI and asked if they wish to proceed ' + | ||
'with caution. Wallets should verify the segwit version from the output of fromBech32, ' + | ||
'then decide when it is safe to use which version of segwit.'; | ||
function _toFutureSegwitAddress(output, network) { | ||
@@ -82,3 +77,2 @@ const data = output.slice(2); | ||
throw new TypeError('Invalid script for segwit address'); | ||
console.warn(FUTURE_SEGWIT_VERSION_WARNING); | ||
return toBech32(data, version, network.bech32); | ||
@@ -143,3 +137,8 @@ } | ||
const data = Buffer.concat([ | ||
Buffer.from([result.witnessVersion, prg.length]), | ||
Buffer.from([ | ||
result.witnessVersion | ||
? result.witnessVersion + FUTURE_SEGWIT_VERSION_DIFF | ||
: result.witnessVersion, | ||
prg.length, | ||
]), | ||
prg, | ||
@@ -245,3 +244,2 @@ ]); | ||
) { | ||
console.warn(FUTURE_SEGWIT_VERSION_WARNING); | ||
return bscript.compile([ | ||
@@ -248,0 +246,0 @@ decodedBech32.version + FUTURE_SEGWIT_VERSION_DIFF, |
@@ -12,3 +12,3 @@ import * as address from './address'; | ||
export { TaggedHashPrefix } from './crypto'; | ||
export { Psbt, PsbtTxInput, PsbtTxOutput, Signer, SignerAsync, HDSigner, HDSignerAsync, witnessStackToScriptWitness, } from './psbt'; | ||
export { Psbt, PsbtTxInput, PsbtTxOutput, Signer, SignerAsync, HDSigner, HDSignerAsync, witnessStackToScriptWitness, BlindingDataLike, } from './psbt'; | ||
export { OPS as opcodes } from './ops'; | ||
@@ -15,0 +15,0 @@ export { Transaction } from './transaction'; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
283270
8265
Updatedblech32@^1.1.2