인가
-
세션과 쿠키web( jsp, servlet )/servlet 2024. 7. 15. 10:35
▤ 목차" data-ke-type="html">HTML 삽입미리보기할 수 없는 소스 ✔ Authentication(인증) vs Authorization(인가)👏 한줄 정리인증은 로그인 과정과 같이 신원을 확인하는 과정을 말한다.인가는 로그인을 유지하여 어떠한 자원에 접근할 수 있는지 확인하는 절차를 말한다. 인증은 유저, 장치의 신원을 증명하는 행위인가는 해당 유저, 장치에 접근 권한을 부여/거부 하는 행위인증은 인가로 이어진다인가는 인증으로 이어진다.토큰(인가)으로 신원을 파악하는 방법은 정확도가 떨어지는 방법이다. ✏️ 차이점서로 의미가 비슷하다고 생각할 수 있지만 다르다.인증을 통해 인가가 가능하지만 인가를 통해 인증을 확인할 수 없다.예를 들어 출입증이다. 나의 신원으로 출입증을 받았다고 ..
-
JWT란?web( jsp, servlet )/jsp 2024. 6. 11. 16:19
▤ 목차" data-ke-type="html">HTML 삽입미리보기할 수 없는 소스 https://hi-hahahoho.tistory.com/76세션과 쿠키에 대해 정리했었다. 그 연장선인 jwt를 정리해보고자 한다.세션과 마찬가지로 HTTP 기반이기에 (TCP/IP) 무상태인 환경에서 사용자와 데이터를 주고 받을 수 있도록 상태를 기억하는 기술이다. ✔ JWT(Json Web Token)로그인 기능은 보안에도 신경써야하고 사용자가 불편하지 않도록 신경써야 한다.회원가입시 로그인정보(ID,PW)를 바로 DB에 저장하고 로그인 시 맞춰보기만 했다면 보안상 위험하다.DB가 뚫리면 해당 정보는 전부 유출되기 때문이다.로그인 방식 또한 복잡하지만 로그인 상태를 유지하는 것도 여러 기술이 필요하다.jwt 또한..