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

chore: Update module github.com/MicahParks/jwkset to v0.6.0 [SECURITY] #274

Merged

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jan 14, 2025

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
github.com/MicahParks/jwkset v0.5.20 -> v0.6.0 age adoption passing confidence

GitHub Vulnerability Alerts

CVE-2025-22149

Impact

The project's provided HTTP client's local JWK Set cache should do a full replacement when the goroutine refreshes the remote JWK Set. The current behavior is to overwrite or append. This is a security issue for use cases that utilize the provided auto-caching HTTP client and where key removal from a JWK Set is equivalent to revocation.

Example attack scenario:

  1. An attacker has stolen the private key for a key published in JWK Set.
  2. The publishers of that JWK Set remove that key from the JWK Set.
  3. Enough time has passed that the program using the auto-caching HTTP client found in github.com/MicahParks/jwkset v0.5.0-v0.5.21 has elapsed its HTTPClientStorageOptions.RefreshInterval duration, causing a refresh of the remote JWK Set.
  4. The attacker is signing content (such as JWTs) with the stolen private key and the system has no other forms of revocation.

Patches

The affected auto-caching HTTP client was added in version v0.5.0 and fixed in v0.6.0. Upgrade to v0.6.0 or later.

Workarounds

The only workaround would be to remove the provided auto-caching HTTP client and replace it with a custom implementation. This involves setting the HTTPClientStorageOptions.RefreshInterval to zero (or not specifying the value). Upgrade to v0.6.0 is advised.

References

Please see the tracking issue on GitHub for additional details: https://github.com/MicahParks/jwkset/issues/40


Release Notes

MicahParks/jwkset (github.com/MicahParks/jwkset)

v0.6.0

Compare Source

The purpose of this release is to fix a bug pointed out by @​rohitkoul in https://github.com/MicahParks/jwkset/pull/7#discussion_r1907816656. There is a bug in the refresh goroutine related to key replacement.

The project's provided HTTP client's local JWK Set cache should do a full replacement when the goroutine refreshes the remote JWK Set. The current behavior is to overwrite or append. This is a security issue for use cases that utilize the provided auto-caching HTTP client and where key removal from a JWK Set is equivalent to revocation.

Regardless of this bug, please note that removing a key from a JWK Set does not equate to instant revocation for most use cases as it takes time for JWK Set updates to propagate to all clients.

Relevant issues:

Relevant pull requests:

v0.5.21

Compare Source


Configuration

📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot requested a review from nieomylnieja as a code owner January 14, 2025 17:23
@renovate renovate bot enabled auto-merge (squash) January 14, 2025 17:23
Copy link
Contributor Author

renovate bot commented Jan 14, 2025

ℹ Artifact update notice

File name: go.mod

In order to perform the update(s) described in the table above, Renovate ran the go get command, which resulted in the following additional change(s):

  • 1 additional dependency was updated

Details:

Package Change
golang.org/x/time v0.7.0 -> v0.9.0

@renovate renovate bot merged commit dda3e7a into main Jan 14, 2025
5 checks passed
@renovate renovate bot deleted the renovate_go-github.com-micahparks-jwkset-vulnerability branch January 14, 2025 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant