Build and Secure a CRUD Application with Laravel 6

Hey there Donco!

Do you think there might be some other thing that can be causing an issue here? Apart from the research and things @holly suggested.

I think is something with cache, any idea how to disable cache for that particular URL? Thank you very much indeed

Is it happening in all browsers? And incognito as well? Iā€™m going to ask the team that works on the SDK if theyā€™ve dealt with this before. You can clear your Laravel app cache in the terminal with:

php artisan cache:clear

Then just test again in an incognito window and let me know if that makes a difference. These mystery bugs are always so frustrating, but weā€™ll get it!

1 Like

Thanks a lot Holly for the chase down! @donco_borisov let us know about the results once you have some time to test what Holly suggested!

holly, hi i am a bigginer with laravel my question is there is no code for saving user locally and either for register the user. plz guide me. thanks in advance

Hey there @haroon.momin! Iā€™m sure Holly will address that once sheā€™s online!

Wonderful tutorial Holly! Have come back to it over and over again. I got everything working but the login. When I attempt to login, it says email or password is incorrect. So I click ā€œforgot passwordā€ link and it says it sent me a password reset email but I donā€™t get it. Not in spam folder either. What to do?

Hi @greg7! Iā€™m really glad youā€™re enjoying it! That is strange about the password reset not working. I just tested with my copy from the GitHub repo and Iā€™m able to get a reset password link. Were you ever able to login at all or did you just create that user account from the Auth0 dashboard?

I would start troubleshooting by going into the Auth0 dashboard and changing that user password there. Click on ā€œUsers & Rolesā€ > ā€œUsersā€ and then find the user in the list and click on them. Scroll all the way down and there should be a ā€œChange passwordā€ button (assuming this wasnā€™t a social login user). Then try to sign in again on the Laravel app and let me know if it works that way!

Hey @haroon.momin! Sorry for the late reply! Were you looking to store the users in your own database instead of pulling them from Auth0? This might be what youā€™re looking for. Let me know if that helps!

https://auth0.com/docs/quickstart/webapp/laravel/01-login#optional-custom-user-handling

1 Like

Ah. There were no users there. I must have missed that step. Thank you. It works now!

2 Likes

Hi @holly,
now we decided to shift to own custom DB feature.
i am using a webhook of ā€œngrokā€ to connect to my local DB.
const connection = mysql.createConnection({
host: ā€˜9dd3aabf.ngrok.ioā€™,
port: 3306,
user: ā€˜rootā€™,
password: ā€˜ā€™,
database: ā€˜mycustomdbā€™,
});
this is the login script, it gives me error of " ERROR:-> "connect ETIMEDOUT"".
why is that? plz help
thanks in advanceā€¦

Awesome share!
Well structured and enticing to try.
Iā€™m developing my 1st User Management System project and intend to use CRUD thatā€™s how I landed in here.

3 Likes

Good to hear that! Let us know if you have any questions!

1 Like

set the local APP_URL to match the one in auth0 . for instance localhost:8000 instead of just 8000 missing locally. This worked for me

2 Likes

Glad you have it working!

Hi all, great tutorial!
I am getting this error when I try to login (clicking on the Login link):

" Callback URL mismatch.
The provided redirect_uri is not in the list of allowed callback URLs.
Please go to the [Application Settings page] (https://myauth0ā€¦) and make sure you are sending a valid callback url from your application."

In my .env file, the APP_URL=http://localhost:8000 (I am not using homestead).

Andā€¦ there on the setting at auth0, the callback url is set to http://localhost:8000/ā€¦

1 Like

Awesome @aburobotics! Let me know if you have any questions!

Hey @raulc27! Thanks for reading! Can you try changing the Allowed Callback URL in the Auth0 dashboard to http://localhost:8000/auth0/callback? Let me know if that works!

Hey @holly

Thank you for this outstanding tutorial, your efforts are greatly appreciated. The problem is, Iā€™ve been trying to follow it, by doing exactly the same steps as you did. Now, everything seemed to be working perfectly well, up until the point where the Auth0 PHP plugin and the Auth0 Laravel plugin had to be installed through composer require auth0/login:"~5.0" command in Terminal. After typing in this command, as soon as I hit Return, Iā€™m getting the errors below:

./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Conclusion: don't install auth0/login 5.3.1
    - Conclusion: don't install auth0/login 5.3.0
    - Conclusion: don't install auth0/login 5.2.0
    - Conclusion: don't install auth0/login 5.1.0
    - Conclusion: don't install auth0/login 5.0.2
    - Conclusion: don't install auth0/login 5.0.1
    - Conclusion: remove laravel/framework v7.0.7
    - Installation request for auth0/login ~5.0 -> satisfiable by auth0/login[5.0.0, 5.0.1, 5.0.2, 5.1.0, 5.2.0, 5.3.0, 5.3.1].
    - Conclusion: don't install laravel/framework v7.0.7
    - auth0/login 5.0.0 requires illuminate/support 5.* -> satisfiable by illuminate/support[5.0.x-dev, 5.1.x-dev, 5.2.x-dev, 5.3.x-dev, 5.4.x-dev, 5.5.x-dev, 5.6.x-dev, 5.7.17, 5.7.18, 5.7.19, 5.7.x-dev, 5.8.x-dev, v5.0.0, v5.0.22, v5.0.25, v5.0.26, v5.0.28, v5.0.33, v5.0.4, v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8, v5.2.0, v5.2.19, v5.2.21, v5.2.24, v5.2.25, v5.2.26, v5.2.27, v5.2.28, v5.2.31, v5.2.32, v5.2.37, v5.2.43, v5.2.45, v5.2.6, v5.2.7, v5.3.0, v5.3.16, v5.3.23, v5.3.4, v5.4.0, v5.4.13, v5.4.17, v5.4.19, v5.4.27, v5.4.36, v5.4.9, v5.5.0, v5.5.16, v5.5.17, v5.5.2, v5.5.28, v5.5.33, v5.5.34, v5.5.35, v5.5.36, v5.5.37, v5.5.39, v5.5.40, v5.5.41, v5.5.43, v5.5.44, v5.6.0, v5.6.1, v5.6.10, v5.6.11, v5.6.12, v5.6.13, v5.6.14, v5.6.15, v5.6.16, v5.6.17, v5.6.19, v5.6.2, v5.6.20, v5.6.21, v5.6.22, v5.6.23, v5.6.24, v5.6.25, v5.6.26, v5.6.27, v5.6.28, v5.6.29, v5.6.3, v5.6.30, v5.6.31, v5.6.32, v5.6.33, v5.6.34, v5.6.35, v5.6.36, v5.6.37, v5.6.38, v5.6.39, v5.6.4, v5.6.5, v5.6.6, v5.6.7, v5.6.8, v5.6.9, v5.7.0, v5.7.1, v5.7.10, v5.7.11, v5.7.15, v5.7.2, v5.7.20, v5.7.21, v5.7.22, v5.7.23, v5.7.26, v5.7.27, v5.7.28, v5.7.3, v5.7.4, v5.7.5, v5.7.6, v5.7.7, v5.7.8, v5.7.9, v5.8.0, v5.8.11, v5.8.12, v5.8.14, v5.8.15, v5.8.17, v5.8.18, v5.8.19, v5.8.2, v5.8.20, v5.8.22, v5.8.24, v5.8.27, v5.8.28, v5.8.29, v5.8.3, v5.8.30, v5.8.31, v5.8.32, v5.8.33, v5.8.34, v5.8.35, v5.8.36, v5.8.4, v5.8.8, v5.8.9].
    - don't install illuminate/support 5.5.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.16|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.17|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.2|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.33|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.34|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.35|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.36|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.37|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.39|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.40|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.41|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.43|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.5.44|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.6.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.1|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.10|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.11|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.12|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.13|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.14|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.15|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.16|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.17|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.19|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.2|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.20|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.21|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.22|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.23|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.24|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.25|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.26|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.27|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.29|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.3|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.30|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.31|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.32|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.33|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.34|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.35|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.36|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.37|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.38|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.39|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.4|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.5|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.6|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.7|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.8|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.6.9|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.7.17|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.7.18|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.7.19|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.7.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.1|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.10|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.11|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.15|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.2|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.20|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.21|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.22|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.23|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.26|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.27|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.3|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.4|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.5|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.6|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.7|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.8|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.7.9|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.8.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.11|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.12|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.14|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.15|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.17|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.18|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.19|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.2|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.20|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.22|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.24|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.27|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.29|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.3|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.30|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.31|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.32|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.33|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.34|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.35|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.36|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.4|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.8|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.8.9|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.0.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.1.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.2.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.3.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support 5.4.x-dev|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.22|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.25|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.26|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.33|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.0.4|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.1|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.13|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.16|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.2|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.20|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.22|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.25|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.30|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.31|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.41|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.6|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.1.8|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.19|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.21|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.24|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.25|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.26|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.27|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.28|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.31|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.32|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.37|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.43|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.45|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.6|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.2.7|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.3.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.3.16|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.3.23|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.3.4|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.0|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.13|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.17|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.19|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.27|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.36|don't install laravel/framework v7.0.7
    - don't install illuminate/support v5.4.9|don't install laravel/framework v7.0.7
    - Installation request for laravel/framework (locked at v7.0.7, required as ^7.0) -> satisfiable by laravel/framework[v7.0.7].


Installation failed, reverting ./composer.json to its original content.

I started everything from scratch, twice, that is, just to make sure itā€™s not some sort of human error caused by me. Alas, it was to no avail. Therefore, if you could shed some light on whatā€™s happening here, as well as - hopefully - provide me with a working solution to this weird issue, so that I can successfully complete the tutorial, Iā€™d be very grateful.