|
|
@ -57,6 +57,9 @@ ECDSA.prototype.randomK = function() { |
|
|
|
return this; |
|
|
|
}; |
|
|
|
|
|
|
|
// Information about public key recovery:
|
|
|
|
// https://bitcointalk.org/index.php?topic=6430.0
|
|
|
|
// http://stackoverflow.com/questions/19665491/how-do-i-get-an-ecdsa-public-key-from-just-a-bitcoin-signature-sec1-4-1-6-k
|
|
|
|
ECDSA.prototype.sig2pubkey = function() { |
|
|
|
var i = this.sig.i; |
|
|
|
if (!(i === 0 || i === 1 || i === 2 || i === 3)) |
|
|
|