-
Notifications
You must be signed in to change notification settings - Fork 14
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
Trusted Keys mongo database cache is misbehaving #340
Comments
The issuer's data is requested from the DB (upsert) based on an obtained credential. Ideally, the key ID can be provided in advance to the call to facilitate the update in a single step.
Evaluate and open an issue to consolidate this approach. |
A furhter issue emerged with the cache. IMO this problem should also be considered when considering a new solution for the cache usage. |
It is not clear to me how the parser should be able to retrieve the cryptographic material. Do you mean the cryptographic material from the cache?
Assuming we have the cryptographic material, then we would need to develop a method like "is this key valid according to your own trust mechanism", right?
[...] we try to think what happens here. The token verifier now should be aware of the nuances of the token cache and is the token verifier responsability to update the cache. |
When recoving trusted keys from a credential issuer, in the original deisgn the keys where cached at the database level as a FALLBACK strategy for situations where they cannot be remotedly fetched (for example, the issuer is temporarely offline ad the
/.well-known/openid-federation
or/.well-known/jwt-vc-issuer
endpoint).However, the current implementation does not use the cache as fallback, but as a primary recovery strategy. As such, if the creddential issuer changes signing key, we are unable to find the new remote key until the cache is manually flushed from the mongo database.
This is the bad code: when looking at the trusted material, first we look at the DB (line 85) and then interrogate the trust evaluation mechanism only when this is not possible
eudi-wallet-it-python/pyeudiw/trust/dynamic.py
Lines 75 to 90 in 486aa59
The text was updated successfully, but these errors were encountered: