JJoriping / KKuTu

글자로 놀자! 끄투 온라인
http://jjo.kr/kkutu
GNU General Public License v3.0
328 stars 267 forks source link

구글 로그인 fetch error #1033

Closed GloriaAin closed 2 years ago

GloriaAin commented 2 years ago

Pull requests #598 을 참고해서 passport-google-oauth2 버전을 0.2.0로 변경 해주었고, 스코프도 변경해 주고 npm install도 해준 상태인데요. 근데도 동일한 에러가 계속해서 반복됩니다.

InternalOAuthError: failed to fetch user profile at C:\Users\jimin\Desktop\game\KKuTu\Server\lib\node_modules\passport-google- 
  oauth2\lib\oauth2.js:92:28 at passBackControl  
  (C:\Users\jimin\Desktop\game\KKuTu\Server\lib\node_modules\oauth\lib\oauth2.js:132:9) at IncomingMessage.<anonymous> 
  (C:\Users\jimin\Desktop\game\KKuTu\Server\lib\node_modules\oauth\lib\oauth2.js:157:7) at IncomingMessage.emit 
  (node:events:539:35) at endReadableNT (node:internal/streams/readable:1345:12) at processTicksAndRejections 
  (node:internal/process/task_queues:83:21)

같은 에러가 반복되는데요. 변경한 부분이 잘못되어 이러한 에러가 반복되는 걸까요?

lshqqytiger commented 2 years ago

auth_google.js 파일의 module.exports.config.scope 배열에 "profile" 값이 들어가 있고 Google Cloud Console에서 애플리케이션이 Google+ API를 사용하도록 설정되어 있는지 확인해보세요.

GloriaAin commented 2 years ago

Google+ api 사용하도록 해보았고, 배열에 profile 값이 들어있는 상태입니다. 근데도 계속해서 오류가 뜨네요. 제 서버의 문제일까요?