You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I try to configure token authentication correctly, I followed all the step,
I have my User model with acts_as_token_authenticatable
added acts_as_token_authentication_handler_for User to the controller I want to secure
In my database my user have a authentication_token and email field, the token is generated with no problems.
I have a route get /users/:id, when I call it with a wrong token or email it redirect me cause I provide wrong infos.
But with another route post /users/edit on the same controller, I get the following error :
Hi, I try to configure token authentication correctly, I followed all the step,
I have my User model with
acts_as_token_authenticatable
added
acts_as_token_authentication_handler_for User
to the controller I want to secureIn my database my user have a authentication_token and email field, the token is generated with no problems.
I have a route get /users/:id, when I call it with a wrong token or email it redirect me cause I provide wrong infos.
But with another route post /users/edit on the same controller, I get the following error :
Can't verify CSRF token authenticity
Completed 422 Unprocessable Entity in 1ms
ActionController::InvalidAuthenticityToken (ActionController::InvalidAuthenticityToken):
What I missed ? cause the token and email are still the same.
Thank you
The text was updated successfully, but these errors were encountered: