From: Pawel Cioch Date: Wed, 11 Sep 2019 03:11:28 +0000 (-0500) Subject: Added HUSH3 encoding and kept old as Legacy for users to be able to cross verify X-Git-Url: https://git.immae.eu/?p=perso%2FImmae%2FProjets%2FCryptomonnaies%2FBIP39.git;a=commitdiff_plain;h=318ec4dc9f37c2ea4fc8de2fd487602c3cd05cb9;ds=sidebyside Added HUSH3 encoding and kept old as Legacy for users to be able to cross verify --- diff --git a/src/js/bitcoinjs-extensions.js b/src/js/bitcoinjs-extensions.js index b37f58f..1a28628 100644 --- a/src/js/bitcoinjs-extensions.js +++ b/src/js/bitcoinjs-extensions.js @@ -1462,6 +1462,17 @@ bitcoinjs.bitcoin.networks.hush = { wif: 0x80, }; +bitcoinjs.bitcoin.networks.hush3 = { + messagePrefix: '\x18Hush Signed Message:\n', + bip32: { + public: 0x0488B21E, + private: 0x0488ADE4, + }, + pubKeyHash: 0x3C, + scriptHash: 0x55, + wif: 0xBC, +}; + bitcoinjs.bitcoin.networks.zclassic = { messagePrefix: '\x18Zcash Signed Message:\n', bip32: { diff --git a/src/js/index.js b/src/js/index.js index 4fac6f1..ab7cc00 100644 --- a/src/js/index.js +++ b/src/js/index.js @@ -2185,11 +2185,18 @@ }, }, { - name: "HUSH - Hush", + name: "HUSH - Hush (Legacy)", onSelect: function() { network = bitcoinjs.bitcoin.networks.hush; setHdCoin(197); }, + }, + { + name: "HUSH - Hush3", + onSelect: function() { + network = bitcoinjs.bitcoin.networks.hush3; + setHdCoin(197); + }, }, { name: "INSN - Insane", diff --git a/tests/spec/tests.js b/tests/spec/tests.js index 6f9fd4f..c9c0e6e 100644 --- a/tests/spec/tests.js +++ b/tests/spec/tests.js @@ -1441,11 +1441,18 @@ it('Allows selection of Callisto', function(done) { }); it('Allows selection of HUSH', function(done) { var params = { - selectText: "HUSH - Hush", + selectText: "HUSH - Hush (Legacy)", firstAddress: "t1g6rLXUnJaiJuu4q4zmJjoa9Gk4fwKpiuA", }; testNetwork(done, params); }); +it('Allows selection of HUSH3', function(done) { + var params = { + selectText: "HUSH - Hush3", + firstAddress: "RXWSQhwvw5jHPGP8bjwJhWoRnMLBnuPDKD", + }; + testNetwork(done, params); +}); it('Allows selection of ExchangeCoin', function(done) { var params = { selectText: "EXCC - ExchangeCoin",