Spring Security - OAuth2 && JWT (JSON Web Token) - 1

spring security 를 통해서 OAuth2 구현을 해 볼 예정이며, 먼저 이번 글에서는 OAuth2 개념과 JWT 개념에 대해서 정리해보려고 한다. OAuth 2 란? OAuth 2.0 권한 부여 프레임워크를 사용하면 타사 애플리케이션의 자원 소유자와 HTTP 서비스 간의 승인 상호 작용을 조정해 자원 소유자를 대신해 HTTP 서비스에 대한 제한된 접근 권한을 얻거나 타사 애플리케이션이 자체적으로 접근 권한을 얻는다. 해당 사양은 RFC 5849, The OAuth 1.0 Protocol 에 설명된 더 이상 사용하지 않는 OAuth 1.0 프로토콜을 대체한다. The OAuth 2.0 authorization framework enables a third-party application to obtain limited access to an HTTP service, either on behalf of a resource owner by orchestrating an approval interaction between the resource owner and the HTTP service, or by allowing the third-party application to obtain access on its own behalf. This specification replaces and obsoletes the OAuth 1.0 protocol described in RFC 5849 . https://tools.ietf.org/html/rfc6749 OAuth 2 를 활용하는 방법을 제대로 이해하려면 특정 역할과 역할 간의 관계를 이해해야 한다. 그렇다면, 각 권한 부여 프로세스에 참여하는 역할을 살펴보자. OAuth defines four roles: resource owner An entity capable of granting access to a pro...