Package com.libitum.app.jwt
Class JwtEntryPoint
java.lang.Object
com.libitum.app.jwt.JwtEntryPoint
- All Implemented Interfaces:
org.springframework.security.web.AuthenticationEntryPoint
public class JwtEntryPoint
extends Object
implements org.springframework.security.web.AuthenticationEntryPoint
Clase que maneja los errores de autenticación no autorizada.
Implementa AuthenticationEntryPoint para interceptar las solicitudes no autorizadas.
- Since:
- 1.0
- Version:
- 1.0
- Author:
- Álvaro Carrión
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
commence
(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, org.springframework.security.core.AuthenticationException authException) En este método devuelve un error en el HTTPResponse cuando un usuario no ha sido auntenticado
-
Constructor Details
-
JwtEntryPoint
public JwtEntryPoint()
-
-
Method Details
-
commence
public void commence(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, org.springframework.security.core.AuthenticationException authException) throws IOException, jakarta.servlet.ServletException En este método devuelve un error en el HTTPResponse cuando un usuario no ha sido auntenticado- Specified by:
commence
in interfaceorg.springframework.security.web.AuthenticationEntryPoint
- Parameters:
request
-response
-authException
-- Throws:
IOException
jakarta.servlet.ServletException
-