]> git.immae.eu Git - perso/Immae/Projets/Cryptomonnaies/BIP39.git/commitdiff
added Thought network spec
authorAndrew <ajhacker@mistiqtech.com>
Tue, 5 Nov 2019 16:26:58 +0000 (11:26 -0500)
committerAndrew <ajhacker@mistiqtech.com>
Tue, 5 Nov 2019 16:26:58 +0000 (11:26 -0500)
changelog.md
src/index.html
src/js/bitcoinjs-extensions.js
src/js/index.js

index 39a1531bb087775ebb76b4f0a5ef1fe621641f5c..29a2b6f88931e48187d32ea2b5977dd97b66d007 100644 (file)
@@ -1,3 +1,7 @@
+# 0.3.13
+
+* Add Thought network
+
 # 0.3.12
 
 * Fix typos
index 95fccc14236a793234dc002aaf9c47664d6b011a..6714a9ff4a7215b7c0d7a60e60c8137fc13578ff 100644 (file)
@@ -15,7 +15,7 @@
         <div class="container">
 
             <h1 class="text-center">Mnemonic Code Converter</h1>
-            <p class="version">v0.3.12</p>
+            <p class="version">v0.3.13</p>
             <hr>
             <div class="row">
                 <div class="col-md-12">
index a9db48504f2300b044c51cb29fd38f082d44a586..255ac86f773c964414522d859a224fc2a2da24d6 100644 (file)
@@ -1716,3 +1716,14 @@ bitcoinjs.bitcoin.networks.aryacoin = {
   scriptHash: 0x6f,
   wif: 0x97
 };
+
+bitcoinjs.bitcoin.networks.thought = {
+  messagePrefix: 'unused',
+  bip32: {
+    public: 0xFbC6A00D,
+    private: 0x5AEBD8C6
+  },
+  pubKeyHash: 0x07,
+  scriptHash: 0x09,
+  wif: 0x7B
+};
index f3302a64bfee229566ff574b82f474ad6db82773..0ecb735af3d7742563b950eca76180eafda515f4 100644 (file)
     }
 
     function validateRootKey(rootKeyBase58) {
-        if(isGRS()) 
+        if(isGRS())
             return validateRootKeyGRS(rootKeyBase58);
-            
+
         // try various segwit network params since this extended key may be from
         // any one of them.
         if (networkHasSegwit()) {
                     privkey = keyPair.toWIF();
                     // BIP38 encode private key if required
                     if (useBip38) {
-                        if(isGRS())  
+                        if(isGRS())
                             privkey = groestlcoinjsBip38.encrypt(keyPair.d.toBuffer(), false, bip38password, function(p) {
                                 console.log("Progressed " + p.percent.toFixed(1) + "% for index " + index);
                             }, null, networks[DOM.network.val()].name.includes("Testnet"));
                         else if (isP2wpkhInP2sh) {
                             address = groestlcoinjs.address.fromOutputScript(scriptpubkey, network)
                         }
-                    } 
+                    }
                     //non-segwit addresses are handled by using groestlcoinjs for bip32RootKey
                 }
 
                 setHdCoin(113);
             },
         },
+        {
+            name: "THT - Thought",
+            onSelect: function() {
+                network = bitcoinjs.bitcoin.networks.thought;
+                setHdCoin(1618);
+            },
+        },
         {
             name: "TOA - Toa",
             onSelect: function() {