diff --git a/monero-wallet-generator.html b/monero-wallet-generator.html index 759f7d3..99d429e 100644 --- a/monero-wallet-generator.html +++ b/monero-wallet-generator.html @@ -2121,6 +2121,24 @@ var cnUtil = (function(initConfig) { return keys; }; + this.create_address_if_prefix = function(seed, prefix) { + var keys = {}; + var first; + if (seed.length !== 64) { + first = this.keccak(seed, seed.length / 2, 32); + } else { + first = seed; + } + keys.spend = this.generate_keys(first); + public_addr = this.pubkeys_to_string(keys.spend.pub, ""); + if (public_addr.toUpperCase().slice(0, prefix.length) != prefix.toUpperCase()) + return null; + var second = this.keccak(keys.spend.sec, 32, 32); + keys.view = this.generate_keys(second); + keys.public_addr = this.pubkeys_to_string(keys.spend.pub, keys.view.pub); + return keys; + }; + this.create_addr_prefix = function(seed) { var first; if (seed.length !== 64) { @@ -3645,6 +3663,16 @@ This is your new Monero wallet:

+

+

+
+ + +
+ (very slow for more than a few characters, no check for valid prefixes) +
+
+

@@ -3757,13 +3785,16 @@ place any email address in a new GPG key, so the right email being shown is no g