diff --git a/bitaddress.org.html b/bitaddress.org.html index fb043d2..af1e1e2 100644 --- a/bitaddress.org.html +++ b/bitaddress.org.html @@ -3741,6 +3741,8 @@ } }; + ECKey.privateKeyPrefix = 0x80; // mainnet + ECKey.prototype.getPub = function () { if (this.pub) return this.pub; return this.pub = ecparams.getG().multiply(this.priv).getEncoded(0); @@ -3776,7 +3778,7 @@ // Sipa Private Key Wallet Import Format ECKey.prototype.getBitcoinWalletImportFormat = function () { var bytes = this.getBitcoinPrivateKeyByteArray(); - bytes.unshift(0x80); // prepend 0x80 byte + bytes.unshift(ECKey.privateKeyPrefix); // prepend 0x80 byte var checksum = Crypto.SHA256(Crypto.SHA256(bytes, { asBytes: true }), { asBytes: true }); bytes = bytes.concat(checksum.slice(0, 4)); var privWif = Bitcoin.Base58.encode(bytes); @@ -3786,7 +3788,7 @@ // Sipa Private Key Wallet Import Format Compressed ECKey.prototype.getBitcoinWalletImportFormatCompressed = function () { var bytes = this.getBitcoinPrivateKeyByteArray(); - bytes.unshift(0x80); // prepend 0x80 byte + bytes.unshift(ECKey.privateKeyPrefix); // prepend 0x80 byte bytes.push(0x01); // append 0x01 byte for compressed format var checksum = Crypto.SHA256(Crypto.SHA256(bytes, { asBytes: true }), { asBytes: true }); bytes = bytes.concat(checksum.slice(0, 4)); @@ -4184,13 +4186,13 @@
- Private Key WIF (51 characters base58, starts with a '5'): + Private Key WIF (51 characters base58, starts with a '5'):


- Private Key WIF (compressed, 52 characters base58, starts with a 'K' or 'L'): + Private Key WIF (compressed, 52 characters base58, starts with a 'K' or 'L'):


@@ -4267,7 +4269,7 @@
PGP Public Key - Signed Version History (v1.8) + Signed Version History (v1.9) GitHub Repository