question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`checks.state argument is missing` after calling `webAuth.authorize()` with google one tap

See original GitHub issue

Description

I am using the method described here to integrate google one-tap with my next js app. In short, it calls webauth.authorize() to authorize with auth0 after authorizing with google. This worked in a previous app that used auth0-passport, but when I run it with my nextjs-auth0 server, it gives me a checks.state argument is missing error.

Reproduction

  • modify the basic nextjs-auth0 example to add in google one tap
  • call webAuth.authorize()

(I’m happy to create a reproducing repo if that is necessary)

Here are the network requests being made from my app

Screen Shot 2022-04-21 at 3 08 22 PM

As you can see, we never visit /api/auth/login, so the state cookie is never set. Is it possible to configure nextjs-auth0 to use a different form of transient state that would work better with webauth?

Environment

Please provide the following:

  • nextjs-auth0 version 1.7.0
  • nextjs 12.1.5
  • auth0-js 9.18.0

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
sakekasicommented, Apr 22, 2022

Just gave it a try, and it works! I like this way much better, since it saves me an extra round of redirects. Thanks a million for the help!

Plus, you just helped me make my bundle a little smaller too. This is awesome 😃

0reactions
adamjmcgrathcommented, Apr 25, 2022

Great! Happy to help @sakekasi

Read more comments on GitHub >

github_iconTop Results From Across the Web

BadRequestError: checks.state argument is missing
Hey All, I find that every so often(not sure of the exact cadence for this error) I get the following error after the...
Read more >
Debugging "checks.state argument is missing" error AUTH0
I am wondering if there are some configuration options that I may be missing in my login handler. import { handleAuth, handleLogin }...
Read more >
Web Authentication: An API for accessing Public Key ... - W3C
The authenticator obtains a biometric or other authorization gesture from the user. The authenticator returns a response to the client, which in ......
Read more >
Adding authentication to a React Native app with Auth0 - Blog
In this tutorial, we're going to look at how to implement authentication in React Native apps using Auth0. Specifically, we're going to:.
Read more >
List of Chromium Command Line Switches - Peter Beverloo
There are lots of command lines which can be used with the Google Chrome ... has no /prefetch:# argument; as such all other...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found