Flask (Python) - Google oAuth 2.0 (Authlib)

  Рет қаралды 53,228

Vuka

Vuka

Күн бұрын

Пікірлер: 96
@mikeconway5544
@mikeconway5544 4 жыл бұрын
Dude... thank you so much for this. Concise and perfectly demonstrated. I looked at about eight different articles prior to finding your video. I wish I'd found this first. I could've saved a day of my life.
@vuka951
@vuka951 4 жыл бұрын
Glad it helped!
@anupamchand3690
@anupamchand3690 2 жыл бұрын
After getting confused with all the authlib documentation, I found this 11min video so easy to follow and implement. Thanks!
@_Nocturnal.
@_Nocturnal. 3 жыл бұрын
At the beginning you were jumping a lot and was hard to understand what you were doing, but later it all became clear. Great video, great explanation well done!
@geraldl7172
@geraldl7172 4 жыл бұрын
Finally what I was looking for. Thank you. Good pace
@vuka951
@vuka951 4 жыл бұрын
Glad it helped!
@alexanderslessor410
@alexanderslessor410 4 жыл бұрын
This is exactly what i was looking for
@karlduckett
@karlduckett 4 жыл бұрын
Awesome tutorial - I disagree with the other comment - the pacing was fine. Great content easy to follow I have subscribed! Can I recommend a facebook 2020 login oauth tutorial. The only one I could find on KZbin was in mandarin :(
@vuka951
@vuka951 4 жыл бұрын
Thanks! I mean its borderline the same as for google only like very slight differences im not sure if it warrants a separate video 🤔
@karlduckett
@karlduckett 4 жыл бұрын
@@vuka951 True - the coding side is virtually identical - however, i'm having difficulty with the Facebook app creation section (localhost vs https vs redirect URIs) driving me a little insane. Bahaha - either way, I've subbed with notify bell on so I'll keep an eye on your uploads in case decide you tackle it :)
@vladgaraba4022
@vladgaraba4022 4 жыл бұрын
@@vuka951 It definitely is. And it's more views for you too. Think about it as someone who is searching to integrate primarily with facebook rather than google
@Arthur-hi3tc
@Arthur-hi3tc 2 жыл бұрын
I got a error: missing "jwks_uri" in metadata, how do i solve this?
@dipendrasingh6878
@dipendrasingh6878 Жыл бұрын
I am getting the same error, How can I resolve ? Anyone here who has solved this issue?
@niltonmedeiros9313
@niltonmedeiros9313 3 жыл бұрын
Perfect, that's what I was looking for! Thank you very much!
@oscarwang7920
@oscarwang7920 4 жыл бұрын
Thanks a lot man ! and what database would you recommend for beginner to use with Flask application (combining with this type of OAuth login and normal register/login on the Flask site )?
@vuka951
@vuka951 4 жыл бұрын
Easiest to use/set up is sqlite3 i got a video up with bcrypt and storing stuff in it using SQLalchemy. For an actual project you would prob use MySQL/PostgreSQL or MongoDB.
@Oratte
@Oratte 4 жыл бұрын
Awesome tutorial! =) Thanks!
@vuka951
@vuka951 4 жыл бұрын
Glad it helped!
@smrutirekhabiswal9449
@smrutirekhabiswal9449 3 жыл бұрын
This is exactly what I was looking for. Thank you😊
@techtinker3949
@techtinker3949 3 жыл бұрын
great video and I'm new to this, so I would like to see how you can capture some of the callback information and get that store in DB (say Mongo). Also do I need to generate a JWT as part the register/login steps or just use the oauth session. thanks
@sheksbear
@sheksbear Жыл бұрын
Thank you this is precise and simple
@pavelhegler6973
@pavelhegler6973 3 жыл бұрын
Everything I have ever looked for. Wish I found this 2 weeks ago
@Jester8890
@Jester8890 4 жыл бұрын
Great video, I implemented this in Python3, much easier than reading the docs straight from Google. One question, what was the alternative method you mentioned would take 20 minutes when you implemented session['email'] = user_info['email']. Is this just implementing a way to store this in a database?
@vuka951
@vuka951 4 жыл бұрын
Its using the google user_info you get, to create (and store)/login (and select) and then put that into the cookie. It wouldn't actually take 20 min to implement just making a video on it would take take that long since i'd have to explain a lot about db stuff and I wasn't really up for doing that. Also Thanks glad it was helpful and saved you time
@GabrielaSantos-hi3el
@GabrielaSantos-hi3el 2 жыл бұрын
I loved it !!!! thank you very much !!!
@franciscovelazquez4352
@franciscovelazquez4352 4 жыл бұрын
For the key you can use secrets library. Thanks for the video.
@vuka951
@vuka951 4 жыл бұрын
You're welcome!
@santiagoguillen6417
@santiagoguillen6417 2 жыл бұрын
Hello, how are you, the video is very good, I would like to know if what you do in the video can be done with Outlook?
@Salehalanazi-7
@Salehalanazi-7 3 жыл бұрын
No bullshit. better and more secure than the udacity course...
@daniyaldehleh8253
@daniyaldehleh8253 4 жыл бұрын
Hi There, First of all, thanks for the great content. I would just like to know, once I turned the app to RESTful, am I permitted to make posts/put requests to users' profiles? if so, how and what credentials do I need?
@GerardoMares
@GerardoMares 4 жыл бұрын
Nice, great video
@vuka951
@vuka951 4 жыл бұрын
Glad you enjoyed it
@akhileshchander5307
@akhileshchander5307 4 жыл бұрын
perfect
@miguelfernandes657
@miguelfernandes657 2 жыл бұрын
Perfect, thanks!
@vaibhavbnagrale8578
@vaibhavbnagrale8578 5 ай бұрын
Perfect video less code and woks totally fine.
@michealhall7776
@michealhall7776 3 жыл бұрын
If anyone is wondering that is not how you work with the flask session object session.get('email') #> None is the default if not found. session.pop('email', None) #> None is needs to be defined unless you wanted to raise an error session.clear() #> Deletes all session information. This is how you create a strong secret_key openssl rand -hex 32 store it as a env outside the project folder so you don't submit secret to git export SECRET_KEY="....Place secret here...." from os import getenv SECRET_KEY = getenv('SECRET_KEY')
@anindyabhattacharya4878
@anindyabhattacharya4878 Жыл бұрын
I am getting error invalid client. I try using flask_oauth library with same creds, I get success. But with authlib I am getting invalid client exception in authorize_access_token method. Need help. Thanks in advance
@thiago1642
@thiago1642 2 жыл бұрын
nice and clean
@mahelnapo8385
@mahelnapo8385 4 жыл бұрын
How do I check what is within the json data. I'll like to be able to print the name of the person logged in onto an existing html page. Would a double curly bracket work?
@bawa1169
@bawa1169 4 жыл бұрын
Hi @vuka I have a doubt, I am able to create new credentials on console.developers.google.com It's asking Authorised domains , Application Homepage link , Application Privacy Policy link . What should I put in these catagories
@vuka951
@vuka951 4 жыл бұрын
First of all you should be going to: Create Credentials => oAuth client ID => Application type => Web Application => Create As for those categories if you can ignore them and just dont put anything if possible. But since I don't get them when creating new credentials you might be creating a different thing. It should ask you for "Authorized redirect URIs" that should be as is it in the video localhost:5000/..etc And it should ask you for: "Authorized JavaScript origins" that should be also wherever your frontend is hosted localhost:5000 (in the video) Hope some of this helps, GL!
@vuka951
@vuka951 4 жыл бұрын
I know its a bit late(a week later) but here you go: kzbin.info/www/bejne/roPQl3WDjrGXaNk On a fresh account literally how to get the credentials
@ankushdua8661
@ankushdua8661 4 жыл бұрын
i need an advice from you please so i have my flask app login page already where user can either login via email and password or via google except that i havent implemented the google oauth part yet so that button on login page redirects to nothing rn my question is do i need to create another route for google with oauth or is is there a way to implement oauth in the existing login page? and one more question --- how do i extract the user information like email and name and other activity by the user to be stored in the database for next time the user logs in with google ofcourse thank you in advance
@aibasics7206
@aibasics7206 2 жыл бұрын
RuntimeError: Missing "jwks_uri" in metadata.......getting this error plz help
@theajaypraj5338
@theajaypraj5338 Жыл бұрын
same ...you solved? tell me i need help
@nitinupadhyay9193
@nitinupadhyay9193 3 жыл бұрын
Brilliant
@joakimjohansson8274
@joakimjohansson8274 4 жыл бұрын
Great video! Could you build upon this and show how to work with Google Services like Google Drive with the Oauth credentials? Take care!
@vuka951
@vuka951 4 жыл бұрын
Thanks! Maybe in the future 😉
@nikitabharane1022
@nikitabharane1022 3 жыл бұрын
How to login zoho crm using OAUTH2.0? Or python? Do you know about it if yes please let me know.
@noah-4482
@noah-4482 3 жыл бұрын
Thank you
@utkarshsinha5838
@utkarshsinha5838 4 жыл бұрын
I tried creating a facebook login by following this video. The login part seems to work but as soon as it redirects to authorization it throws the error "KeyError: 'email'" . Are there any other changes to be made as well?
@vuka951
@vuka951 4 жыл бұрын
Yes you do have to change the code a bit to make it work with Facebook. You can find all the info on the authlib docs: docs.authlib.org/en/stable/
@mgreek31
@mgreek31 2 жыл бұрын
nice
@anirudhgrack7560
@anirudhgrack7560 2 жыл бұрын
Not working for me getting RuntimeError: ‘Missing “jwk_uri” in metadata’
@willcline9404
@willcline9404 2 жыл бұрын
me too
@terarara189
@terarara189 2 жыл бұрын
@@willcline9404 me 3
@theajaypraj5338
@theajaypraj5338 Жыл бұрын
me 4
@MichaelSmith-tw6yx
@MichaelSmith-tw6yx Ай бұрын
me 5
@zaheerkhan8097
@zaheerkhan8097 4 жыл бұрын
Nice video. Plz make video on cross origin request using flask
@vuka951
@vuka951 4 жыл бұрын
If you mean like enabling cors (cross origin requests) there already is one. kzbin.info/www/bejne/hX2ao6qdm7arl6M
@zaheerkhan8097
@zaheerkhan8097 4 жыл бұрын
@@vuka951 Nice !
@viktorkuzmanov3086
@viktorkuzmanov3086 3 жыл бұрын
on 8:22 when i run my app i get Not Found The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.
@Ruypbf99
@Ruypbf99 3 жыл бұрын
Same problem. I found out I had a misstype in my code, you probably have the same
@leminos6119
@leminos6119 3 жыл бұрын
How to modify this code to use with blueprint because it is throwing several errors
@willcline9404
@willcline9404 2 жыл бұрын
Getting this error: " RuntimeError('Missing "jwks_uri" in metadata') RuntimeError: Missing "jwks_uri" in metadata". Anyone dealt with this?
@macvisys7127
@macvisys7127 Жыл бұрын
same error ia malso getting
@theajaypraj5338
@theajaypraj5338 Жыл бұрын
Missing "jwks_uri" in metadata /?
@CodeTerra
@CodeTerra 3 жыл бұрын
How to access user Google Drive for modification via Google login in Flask
@asishmishra1605
@asishmishra1605 4 жыл бұрын
after login to google,i want to check if he is already present in database or not.if not than i will log him out ,if yes i will redirect him to welcome page.How to do this.
@alvingultiano519
@alvingultiano519 2 жыл бұрын
im having an error called "ModuleNotFoundError: No module named 'authlib.integrations" can you make a new video for googleOauth
@mgreek31
@mgreek31 2 жыл бұрын
pip install requests
@kiranthakur7463
@kiranthakur7463 3 жыл бұрын
Bro You did fantastic work. I have issue with 'auth_decorators' library... How to install it.
@anonimes4005
@anonimes4005 2 жыл бұрын
just put the .py file in the same directory
@EstebanRigoni
@EstebanRigoni 4 жыл бұрын
How can I check if the user is still connected after n minutes? Just verifying the session cookie? Thank you
@vuka951
@vuka951 4 жыл бұрын
You can check if the user is logged in only when they send a request
@mediatwinkleTV
@mediatwinkleTV Жыл бұрын
This is how you earn a subscriber :)
@shardulkulkarni1008
@shardulkulkarni1008 4 жыл бұрын
Nit !!!! simplest code !
@dibri
@dibri 2 жыл бұрын
where can I find other scopes
@utkarshsinha5838
@utkarshsinha5838 4 жыл бұрын
Will 'userinfo' be valid for facebook login as well?
@vuka951
@vuka951 4 жыл бұрын
I don't know for sure haven't done Facebook login with authlib. I suggest looking trough the docs there is prob. info about that there: docs.authlib.org/en/stable/
@hrishavsahu9485
@hrishavsahu9485 2 жыл бұрын
can you make a video for the same using fastapi
@shivrajpatil4869
@shivrajpatil4869 4 жыл бұрын
how can I send mail using acquired token?
@nonamearmyid50
@nonamearmyid50 4 жыл бұрын
how to get client name info from facebook using aouth flask? please!
@nandhiniram4364
@nandhiniram4364 3 жыл бұрын
i need source code of flask yahoo login?
@terarara189
@terarara189 2 жыл бұрын
stuck in error after login
@penguin0123
@penguin0123 8 ай бұрын
Hi @Vuka and buddies. When I try Login route I got this --> Access blocked: This app’s request is invalid Error 400: redirect_uri_mismatch Please help
@umerwazir2806
@umerwazir2806 4 жыл бұрын
When getting user email in user_info, I get error of " KeyError: 'email' " ?
@ilya-zhirukhin
@ilya-zhirukhin Жыл бұрын
не актуально
@alexanderslessor410
@alexanderslessor410 4 жыл бұрын
bruh
@vuka951
@vuka951 4 жыл бұрын
vro
@chrisschuller7055
@chrisschuller7055 3 жыл бұрын
You explain almost nothing.
Implementing OAuth 2.0 from SCRATCH
24:56
Carberra
Рет қаралды 3 М.
Python Flask Google Login: [HOW TO]  Google Login for Flask (2021)
14:06
Когда отец одевает ребёнка @JaySharon
00:16
История одного вокалиста
Рет қаралды 14 МЛН
Life hack 😂 Watermelon magic box! #shorts by Leisi Crazy
00:17
Leisi Crazy
Рет қаралды 80 МЛН
小路飞嫁祸姐姐搞破坏 #路飞#海贼王
00:45
路飞与唐舞桐
Рет қаралды 29 МЛН
Implement login with google in python flask applications with authlib
26:50
"The Life & Death of htmx" by Alexander Petros at Big Sky Dev Con 2024
23:01
Montana Programmers
Рет қаралды 64 М.
OAuth 2.0 explained with examples
10:03
ByteMonk
Рет қаралды 146 М.
Add Google Hosted Authentication to a Python Flask App
12:55
Vincent Stevenson
Рет қаралды 20 М.
Authenticating a Flask API Using JSON Web Tokens
20:33
Pretty Printed
Рет қаралды 175 М.
NestJS & Google OAuth2 with Passport
1:12:18
Anson the Developer
Рет қаралды 39 М.
✅ FastAPI Tutorial • Implement GOOGLE SIGNIN LIKE A PRO
35:25
Amo Procedures
Рет қаралды 20 М.
OAuth 2.0 - a dead simple explanation
9:16
Jan Goebel
Рет қаралды 22 М.