Auth0 authentication in Reactjs using OAuth2

Поділитися
Вставка
  • Опубліковано 12 січ 2025

КОМЕНТАРІ • 110

  • @justcreate1387
    @justcreate1387 Рік тому +10

    Thank you! Every single tuturial on Auth0 is SUBPAR. You nailed it on the head. You skipped no details and fully answered any questions that someone implementing this for the first time would ask. Auth0, and other people teaching this, assume that people either:
    1. have plenty of experience with implementing auth. or
    2. people only want to add auth to the frontend(which makes no sense to me, why would we start auth by only discussing the ui?!).
    Once again thanks, instant 'like' and 'subscribe' from me

  • @akshayshinde2403
    @akshayshinde2403 9 місяців тому +2

    One of the best video ever. You covered complete flow of auth0, how it actually works on frontend and backend.

    • @harshbaid.13
      @harshbaid.13 9 місяців тому

      Can you share the code? I am facing implementing this

    • @akshayshinde2403
      @akshayshinde2403 9 місяців тому

      @@harshbaid.13 which tech stack are using for frontend and backend?

    • @harshbaid.13
      @harshbaid.13 9 місяців тому

      ​@@akshayshinde2403 MERN stack

  • @systemforge
    @systemforge Рік тому +2

    OMG... you are a lifesaver! Thank you so much. The mistake I was making was that I wasn't passing the audience

    • @harshbaid.13
      @harshbaid.13 9 місяців тому

      Can you share the code? I am facing implementing this

  • @VitalMercenary
    @VitalMercenary 3 роки тому +6

    Thanks for this video, it was super helpful with the backend API authenticated requests portion!

  • @akshatdubey4421
    @akshatdubey4421 10 місяців тому

    you are a life saver. I spent 3 hours trying to get the JWT

    • @harshbaid.13
      @harshbaid.13 9 місяців тому

      Can you share the code? I am facing implementing this

  • @saurabhjainwal4604
    @saurabhjainwal4604 3 роки тому +1

    Thank you so much dude I was just think of shifting my app authentication from my JWT based auth to a managed service provider and this tutorial cleared almost all the doubts I had, regarding Auth0. Thanks

  • @JachMichael
    @JachMichael 5 місяців тому

    This is gold. Thanks, all the informations you need to secure your app is here :)

  • @chopy1012
    @chopy1012 Рік тому +1

    Thank you, this was really helpful, especially as a person who never used any auth at all

  • @daniyallodhi7765
    @daniyallodhi7765 Рік тому +4

    UPDATE: THE auth0Provider has some changes
    redirectUri is now redirect_uri and both redirect_uri and audience will be written inside the authorizationParams like below

  • @crissatrapi3933
    @crissatrapi3933 11 місяців тому

    wow!! this was seriously a great explanation even for beginners, thanks !!!

  • @ronitpanda5964
    @ronitpanda5964 3 роки тому +2

    Thanks a lot man this was a really helpful tutorial covering all the aspects of using auth0 in a full stack app

  • @akshayking1244
    @akshayking1244 Рік тому +1

    Thank you soooooo much brother! Love this video and your voice as well! Thankful! 🙏

  • @nithinmoorthy5911
    @nithinmoorthy5911 2 роки тому

    This is great. Thank you so much for making this and going from the beginning, without a lot of bloatware components and css

  • @alexanderhergert875
    @alexanderhergert875 Рік тому

    This video contained many useful informations to make my authentication and authorization work even if I did it differently in the end. Thank you very much.

  • @kevklash
    @kevklash 2 роки тому +8

    Let me tell you, not even Auth0 has such a nice tutorial, their info is not that clear. Great video, and thanks for sharing.

    • @mafiacodes
      @mafiacodes  2 роки тому

      Glad you think so!

    • @RaahiSatyam
      @RaahiSatyam Рік тому

      @@mafiacodes i have used Auth0 in Next js app & deployed in netlify but it's not working what can i do?

  • @knowwithfarhan9310
    @knowwithfarhan9310 3 роки тому +1

    Thank you so much for this awesome tutorial, your teaching skill is super.

  • @ConorTurner-f4l
    @ConorTurner-f4l 11 місяців тому

    10/10 Amazing video, best on the subject. Many thanks :)

  • @bhaskardixit1564
    @bhaskardixit1564 2 роки тому

    Nice and clear. Understood the most of concepts thank you

  • @Column1313
    @Column1313 Рік тому

    Thank you so much. everything needed covered eloquently. big fan.

  • @prabujs1785
    @prabujs1785 2 роки тому +1

    great. Thanks for posting this video tutorial.

  • @asmapatel6127
    @asmapatel6127 2 роки тому +1

    hello, I keep on getting error
    Error: You forgot to wrap your component in .
    Source
    src/LogInButton.js (6:34) @ onClick
    4 | const { loginWithRedirect } = useAuth0();
    5 |
    > 6 | return loginWithRedirect()}>Log In
    | ^
    please tell me how to resolve?

  • @mdalkaium
    @mdalkaium 2 роки тому

    Thanks for your nice explanation.

  • @krutarthdarji
    @krutarthdarji Рік тому +1

    Please provide Github repos for this. Great Video by the way!

  • @vikivarun6122
    @vikivarun6122 2 роки тому +1

    Really Great content

  • @daniel67324
    @daniel67324 2 роки тому

    Great stuff. Thank you for sharing.

  • @riteshthakur9250
    @riteshthakur9250 3 роки тому +1

    liked your video
    but i have a request
    can you make microservice with node js videos that can help how to build microservices with node js
    i really wanted to know how to do that but there are not that many videos on youtube which can help
    so please make a full series on how to build microservices with node js

  • @thaisonnguyen8165
    @thaisonnguyen8165 2 роки тому +2

    sir, I followed all your codes but can't get userinfo from backend. When I use the same way in frontend it's works. Is axios can not use in expressJS?

  • @owoichoadoyi7357
    @owoichoadoyi7357 Місяць тому

    Great video.
    What about if I design my own signup and login pages, how will I do it without using loginWithReDirect?

  • @kunaljethva9623
    @kunaljethva9623 2 роки тому

    Awesome video ❣️

  • @prakash_subbaiah_crazy_world
    @prakash_subbaiah_crazy_world 11 місяців тому

    Awesome guide....may i know which flow is this in OAuth 2.0?
    Is this Authorization code flow?
    Please confirm.

  • @chris_ea
    @chris_ea Рік тому

    Thanks, is it necessary to make one more call from the serverside to extract the incoming token to clear info? Isnt it possible JWSverify it locally and decode the jws token?

  • @devJaminur
    @devJaminur 3 роки тому +1

    wow..nice video

  • @asfarwaheed3913
    @asfarwaheed3913 Місяць тому

    How can I redirect the user to some page route other than the / route after logging out ?

  • @parmarjaydip1994
    @parmarjaydip1994 11 місяців тому

    Thank you so much . BTW which font is this ?

  • @fatcat500
    @fatcat500 3 роки тому +2

    great vid thanks

  • @mr.artist486
    @mr.artist486 2 роки тому

    This is very helpful. Could you please make one video telling 'Firebase authorization using auth0' and 'generating custom token s in firebase using auth0' ??

  • @dumindusameendra
    @dumindusameendra Рік тому

    Hi, so if we were to deploy this, is having the auth configurations on index.js not a security risk?

  • @PanlasangMotour
    @PanlasangMotour Рік тому

    How to implement token expiry when the users idle on the page like dashboard also i want to refresh it and have a limit timer per token or maybe reuse the token time when not idle 😕 can we get a tut for that thanks in advance ❤❤

  • @ketkigokhale975
    @ketkigokhale975 Рік тому

    When selcting single page web application option while initiating this project,i keep getting error that you dont have permission to access the resource..i have subscribed to the Auth0 the same way you have explained initially..what to do?

  • @ThanhNguyen-tj9pw
    @ThanhNguyen-tj9pw Рік тому

    thanks for all, but can i ask your theme vsc ?

  • @akshaybisht2660
    @akshaybisht2660 Рік тому

    Hi, i have a Web App in Next.js with TypeScript and also Implemented Auth0 but i am not getting the Access Token? How can I get the Token access so that I can use that Access Token to further call my API's?

  • @hectormanuelsantosbautista7032
    @hectormanuelsantosbautista7032 3 роки тому

    Would the implementation in react native with expo be the same way?

  • @abhishekmazumder2060
    @abhishekmazumder2060 3 роки тому

    Amazing stuff brother. which font are you using on vscode editor?

  • @cosmelvillalobos6448
    @cosmelvillalobos6448 3 роки тому

    hey man how do you apply the same logic in Rails, I am trying to replicate it, but when I try to pull the user information on my backend using rails, I am not getting it.

  • @AyanKhan-dc3eu
    @AyanKhan-dc3eu 2 роки тому

    My react app is working fine on desktop but on android browser its white blank after using auth0 what can be the issue? are you able to use your react app over wifi on android after using auth0?

  • @sumanpokharel1718
    @sumanpokharel1718 3 роки тому

    great video . i have a query tho . errorhandler middleware code does not work (except for new Error("not found")) or am i wrong.

    • @mafiacodes
      @mafiacodes  3 роки тому

      Watch this video for more clarity on error handler to clear all doubts.
      3. Setting up express with Error handler | Node JS API Authentication
      ua-cam.com/video/Bv0sdSGnX2I/v-deo.html

  • @deputyrook6232
    @deputyrook6232 2 роки тому

    so Auth0 is an "extention", kind of, of OAuth2? by authenticating with Auth0 you're authenticating with OAuth2, right?

  • @anishbishnoi29xD
    @anishbishnoi29xD 3 роки тому +2

    Thanks ❤️

  • @manojnavinjamuri5867
    @manojnavinjamuri5867 Рік тому +1

    There is error in my application. Please resolve the error. My API is not authorizing single page application please resolve this

  • @skverskk
    @skverskk 3 роки тому +2

    Awesome!!!

  • @ibrahimzaidi8871
    @ibrahimzaidi8871 3 роки тому

    hey do you have any github repository ? so that i can download it from there

  • @prat_0501
    @prat_0501 2 роки тому

    I am using auth0, How can I authorize logged in user using firebase function?

  • @gabrielfono844
    @gabrielfono844 3 роки тому

    hi sir
    thanks for this amazing tutorials
    hey ,
    I am building an online learning plateform for my community and I wanna to customize the default page that Auth0 provides when users login.
    how could I do it??
    I look forward to hearing from you back
    really love this channel

  • @RossGhazi
    @RossGhazi Рік тому +1

    for min 7 there has been an update, rather than redirect="window.location.origin" use authorizationParams={{
    redirect_uri: window.location.origin,
    }}

  • @arielzarate3643
    @arielzarate3643 Рік тому

    gracias mi hermano me sirvio ♥

  • @fooked1
    @fooked1 3 роки тому

    How can you setup registration callbacks to create a user in your own api's DB?

    • @mafiacodes
      @mafiacodes  3 роки тому

      two options, either create a webhook in auth0 OR as suggested by auth0 itself that every time a request is made to backend using the token, search if u have a user or else create one.

  • @Asha__s
    @Asha__s Рік тому

    I have a doubt!! I am unable to receive email token from user while logging using Facebook.Can someone help ??

  • @bibekpaudyal4434
    @bibekpaudyal4434 4 місяці тому

    How do i make the auth0 login page appear without having to press the login button ? if user is authenticated then they should be redirected to the url they entered else redirect them to login page of auth0

    • @owoichoadoyi7357
      @owoichoadoyi7357 Місяць тому

      I think you can make that setting in your email template in your auth0 account

  • @amjadawan4150
    @amjadawan4150 Рік тому +1

    sir can we use this for any web app. is it completely secured?

    • @mafiacodes
      @mafiacodes  Рік тому +1

      Yes any react app, things may change for react frameworks like nextjs/remix/etc

  • @DTUSEM
    @DTUSEM 3 роки тому +1

    Thanks sir

  • @isurumadusanka9256
    @isurumadusanka9256 3 роки тому +1

    Thank you

  • @riyasahamedm4747
    @riyasahamedm4747 2 роки тому

    Which Terminal you are using?

  • @santhoshkumar2911
    @santhoshkumar2911 3 роки тому +1

    Can you share the code used please.

    • @mafiacodes
      @mafiacodes  3 роки тому +3

      I'll check if I have, but u can follow the video for all the steps

  • @subhashgn1775
    @subhashgn1775 3 роки тому

    Do we need to call the
    getacesstokensilently() for every api call in different component.
    Can we use it as state in root component, if so how to handle when the page gets refreshed?

  • @shobhitsaini8110
    @shobhitsaini8110 2 роки тому +1

    code on github??

  • @ABUTAHER-wg7gz
    @ABUTAHER-wg7gz Рік тому

    if i reload the page

  • @subhashgn1775
    @subhashgn1775 3 роки тому +1

    Is auth0 free forever if the no of users under 7000?

    • @mafiacodes
      @mafiacodes  3 роки тому +1

      Yes I guess so

    • @subhashgn1775
      @subhashgn1775 3 роки тому

      Thank you for the response.
      It was so quick.
      Grateful to you.

  • @dimodimchev7164
    @dimodimchev7164 3 роки тому

    Do you have any idea how this can be replicated with a Django backend?

    • @mafiacodes
      @mafiacodes  3 роки тому

      You use it the same way but the django way, simply get the jwk from auth0 to verify the access token on the backend and the frontend remains the same

    • @dimodimchev7164
      @dimodimchev7164 3 роки тому

      @@mafiacodes I’m struggling on the verification part in Django

  • @alnurabdala6115
    @alnurabdala6115 2 роки тому

    i get an error saying jwt is not a function how do I fix this??

    • @walternomas
      @walternomas 2 роки тому

      var { expressjwt: jwt } = require("express-jwt");

  • @ol1175
    @ol1175 3 роки тому

    BEST!

  • @ivayloivanov7398
    @ivayloivanov7398 2 роки тому

    Guys everything works normally, but there is no req.user. Please help

  • @rakesh3372
    @rakesh3372 3 роки тому

    Hi, can I have a consultation with you?

  • @Ganesh_Golhar
    @Ganesh_Golhar 11 місяців тому

    sir could you please provide Source code

  • @engineerscodes
    @engineerscodes 2 роки тому

    Hey your just exposing your api key & client ID
    what about security

  • @sanitbandekar
    @sanitbandekar 3 роки тому

    Hello where are you ??

    • @mafiacodes
      @mafiacodes  3 роки тому

      some other projects are going on...:)

  • @Ben-hw1lr
    @Ben-hw1lr 2 роки тому

    the code please ...

    • @mafiacodes
      @mafiacodes  2 роки тому

      I don’t really know if I have the code now, if it’s on GitHub the link must be there in the description

    • @Ben-hw1lr
      @Ben-hw1lr 2 роки тому

      @@mafiacodes il n’y a pas de lien github

  • @latestsongsshorts6306
    @latestsongsshorts6306 2 роки тому +1

    req.user not working for me. It gives undefined