JWT Authorizer in API Gateway HTTP API oidc discovery endpoint with a trailing slash.

0

Is there a way to allow a trailing slash or follow a 308 redirect for an OIDC discovery endpoint using the JWT Authorizer?

I'm currently using next.js with trailingSlash: true and some middleware that adds the .well-known/openid-configuration endpoint. Unfortunately next.js added a "/" suffix to make it .well-known/openid-configuration/ and the HTTP API gateway responds with the following header:

www-authenticate
	Bearer scope="" error="invalid_token" error_description="non-200 status code received from OIDC discovery endpoint"

Is there a way to workaround this? Is this a bug or a strict adherence to the spec?

Any help would be appreciated,

Dave

No Answers

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions