fix(api): catch remaining JWKS mutation survivors (#130) - #153
Merged
Conversation
Make JWKS cache expiry deterministic with Tokio's test clock and add a realistic local JWKS server fixture. The fixture covers RSA signing-key filtering and verifies the accepted public key through an RS256 token. Also enable jsonwebtoken's RustCrypto backend so production JWT verification has an explicit crypto provider. Tests: cargo fmt --all -- --check Tests: cargo test -p api Tests: cargo clippy -p api --all-targets -- -D warnings Tests: cargo mutants -p api -f crates/api/src/auth/jwks.rs (19 tested: 13 caught, 6 unviable) Co-authored-by: gpt-5.6-luna (opencode-go) Co-authored-by: pi agent <pi@agent.local>
2 tasks
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.
Summary
Fixes the six surviving mutation-testing mutants in
CachingJwksProviderfrom issue #130.kidkeys.docs/issues/remaining-6-jwks-mutants.md.Validation
cargo fmt --all -- --checkcargo test -p apicargo clippy -p api --all-targets -- -D warningscargo mutants -p api -f crates/api/src/auth/jwks.rsAcceptance criteria
mutate-securityverification.Co-authored-by: gpt-5.6-luna (opencode-go)