First of all great tutorial, thanks a lot for all your efforts dude, I've a question, how can I set a remember me system with JWT token ? And also, how to increase expiration duration from the config file (config/auth.php) ?
Thanks dude, I've another question please, if the token is stocked localy, then yo access protected area I've check the user token for that, if Auth::user() did the job, why we stock the token localy ?
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
First of all great tutorial, thanks a lot for all your efforts dude, I've a question, how can I set a remember me system with JWT token ? And also, how to increase expiration duration from the config file (config/auth.php) ?
For the second part of the question, the answer should be:
github.com/tymondesigns/jwt-auth/b...
Would there be a need for remember me? As long as the client has the token; they have access to the system.
You could extend token's time to live for those type of users, that could work...I think.
Override the token ttl
$token = auth()->setTTL(7200)->attempt($credentials);
Further Reading
stackoverflow.com/questions/236038...
Thanks dude, I've another question please, if the token is stocked localy, then yo access protected area I've check the user token for that, if Auth::user() did the job, why we stock the token localy ?