added support for RSA signatures.#16
Conversation
|
Thank you for your contribution. I think I can accept this once myself and maybe some other people have time to test it and verify that it works as it should. There are a few things that need to be fixed with regard to coding standards, but I will put those in other comments. |
There was a problem hiding this comment.
Why not just assign the function directly instead of having a separate function? Something like this?
RSAKey.prototype.verify = function(text, signature, digestMethod) {
var c = parseBigInt(signature, 16);
var m = c.modPowInt(this.e, this.n);
if (m == null) return null;
var digest = pkcs1unpad2(m, (this.n.bitLength()+7)>>3);
console.log("RSAVerify: message digest :- " + digest);
return digest == digestMethod(text);
};
Same goes for the other function you created.
…formatting for private key operations was being done wrongly.
|
+1 ? |
|
+1 |
|
You example is always returning false |
|
+1 |
|
-er- any way I could help to get this updated and merged? Really need the signing feature. |
|
@khatribharat Any chance you could fix those conflicts? |
|
Please rebase against master using TypeScript. |
|
the digest method it works fine, if we use |
I've added support for RSA signatures.
Usage :