You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently it is not possible to set custom headers when requesting the keys.
In our case this lead to the following problem: the "request" module sets the Accept header to application/json when json: true is used and no Accept header is set explicitly. See:
However if the server that stores the JWKS is configured to return a application/jwk-set+json content-type, a request with Accept: application/json is declined with a 406 error. To fix this we need to set the Accept header to either application/jwk-set+json or *.
It would be great if custom headers could be configured in the options.
The text was updated successfully, but these errors were encountered:
Currently it is not possible to set custom headers when requesting the keys.
In our case this lead to the following problem: the "request" module sets the
Accept
header toapplication/json
whenjson: true
is used and noAccept
header is set explicitly. See:https://github.com/request/request/blob/a92e138d897d78ce19dd70bd1ad271c7f9c6a23d/request.js#L1279-L1281
However if the server that stores the JWKS is configured to return a
application/jwk-set+json
content-type, a request withAccept: application/json
is declined with a 406 error. To fix this we need to set theAccept
header to eitherapplication/jwk-set+json
or*
.It would be great if custom headers could be configured in the options.
The text was updated successfully, but these errors were encountered: