mirror of
https://github.com/OneKeyHQ/bip39.git
synced 2026-04-17 16:02:16 +00:00
adding xlm stellar
This commit is contained in:
@@ -888,6 +888,7 @@
|
||||
<script src="js/biginteger.js"></script>
|
||||
<script src="js/zxcvbn.js"></script>
|
||||
<script src="js/entropy.js"></script>
|
||||
<script src="js/stellar-util.js"></script>
|
||||
<script src="js/index.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -808,6 +808,14 @@
|
||||
privkey = ethUtil.addHexPrefix(privkey);
|
||||
pubkey = ethUtil.addHexPrefix(pubkey);
|
||||
}
|
||||
// Stellar is different
|
||||
if (networks[DOM.network.val()].name == "XLM - Stellar") {
|
||||
const path = "m/44'/148'/" + index + "'";
|
||||
const keypair = stellarUtil.derivePath(path, seed);
|
||||
indexText = path;
|
||||
privkey = keypair.secret();
|
||||
pubkey = address = keypair.publicKey();
|
||||
}
|
||||
// Ripple values are different
|
||||
if (networks[DOM.network.val()].name == "XRP - Ripple") {
|
||||
privkey = convertRipplePriv(privkey);
|
||||
@@ -1694,6 +1702,14 @@
|
||||
setHdCoin(1);
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "XLM - Stellar",
|
||||
onSelect: function() {
|
||||
segwitAvailable: false,
|
||||
network = null;
|
||||
setHdCoin(148);
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "XMY - Myriadcoin",
|
||||
segwitAvailable: false,
|
||||
|
||||
41520
src/js/stellar-util.js
Normal file
41520
src/js/stellar-util.js
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user