aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authoriancoleman <1281387+iancoleman@users.noreply.github.com>2020-05-11 09:16:11 +1000
committerGitHub <noreply@github.com>2020-05-11 09:16:11 +1000
commit677d18f2e0e5281f741ac1870a537fe45e462e7f (patch)
treed60cc5fa68fed1adba493882c44f50bafa4984aa /src
parentf3051a6a9f72c16b5b964d8cc7a23a3553d08dd2 (diff)
parent115eb450839f1ecc86ffe03768a59637986a6c83 (diff)
downloadBIP39-677d18f2e0e5281f741ac1870a537fe45e462e7f.tar.gz
BIP39-677d18f2e0e5281f741ac1870a537fe45e462e7f.tar.zst
BIP39-677d18f2e0e5281f741ac1870a537fe45e462e7f.zip
Merge pull request #422 from cryply/master
adding CRP support
Diffstat (limited to 'src')
-rw-r--r--src/js/bitcoinjs-extensions.js11
-rw-r--r--src/js/index.js8
-rw-r--r--src/js/segwit-parameters.js30
3 files changed, 49 insertions, 0 deletions
diff --git a/src/js/bitcoinjs-extensions.js b/src/js/bitcoinjs-extensions.js
index e67996c..7cd480c 100644
--- a/src/js/bitcoinjs-extensions.js
+++ b/src/js/bitcoinjs-extensions.js
@@ -581,6 +581,17 @@ libs.bitcoin.networks.cannacoin = {
581 wif: 0x9c, 581 wif: 0x9c,
582}; 582};
583 583
584libs.bitcoin.networks.cranepay = {
585 messagePrefix: '\x18Bitcoin Signed Message:\n',
586 bip32: {
587 public: 0x0488b21e,
588 private: 0x0488ade4
589 },
590 pubKeyHash: 28,
591 scriptHash: 10,
592 wif: 123,
593};
594
584libs.bitcoin.networks.cryptoescudo = { 595libs.bitcoin.networks.cryptoescudo = {
585 messagePrefix: '\x18Cryptoescudo Signed Message:\n', 596 messagePrefix: '\x18Cryptoescudo Signed Message:\n',
586 bip32: { 597 bip32: {
diff --git a/src/js/index.js b/src/js/index.js
index 43c6955..3dde602 100644
--- a/src/js/index.js
+++ b/src/js/index.js
@@ -2332,6 +2332,14 @@
2332 }, 2332 },
2333 }, 2333 },
2334 { 2334 {
2335 name: "CRP - CranePay",
2336 onSelect: function() {
2337 network = libs.bitcoin.networks.cranepay;
2338 setHdCoin(2304);
2339 },
2340 },
2341
2342 {
2335 name: "CRW - Crown (Legacy)", 2343 name: "CRW - Crown (Legacy)",
2336 onSelect: function() { 2344 onSelect: function() {
2337 network = libs.bitcoin.networks.crown; 2345 network = libs.bitcoin.networks.crown;
diff --git a/src/js/segwit-parameters.js b/src/js/segwit-parameters.js
index ea6f86e..997a0f8 100644
--- a/src/js/segwit-parameters.js
+++ b/src/js/segwit-parameters.js
@@ -163,6 +163,36 @@ libs.bitcoin.networks.regtest.p2wshInP2sh = {
163 scriptHash: 0xc4, 163 scriptHash: 0xc4,
164 wif: 0xef 164 wif: 0xef
165}; 165};
166
167libs.bitcoin.networks.cranepay.p2wpkhInP2sh = {
168 baseNetwork: "cranepay",
169 messagePrefix: '\x18Bitcoin Signed Message:\n',
170 bech32: 'cp',
171 bip32: {
172 public: 0x049d7cb2,
173 private: 0x049d7878
174 },
175 pubKeyHash: 28,
176 scriptHash: 10,
177 wif: 123
178};
179
180// bech32
181libs.bitcoin.networks.cranepay.p2wpkh = {
182 baseNetwork: "cranepay",
183 messagePrefix: '\x18Bitcoin Signed Message:\n',
184 bech32: 'cp',
185 bip32: {
186 public: 0x04b24746,
187 private: 0x04b2430c
188 },
189 pubKeyHash: 28,
190 scriptHash: 10,
191 wif: 123
192};
193
194
195
166 196
167libs.bitcoin.networks.litecoin.p2wpkh = { 197libs.bitcoin.networks.litecoin.p2wpkh = {
168 baseNetwork: "litecoin", 198 baseNetwork: "litecoin",