]> git.immae.eu Git - perso/Immae/Projets/Cryptomonnaies/BIP39.git/commitdiff
Merge pull request #433 from scribenetwork/master
authoriancoleman <1281387+iancoleman@users.noreply.github.com>
Mon, 24 Aug 2020 23:27:54 +0000 (09:27 +1000)
committerGitHub <noreply@github.com>
Mon, 24 Aug 2020 23:27:54 +0000 (09:27 +1000)
Add Scribe support

src/js/bitcoinjs-extensions.js
src/js/index.js
tests/spec/tests.js

index 7cd480cde745387d597d9cb9536898a533fc065f..8f50f11f4c83067424e9128bafdff2968eb063b9 100644 (file)
@@ -139,6 +139,17 @@ libs.bitcoin.networks.axe = {
   wif: 0xcc
 };
 
+libs.bitcoin.networks.scribe = {
+  messagePrefix: 'unused',
+  bip32: {
+    public: 0x0488B21E,
+    private: 0x0488ADE4
+  },
+  pubKeyHash: 0x3c,
+  scriptHash: 0x7d,
+  wif: 0x6e
+};
+
 libs.bitcoin.networks.slimcoin = {
   messagePrefix: 'unused',
   bip32: {
index 3dde602e3858e393943874a20ff40591d036d0dd..2c2e99a2fb6742c316182cb23590bc37497f3e84 100644 (file)
               setHdCoin(19165);
             },
         },
+        {
+            name: "SCRIBE - Scribe",
+            onSelect: function() {
+                network = libs.bitcoin.networks.scribe;
+                setHdCoin(545);
+            },
+        },
     {
           name: "SLS - Salus",
           onSelect: function() {
index 0e7edb98917d62d015944152fafb63fae00eda44..14cdb8e5a765b307f1d8c81ea5fb4fb875730bf1 100644 (file)
@@ -2265,6 +2265,16 @@ it('Allows selection of CranePay', function(done) {
     };
     testNetwork(done, params);
 });
+it('Allows selection of Scribe', function(done) {
+    var params = {
+        selectText: "SCRIBE - Scribe",
+        phrase: "abandon abandon ability",
+        firstAddress: "RYAnPeBLD8veZ9Tw8xugeTC2f9PeZonLHM",
+        firstPubKey: "02c912bc4759c8a209475502fb5352ff5be8a8f13eb72f1732ee25125cd53edc1e",
+        firstPrivKey: "HLZWvNCEUv4ghygjH9A2EYCa9HNRcxe5CS42kzUTmoxJYp3z96QE",
+    };
+    testNetwork(done, params);
+});
 
 // BIP39 seed is set from phrase
 it('Sets the bip39 seed from the prhase', function(done) {