Repository navigation
feat: add optional JWT expiry enforcement - #303
Open
marco-a-affinidi wants to merge 1 commit into
Open
marco-a-affinidi wants to merge 1 commit into
marco-a-affinidi wants to merge 1 commit into
Conversation
marco-a-affinidi
requested review from
carlos-affinidi,
cosminm-affnd and
ivan-branets-affinidi
September 8, 2026 16:50
|
Coverage after merging fix/missing_exp into main will be
Coverage Report |
🛡️ AI Agentic Security Code Review2 AI-confirmed issues. Mandatory to check: 🔒 Security Code Review Report — Security tab ↗ 📊 Summary & findings
Finding details (titles, evidence + remediation) are in the 🔒 Security tab ↗ — visible to maintainers / code owners only. |
ivan-branets-affinidi
approved these changes
Sep 17, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request enhances the handling and validation of JWT Verifiable Credentials (VCs) regarding the presence of an expiry (
exp) field. The main improvement is the introduction of a configurable option to require the expiry field during integrity verification, along with updated tests to cover this new behavior.Enhancements to expiry validation:
allowMissingExpiryparameter (defaulting totrue) to theverifyIntegritymethod inJwtDm1Suite, allowing callers to enforce the presence of theexpclaim if required by policy.falseif the expiry is missing andallowMissingExpiryis set tofalse.Testing improvements:
jwt_exp_validation_test.dartto better reflect the scenarios covered, such as permitting missing expiry by default and rejecting it when explicitly required. [1] [2]verifyIntegrityrejects credentials missingexpwhenallowMissingExpiryis set tofalse.verifiable_credential_test.dartto clarify that integrity checks pass when expiry is missing.