Hello, I have the follwing error: I try to login into instagram’s webview (mobile app). the login is success but I gen an error from auth0 that the state param key is invalid. How can I do a proper login even in that webview?
Welcome to the Auth0 Community!
The error that you encounter can have multiple causes, but in general, the state
value that the application generates during the login flow does not match with the state
value returned by Auth0 after authentication. Some of the potential causes of this happening can include :
- a URL mismatch, typically caused by the addition/subtraction of ’ www '. This has been mentioned by a user in the following post, which was the cause of the error in question in that particular case, which is similar to the issue that you encounter;
- the webview could manage the session differently or it has a shorter lifetime than a browser session;
- it’s probably not the case, but a long inactivity time in the webview ( the user sitting on the login page without interaction ) can also invalidate the original
state
Let me know if you were able to pin point the issue and if it’s still ongoing for you. Any updates on the matter could help further track down the cause for this behaviour.
Best regards,
Gerald