- Does it work if you comment out the VerifyCsrf middleware in the Kernel.php?
- If yes, do your sessions work properly? CSRF saves the token in the session so if they don't work it won't find the token to compare. What sessiondriver are you using?
Auth Login shows 419 page expired on POST request
Hey folks,
I've been getting a 419 page expired error when trying to log in to my system. I by default enabled the middleware auth to the root route so that the first page that comes up is the login page. However, when putting my credentials and submitting the form, the system does not log in and instead shows a 419 error I mentioned in the beginning. Is there any insight on this problem?
Things I've tried:
- I put a @csrf tag inside the login form
- Referenced the token in the meta tag within the header of the master blade so that all pages can have the token
- Gave permissions to the storage folder on my pc
- Cleared cache and cookies in the browser
None of these solutions worked for me. Appreciate any help!
Long story short... turns out that the REAL issue here is the fact I was using a virtual machine version of XAMPP which was mounting a nfs drive to my local computer... and preventing access to all files in the laravel application. Not 100% sure how the vm works or even how to tie it up with a local computer BUT I just switched to a normal desktop installation of XAMPP on my mac and then gave it some write & read permissions to the htdocs folder and boom!! all of the sudden the error went away!
Please or to participate in this conversation.