diff options
-rw-r--r-- | src/js/bitcoinjs-extensions.js | 22 | ||||
-rw-r--r-- | src/js/index.js | 14 | ||||
-rw-r--r-- | tests/spec/tests.js | 14 |
3 files changed, 50 insertions, 0 deletions
diff --git a/src/js/bitcoinjs-extensions.js b/src/js/bitcoinjs-extensions.js index a3f86cf..4389969 100644 --- a/src/js/bitcoinjs-extensions.js +++ b/src/js/bitcoinjs-extensions.js | |||
@@ -1418,4 +1418,26 @@ bitcoinjs.bitcoin.networks.phore = { | |||
1418 | pubKeyHash: 0x37, | 1418 | pubKeyHash: 0x37, |
1419 | scriptHash: 0x0D, | 1419 | scriptHash: 0x0D, |
1420 | wif: 0xD4, | 1420 | wif: 0xD4, |
1421 | }; | ||
1422 | |||
1423 | bitcoinjs.bitcoin.networks.blocknode = { | ||
1424 | messagePrefix: '\x18Blocknode Signed Message:\n', | ||
1425 | bip32: { | ||
1426 | public: 0x0488b21e, | ||
1427 | private: 0x0488ade4 | ||
1428 | }, | ||
1429 | pubKeyHash: 0x19, | ||
1430 | scriptHash: 0x3F, | ||
1431 | wif: 0x4b, | ||
1432 | }; | ||
1433 | |||
1434 | bitcoinjs.bitcoin.networks.blocknode_testnet = { | ||
1435 | messagePrefix: '\x18Blocknode Testnet Signed Message:\n', | ||
1436 | bip32: { | ||
1437 | public: 0x043587cf, | ||
1438 | private: 0x04358394 | ||
1439 | }, | ||
1440 | pubKeyHash: 0x55, | ||
1441 | scriptHash: 0x7d, | ||
1442 | wif: 0x89, | ||
1421 | }; \ No newline at end of file | 1443 | }; \ No newline at end of file |
diff --git a/src/js/index.js b/src/js/index.js index f33d025..9d94765 100644 --- a/src/js/index.js +++ b/src/js/index.js | |||
@@ -1703,6 +1703,20 @@ | |||
1703 | }, | 1703 | }, |
1704 | }, | 1704 | }, |
1705 | { | 1705 | { |
1706 | name: "BND - Blocknode", | ||
1707 | onSelect: function() { | ||
1708 | network = bitcoinjs.bitcoin.networks.blocknode; | ||
1709 | setHdCoin(2941); | ||
1710 | }, | ||
1711 | }, | ||
1712 | { | ||
1713 | name: "tBND - Blocknode Testnet", | ||
1714 | onSelect: function() { | ||
1715 | network = bitcoinjs.bitcoin.networks.blocknode_testnet; | ||
1716 | setHdCoin(1); | ||
1717 | }, | ||
1718 | }, | ||
1719 | { | ||
1706 | name: "BRIT - Britcoin", | 1720 | name: "BRIT - Britcoin", |
1707 | onSelect: function() { | 1721 | onSelect: function() { |
1708 | network = bitcoinjs.bitcoin.networks.britcoin; | 1722 | network = bitcoinjs.bitcoin.networks.britcoin; |
diff --git a/tests/spec/tests.js b/tests/spec/tests.js index b1308fb..6f9d693 100644 --- a/tests/spec/tests.js +++ b/tests/spec/tests.js | |||
@@ -1348,6 +1348,20 @@ it('Allows selection of Phore', function(done) { | |||
1348 | }; | 1348 | }; |
1349 | testNetwork(done, params); | 1349 | testNetwork(done, params); |
1350 | }); | 1350 | }); |
1351 | it('Allows selection of Blocknode', function(done) { | ||
1352 | var params = { | ||
1353 | selectText: "BND - Blocknode", | ||
1354 | firstAddress: "BG8xZSAur2jYLG9VXt8dYfkKxxeR7w9bSe", | ||
1355 | }; | ||
1356 | testNetwork(done, params); | ||
1357 | }); | ||
1358 | it('Allows selection of Blocknode Testnet', function(done) { | ||
1359 | var params = { | ||
1360 | selectText: "tBND - Blocknode Testnet", | ||
1361 | firstAddress: "bSptsFyDktFSKpWveRywJsDoJA2TC6qfHv", | ||
1362 | }; | ||
1363 | testNetwork(done, params); | ||
1364 | }); | ||
1351 | 1365 | ||
1352 | // BIP39 seed is set from phrase | 1366 | // BIP39 seed is set from phrase |
1353 | it('Sets the bip39 seed from the prhase', function(done) { | 1367 | it('Sets the bip39 seed from the prhase', function(done) { |