File tree Expand file tree Collapse file tree
kotlin/com/yourssu/scouter/common/implement/support/security/oauth2 Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,15 +7,15 @@ data class GoogleOAuth2Properties(
77 val clientId : String ,
88 val clientSecret : String ,
99 // 기존 path는 널 허용 + 기본값 제공
10- var redirectPath : String? = " /oauth2 /callback/google" ,
10+ var redirectPath : String? = " /oauth /callback/google" ,
1111 var allowedRedirectUris : List <String >? = null ,
1212 val scope : List <String >
1313) {
1414
1515 fun calculateRedirectUri (baseUrl : String? = null): String {
1616 // referer 등으로 들어온 baseUrl에서 오리진만 추출해 안전하게 붙임
1717 val origin = extractOrigin(baseUrl ? : " http://localhost:5173" )
18- val path = (redirectPath ? : " /oauth2 /callback/google" ).let { p -> if (p.startsWith(" /" )) p else " /$p " }
18+ val path = (redirectPath ? : " /oauth /callback/google" ).let { p -> if (p.startsWith(" /" )) p else " /$p " }
1919 return origin.removeSuffix(" /" ) + path
2020 }
2121
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ oauth2:
2626 google :
2727 client_id : ${GOOGLE_OAUTH_CLIENT_ID} # 환경변수에서 주입
2828 client_secret : ${GOOGLE_OAUTH_CLIENT_SECRET} # 환경변수에서 주입
29- redirect-path : /oauth2 /callback/google
29+ redirect-path : /oauth /callback/google
3030 allowed_redirect_uris :
3131 - ${ALLOWED_REDIRECT_URI_LOCAL}
3232 - ${ALLOWED_REDIRECT_URI_DEV}
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ oauth2:
3434 google :
3535 client_id : ${GOOGLE_OAUTH_CLIENT_ID} # 환경변수에서 주입
3636 client_secret : ${GOOGLE_OAUTH_CLIENT_SECRET} # 환경변수에서 주입
37- redirect-path : /oauth2 /callback/google
37+ redirect-path : /oauth /callback/google
3838 allowed_redirect_uris :
3939 - ${ALLOWED_REDIRECT_URI_LOCAL}
4040 - ${ALLOWED_REDIRECT_URI_DEV}
You can’t perform that action at this time.
0 commit comments