🏄 OAuth 2.0

image.png

  1. Request token
  2. User login & consent
  3. Authorization code
  4. Exchange code for token
  5. Token response
  6. Use token to call Google API

👾 Google Login 구현해보기

Passport 라이브러리 설치

Passport 라이브러리 설치

npm install \\
  express-session \\
  passport \\
  passport-google-oauth20

👉 Google 로그인 인증 키 발급

1️⃣ Google Cloud Platform 접속하기

2️⃣ Project 생성하기

image.png