Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it empty implementation equivalent to Not Implemented? #2

Open
dileepbapat opened this issue Apr 16, 2021 · 8 comments
Open

Is it empty implementation equivalent to Not Implemented? #2

dileepbapat opened this issue Apr 16, 2021 · 8 comments

Comments

@dileepbapat
Copy link

https://github.com/digitalbazaar/rsa-signature-2018/blob/master/lib/RsaSignature2018.js

Above file defines an empty object, is it missing implementation?

Change: https://github.com/digitalbazaar/jsonld-signatures/blob/master/CHANGELOG.md#800---2021-03-18 moves signature suites into its own repo (which is this)

@dmitrizagidulin
Copy link
Contributor

@dileepbapat - you're correct, a standalone RSA suite is not implemented at this point. (We don't really use it in any of our use cases / deployments.)
For what it's worth, there is PR #1, which does have the code extracted from jsonld-signatures. It's just not really used/tested.

@uocnb
Copy link

uocnb commented Feb 10, 2022

@dmitrizagidulin I've tested with the latest version of vc.js with rn branch, and it works well. Could you please merge the PR #1?

@dmitrizagidulin
Copy link
Contributor

@uocnb - oh, hey, good to know! :) Thanks for testing it.

@fabrii
Copy link

fabrii commented Jun 2, 2023

Hi @uocnb. Did it worked out of the box for you?

I'm generating my credentials with https://github.com/danubetech/verifiable-credentials-java. It generates them with RS256 ALG.
I changed the algorithm in RsaSignature2018.js, and removed the "pss" attributes and salts in the RsaVerificationKey2018.js, but I am always getting "Invalid Signature". Might be also related to the way both libraries calculate the data that is going to be validated against the signature.

BTW, I also tried generating (java) and validating (js) credentials with ED25519 and works ok.

Just in case, reproducer here: https://github.com/fabrii/dc-playground

Thanks

@fabrii
Copy link

fabrii commented Jun 3, 2023

Found out that the RsaSignature2018 is working perfectly. The problem is that the received "verifyData" byte array is different on javascript vs java library. I am digging a bit further to know why.

@fabrii
Copy link

fabrii commented Jun 3, 2023

Seems to be related to an error in the canonicalization process.

Opened an issue upstream: digitalbazaar/jsonld.js#524

@dmitrizagidulin, I would really appreciate if you could take a look and tell me what you think.

Thanks!

@uocnb
Copy link

uocnb commented Jun 27, 2023

Hi @fabrii, as I remember it required few changes to make it work. It's long time already when I'm working with this.
The implementation can be found here: https://github.com/idpass/inji. See the package.json for details.

Good luck!

@fabrii
Copy link

fabrii commented Jun 27, 2023

I made it work. The suite is working ok. The problem is with the canonicalization process. More info in the issue opened in digitalbazar.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants