pyo92 / project-lottery

Spring boot 복권 서비스 (Monolithic)
1 stars 0 forks source link

scrap api - only admin user #166

Closed pyo92 closed 4 months ago

pyo92 commented 4 months ago

금번 PR 은 scrap api url 전체를 관리자만 수행할 수 있도록 하는 security configuration 작업이다.

기존에는 인가된 사용자 누구라도 scrap api url 만 알고 있다면, 수행할 수 있었다. 이를 관리자만 수행할 수 있도록 하기 위해 spring security configuration 을 수정했다.

1) 비인가 -> custom authentication entry point handler -> /security/auth -> OAuth 로그인 2) 권한 불충분 -> custom access denied handler -> /security/denied -> index view (+ 에러 메시지)

This closes #165