Files
sodalive-backend-spring-boot/src/main/kotlin/kr/co/vividnext/sodalive/jwt/JwtAuthenticationEntryPoint.kt
Klaus f81f07bd05 시큐리티 설정
유저 API - 로그인, 회원가입, 계정정보 추가
2023-07-23 03:28:06 +09:00

19 lines
612 B
Kotlin

package kr.co.vividnext.sodalive.jwt
import org.springframework.security.core.AuthenticationException
import org.springframework.security.web.AuthenticationEntryPoint
import org.springframework.stereotype.Component
import javax.servlet.http.HttpServletRequest
import javax.servlet.http.HttpServletResponse
@Component
class JwtAuthenticationEntryPoint : AuthenticationEntryPoint {
override fun commence(
request: HttpServletRequest,
response: HttpServletResponse,
authException: AuthenticationException
) {
response.sendError(HttpServletResponse.SC_UNAUTHORIZED)
}
}