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

BadRequestError: checks.state argument is missing #543

Closed
6 tasks done
javiern8410 opened this issue Nov 20, 2023 · 2 comments
Closed
6 tasks done

BadRequestError: checks.state argument is missing #543

javiern8410 opened this issue Nov 20, 2023 · 2 comments

Comments

@javiern8410
Copy link

Checklist

Description

When update to versión 2.5.2 get the following error.

BadRequestError: checks.state argument is missing
at /home/app/node_modules/express-openid-connect/middleware/auth.js:121:31
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

In this version I cannot find the checks object that I found in older versions in the auth.js file.

const checks = {
    max_age,
    code_verifier,
    nonce,
    state,
};

Reproduction

1 - I have a production app with auth0 integrated via openid connect
2 - Update openid-connect
3 - Get error provide in description

Additional context

No response

express-openid-connect version

2.5.2

Express version

4.17.1

Node.js version

v16.15.0 and 18.17.1

@javiern8410 javiern8410 added the bug Something isn't working label Nov 20, 2023
@adamjmcgrath
Copy link
Contributor

Hi @javiern8410 - thanks for raising this

I can't reproduce the error given the steps you've shared.

Take a look at #145 (comment) and #267 (comment) for an explanation of the error and some tips on debugging.

If you can provide a link, repo or HAR file (make sure you redact any secrets like passwords/session cookies) - I'd be happy to investigate for you.

@adamjmcgrath adamjmcgrath added needs investigation and removed bug Something isn't working labels Nov 21, 2023
@javiern8410
Copy link
Author

Hi @adamjmcgrath, I can't send link or repo because it is a private repo. Reading the comments you shared with me I was able to fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants