Closed rajeshshrma closed 4 years ago
Hi,
The error "Invalid State" is reached when the state token return from the Oauth server is different or too old from the one given by Mattermost at the beginning of the process.
When you click on the Gitlab button you are redirected to the Oauth server to login against LDAP. The first URL you reach on Oauth server is formatted like that : https://<oauth_server>/oauth/authorize.php?response_type=code&client_id=<ID>&redirect_uri=<URL>&state=<TOKEN>
. The last parameter is the state token. The Oauth server should return this token to Mattermost at the end of authentication process.
So, you need to check if the returned token and the initial token are the same and not changed during transport (possible on filtered network). If not, maybe the state token expired too fast. Normally, the state token is automatically managed by Mattermost and Oauth, you do not need to configure anything.
I recommend you to capture network packets between Mattermost, the client and the Oauth server to verify data exchanged between these three parts.
Regards
Thanks Denis.
I resolved It.
Resolved.
Hi @rajeshshrma,
I know its too late, but I'm facing the same issue as you mentioned above. Can you please provide the steps, how you resolved the issue.
Thanks & Regards, Vasanth
Hi,
The error "Invalid State" is reached when the state token return from the Oauth server is different or too old from the one given by Mattermost at the beginning of the process.
When you click on the Gitlab button you are redirected to the Oauth server to login against LDAP. The first URL you reach on Oauth server is formatted like that : https://
We are getting "Invalid State" Error after authentication from LDAP and redirecting to the signup/complete page. We are