File tree 1 file changed +2
-2
lines changed
src/main/java/com/readyvery/readyverydemo/security/oauth2/service
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ public class CustomOAuth2UserService implements OAuth2UserService<OAuth2UserRequ
31
31
32
32
@ Override
33
33
public OAuth2User loadUser (OAuth2UserRequest userRequest ) throws OAuth2AuthenticationException {
34
-
34
+ System . out . println ( "userRequest = " + userRequest );
35
35
/**
36
36
* DefaultOAuth2UserService 객체를 생성하여, loadUser(userRequest)를 통해 DefaultOAuth2User 객체를 생성 후 반환
37
37
* DefaultOAuth2UserService의 loadUser()는 소셜 로그인 API의 사용자 정보 제공 URI로 요청을 보내서
@@ -48,7 +48,7 @@ public OAuth2User loadUser(OAuth2UserRequest userRequest) throws OAuth2Authentic
48
48
*/
49
49
String registrationId = userRequest .getClientRegistration ().getRegistrationId ();
50
50
SocialType socialType = getSocialType (registrationId );
51
- System . out . println ( "socialType = " + socialType );
51
+
52
52
String userNameAttributeName = userRequest .getClientRegistration ()
53
53
.getProviderDetails ().getUserInfoEndpoint ().getUserNameAttributeName (); // OAuth2 로그인 시 키(PK)가 되는 값
54
54
Map <String , Object > attributes = oAuth2User .getAttributes (); // 소셜 로그인에서 API가 제공하는 userInfo의 Json 값(유저 정보들)
You can’t perform that action at this time.
0 commit comments