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

HTTP 500 on /.well-known/jwks.json endpoint when updating keys #2390

Closed
mmanes opened this issue Jul 25, 2023 · 1 comment
Closed

HTTP 500 on /.well-known/jwks.json endpoint when updating keys #2390

mmanes opened this issue Jul 25, 2023 · 1 comment
Assignees
Labels
bug Something isn't working
Milestone

Comments

@mmanes
Copy link

mmanes commented Jul 25, 2023

Description

In rare cases, it is possible for FusionAuth to return an HTTP status of 500 from the JWKS endpoint when certain key modification operations are in progress. Additionally, the following log message may be recorded:

2023-07-25 10:33:28.712 PM ERROR org.primeframework.mvc.PrimeMVCRequestHandler - Error encountered
com.fasterxml.jackson.databind.JsonMappingException: Index 1 out of bounds for length 0 (through reference chain: io.fusionauth.domain.oauth2.JWKSResponse["k
eys"]->java.util.ArrayList[1])

Affects versions

FusionAuth <= 1.46.0

Steps to reproduce

This issue is typically only seen while under high load, but may be reproducible with the following:

  • Create a load test to repeatedly make requests against the JWKS endpoint.
  • Generate or delete RSA keys from the console or API.

Expected behavior

A successful JWKS response to all requests.

Community guidelines

All issues filed in this repository must abide by the FusionAuth community guidelines.

Release Notes

Correct a potential race condition that could cause a request to the /.well-known/jwks.json endpoint to exception and return a 500 status code when under heavy load.

@mmanes mmanes added this to Backlog in FusionAuth Issues via automation Jul 25, 2023
@mmanes mmanes removed this from Backlog in FusionAuth Issues Jul 25, 2023
@robotdan robotdan added the bug Something isn't working label Jul 26, 2023
@robotdan robotdan added this to Backlog in FusionAuth Issues via automation Jul 26, 2023
@robotdan robotdan added this to the 1.48.0 milestone Jul 26, 2023
@robotdan
Copy link
Member

@robotdan robotdan moved this from Backlog to Code complete in FusionAuth Issues Jul 28, 2023
@robotdan robotdan self-assigned this Jul 28, 2023
@robotdan robotdan moved this from Code complete to Reviewer approved in FusionAuth Issues Aug 4, 2023
@robotdan robotdan moved this from Reviewer approved to Code complete in FusionAuth Issues Oct 11, 2023
@robotdan robotdan moved this from Code complete to Delivered in FusionAuth Issues Oct 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
FusionAuth Issues
  
Delivered
Development

No branches or pull requests

2 participants