add bitcoin private testnet support

This commit is contained in:
J62
2021-03-29 19:46:51 -07:00
parent 23f393acfb
commit 1820b6ac67
3 changed files with 33 additions and 5 deletions

View File

@@ -1531,6 +1531,17 @@ libs.bitcoin.networks.bitcoinprivate = {
wif: 0x80,
};
libs.bitcoin.networks.bitcoinprivatetestnet = {
messagePrefix: '\x18BitcoinPrivate Signed Message:\n',
bip32: {
public: 0x043587CF,
private: 0x04358394,
},
pubKeyHash: 0x1957,
scriptHash: 0x19E0,
wif: 0xEF,
};
libs.bitcoin.networks.bitcoinz = {
messagePrefix: '\x18BitcoinZ Signed Message:\n',
bip32: {

View File

@@ -2389,6 +2389,13 @@
setHdCoin(183);
},
},
{
name: "BTCPt - Bitcoin Private Testnet",
onSelect: function() {
network = libs.bitcoin.networks.bitcoinprivatetestnet;
setHdCoin(1);
},
},
{
name: "BSC - Binance Smart Chain",
onSelect: function() {

View File

@@ -987,6 +987,16 @@ it('Allows selection of Bitcoin Private', function(done) {
};
testNetwork(done, params);
});
it('Allows selection of Bitcoin Private testnet', function(done) {
var params = {
selectText: "BTCPt - Bitcoin Private Testnet",
phrase: "abandon abandon ability",
firstAddress: "n1UcUUSDfDppfzh7XLJNHmZkLdbTQg3VAZL",
firstPubKey: "0382a5450765e2025bdb5f7d109c9254a11ef97a566228bf171d80ecb348763bb0",
firstPrivKey: "cV3coiYD2NhHKfhC6Gb8DzpvPzcGYYExYxuNxpUtKq3VUJrkFLZx",
};
testNetwork(done, params);
});
it('Allows selection of Bitcoin SV', function(done) {
var params = {
selectText: "BSV - BitcoinSV",