checkJwt middleware doesn't work on API example
luis199230 opened this issue · 2 comments
luis199230 commented
Checklist
- The issue can be reproduced in the auth0-react sample app (or N/A).
- I have looked into the Readme, Examples, and FAQ and have not found a suitable solution or answer.
- I have looked into the API documentation and have not found a suitable solution or answer.
- I have searched the issues and have not found a suitable solution or answer.
- I have searched the Auth0 Community forums and have not found a suitable solution or answer.
- I agree to the terms within the Auth0 Code of Conduct.
Description
I added tokenSigningAlg parameter to auth method from express-oauth2-jwt-bearer
Reproduction
npm i
npm run build
npm run install:examples
npm run start:api
Additional context
With this I solved the issue
const checkJwt = auth({
audience: AUDIENCE,
issuerBaseURL: `https://${DOMAIN}`,
tokenSigningAlg: SIGNATURE
});
auth0-react version
2.2.3
React version
^18.2.0
Which browsers have you tested in?
Chrome
frederikprijck commented
Thanks for reaching out. I assume u are using HS256? If that's the case, it's expected that you need to set that. But for RS256, you shouldnt.
Not sure I understand what the specific question here is tho, can you elaborate?
frederikprijck commented
Closing, can reopen if needed.