Skip to content

Commit f9429eb

Browse files
committed
feat: resolve security exception
1 parent 91ecb3c commit f9429eb

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

presentation/support/auth/src/main/kotlin/org/doorip/presentation/support/auth/SecurityExceptionHandler.kt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ package org.doorip.presentation.support.auth
22

33
import jakarta.servlet.http.HttpServletRequest
44
import jakarta.servlet.http.HttpServletResponse
5+
import org.doorip.domain.UnauthenticatedException
6+
import org.doorip.domain.UnauthorizedException
57
import org.springframework.beans.factory.annotation.Qualifier
68
import org.springframework.security.access.AccessDeniedException
79
import org.springframework.security.core.AuthenticationException
@@ -20,14 +22,14 @@ internal class SecurityExceptionHandler(
2022
response: HttpServletResponse,
2123
authenticationException: AuthenticationException,
2224
) {
23-
// TODO
25+
handler.resolveException(request, response, handler, UnauthenticatedException)
2426
}
2527

2628
override fun handle(
2729
request: HttpServletRequest,
2830
response: HttpServletResponse,
2931
accessDeniedException: AccessDeniedException,
3032
) {
31-
// TODO
33+
handler.resolveException(request, response, handler, UnauthorizedException)
3234
}
3335
}

0 commit comments

Comments
 (0)