Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix the presentation submission in the oid4vp-rs e2e test. (#8)
* wip: use ssi 0.8.1, debugging e2e test using did resolver Signed-off-by: Ryan Tate <[email protected]> * wip: use VerificationMethodDIDResolver for DIDClient constructor Signed-off-by: Ryan Tate <[email protected]> * remove unused imports Signed-off-by: Ryan Tate <[email protected]> * wip: debugging did resolver jwk not found in e2e flow Signed-off-by: Ryan Tate <[email protected]> * feat/improve-presentation-exchange-support-in-oid4vp-rs add implementation methods for Presentation Definition. WIP: Need to continue work for Presentation Submission and the rest of the structs used in the presentation exchange flow. Signed-off-by: Ryan Tate <[email protected]> Co-authored-by: Todd Showalter <[email protected]> * add getter methods for presentation definition member fields Signed-off-by: Ryan Tate <[email protected]> * fix broken links in documentation Signed-off-by: Ryan Tate <[email protected]> * update presentation submission implementation Signed-off-by: Ryan Tate <[email protected]> * fix test cases. todo: update test cases to use newly created interface for presentation exchange Signed-off-by: Ryan Tate <[email protected]> * update json schema validator to use anyhow result type Signed-off-by: Ryan Tate <[email protected]> * wip: use latest implementation changes, update tests Signed-off-by: Ryan Tate <[email protected]> * fix verification method did resolver tests Signed-off-by: Ryan Tate <[email protected]> * wip: remove unused imports Signed-off-by: Ryan Tate <[email protected]> * add ClaimFormat type Signed-off-by: Ryan Tate <[email protected]> * add regex support for string pattern matching Signed-off-by: Ryan Tate <[email protected]> * revert uuid presentation definition id type to string Signed-off-by: Ryan Tate <[email protected]> * fix: ensure negation of regex pattern match for error Signed-off-by: Ryan Tate <[email protected]> * add 'other' variante to claim format type Signed-off-by: Ryan Tate <[email protected]> * remove commented out code Signed-off-by: Ryan Tate <[email protected]> * use ssi sub-crates instead of main ssi dependency Signed-off-by: Ryan Tate <[email protected]> * add jwt_vc_json and jwt_vp_json claim formats Signed-off-by: Ryan Tate <[email protected]> * wip: construct verifiable presentation for e2e test Signed-off-by: Ryan Tate <[email protected]> * wip: perform validation on presentation submission Signed-off-by: Ryan Tate <[email protected]> * ensure range exclusive values are checked; fix inclusive range values Signed-off-by: Ryan Tate <[email protected]> * ensure enum values are parsed in alpha descending order This is a fix for a bug where ClaimFormat::JwtVc was being parsed when ClaimFormat::JwtVp should have been instead. The fix is to order the enum fields in alphabetical descending order, such that VP comes BEFORE VC, and so on, for the other formats. Signed-off-by: Ryan Tate <[email protected]> * wip: verify authorized response presentation submission Signed-off-by: Ryan Tate <[email protected]> * ensure json schema validator adheres to the specification Signed-off-by: Ryan Tate <[email protected]> * ensure json schema validator adheres to the specification Signed-off-by: Ryan Tate <[email protected]> * add unit tests for schema validator Signed-off-by: Ryan Tate <[email protected]> * use serde default value for constraints field if not found during deserialization Signed-off-by: Ryan Tate <[email protected]> * remove unused imports Signed-off-by: Ryan Tate <[email protected]> * remove unsed imports in test files Signed-off-by: Ryan Tate <[email protected]> * update vp token Signed-off-by: Ryan Tate <[email protected]> * rebase with main Signed-off-by: Ryan Tate <[email protected]> * remove unused dependencies Signed-off-by: Ryan Tate <[email protected]> * add rand crate and provide random nonce method using Rng trait Signed-off-by: Ryan Tate <[email protected]> * remove todos and update comments, use JWKResolver instead of VerificationMethodDIDResolver Signed-off-by: Ryan Tate <[email protected]> * fix clippy warnings Signed-off-by: Ryan Tate <[email protected]> * verify jwt in validate_authorization_response presentation definition method Signed-off-by: Ryan Tate <[email protected]> * Update tests/e2e.rs Co-authored-by: Jacob <[email protected]> * update descriptor map nested path in e2e example Signed-off-by: Ryan Tate <[email protected]> * remove dependency patches Signed-off-by: Ryan Tate <[email protected]> * add paths to example for input descriptor constraints field Signed-off-by: Ryan Tate <[email protected]> * use top level json path for jwt_vp_json Signed-off-by: Ryan Tate <[email protected]> * Update src/verifier/client.rs Co-authored-by: Jacob <[email protected]> * rebase Signed-off-by: Ryan Tate <[email protected]> * revert validation function async signature to use boxed pin future Signed-off-by: Ryan Tate <[email protected]> * add helper methods Signed-off-by: Ryan Tate <[email protected]> * debug: jwt claim signing does not include public key Signed-off-by: Ryan Tate <[email protected]> * make request signer methods return a result Signed-off-by: Ryan Tate <[email protected]> * refactor presentation exchange file into smaller modules Signed-off-by: Ryan Tate <[email protected]> * fix clippy warnings Signed-off-by: Ryan Tate <[email protected]> * fix outcome error cause Signed-off-by: Ryan Tate <[email protected]> * add credential format and add requested fields helper method to input descriptor Signed-off-by: Ryan Tate <[email protected]> * Update src/core/presentation_definition.rs Co-authored-by: Jacob <[email protected]> * Update src/core/presentation_definition.rs Co-authored-by: Jacob <[email protected]> * wip: add notes on required fields parsing Signed-off-by: Ryan Tate <[email protected]> * update vp token base64 encoding and check for multiple vp payloads Signed-off-by: Ryan Tate <[email protected]> * move validation to auth response impl instead of presentation definition impl Signed-off-by: Ryan Tate <[email protected]> * remove feature gated non-optional deps Signed-off-by: Ryan Tate <[email protected]> * remove cfg features Signed-off-by: Ryan Tate <[email protected]> * wip: handle groups in presentation definition, input descriptor tests Signed-off-by: Ryan Tate <[email protected]> * remove cfg feature tags Signed-off-by: Ryan Tate <[email protected]> * remove extraneous metadata helper methods; use UntypedObject for dereferencing Signed-off-by: Ryan Tate <[email protected]> * add submission requirement check for presentation validation Signed-off-by: Ryan Tate <[email protected]> * add validate method to vp token; ensure submission requirement all rule is enforced. Signed-off-by: Ryan Tate <[email protected]> * add vp token validate unencoded method. fix minor todos. Signed-off-by: Ryan Tate <[email protected]> * Update Cargo.toml Co-authored-by: Jacob <[email protected]> * fix other claim format serde Signed-off-by: Ryan Tate <[email protected]> * use Vec::is_empty versus Option::is_none for various serialization fields This commit also removes validation logic from vp token response struct. Signed-off-by: Ryan Tate <[email protected]> * revert to use of ClaimFormatMap to pass presentation defintion test suite Signed-off-by: Ryan Tate <[email protected]> --------- Signed-off-by: Ryan Tate <[email protected]> Co-authored-by: Todd Showalter <[email protected]> Co-authored-by: Jacob <[email protected]>
- Loading branch information