Update OAuth2-Front-Approach.md
This commit is contained in:
parent
23c95ea5db
commit
a43277fe2e
@ -6,6 +6,16 @@ A way for the `user` to tell `google` to give an access token to `xorismesiti.gr
|
||||
|
||||
### OAuth2 Frontend/Backend Flow:
|
||||
|
||||
| When | Why | How |
|
||||
|-------|--------------------------|--------------------------------------------------|
|
||||
| 1 | Get Code | Frontend ⇢ Google ⇢ Frontend |
|
||||
| 2 | Exchange Code with Token | Frontend ⇢ Backend ⇢ Google ⇢ Backend ⇢ Frontend |
|
||||
| 4 | Use Token | Frontend ⇢ Google ⇢ Frontend |
|
||||
|
||||
<br><br><br>
|
||||
|
||||
### OAuth2 Frontend/Backend Flow:
|
||||
|
||||
1. Frontend **Redirect** the user to Google's OAuth authorization endpoint `accounts.google.com/o/oauth2`
|
||||
2. User **Login in** to Google and grant permissions
|
||||
3. Google **Redirect** the user back to `xorismesiti.gr/callback` including the authorization `code`
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user