auth0/auth0-react

checkJwt middleware doesn't work on API example

luis199230 opened this issue · 2 comments

Checklist

Description

I added tokenSigningAlg parameter to auth method from express-oauth2-jwt-bearer

Reproduction

  1. npm i
  2. npm run build
  3. npm run install:examples
  4. 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

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?

Closing, can reopen if needed.