Index
All Classes and Interfaces|All Packages|Serialized Form
A
- addAuthority(RouteAuthority) - Method in class tech.lastbox.lastshield.security.core.CoreSecurityConfig
-
Adds a
RouteAuthorityto the list of authorities.
C
- configure() - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Configures CORS settings for HTTP security by returning a
Customizerthat customizes theCorsConfigurerfor HTTP security. - CONNECT - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP CONNECT Method
- CoreSecurityConfig - Class in tech.lastbox.lastshield.security.core
-
The
CoreSecurityConfigclass configures the security settings for the web application, including authorization, authentication, and Cross-Site Request Forgery (CSRF) protection. - CoreSecurityConfig(CorsConfig, SecurityUtil, SecurityFilter) - Constructor for class tech.lastbox.lastshield.security.core.CoreSecurityConfig
-
Constructs a new
CoreSecurityConfiginstance with the required dependencies for CORS configuration, security utilities, and a custom security filter. - CorsConfig - Class in tech.lastbox.lastshield.security.core
-
The
CorsConfigclass is responsible for configuring Cross-Origin Resource Sharing (CORS) settings for the application. - CorsConfig() - Constructor for class tech.lastbox.lastshield.security.core.CorsConfig
-
Default constructor for the CorsConfig class.
- CustomUserDetailsService - Class in tech.lastbox.lastshield.security.core
-
CustomUserDetailsServiceis an implementation ofUserDetailsServicethat loads user-specific data during authentication. - CustomUserDetailsService(SecurityUtil, ApplicationContext) - Constructor for class tech.lastbox.lastshield.security.core.CustomUserDetailsService
-
Constructs a
CustomUserDetailsServicewith the required dependencies for security utilities and the Spring application context.
D
- defaultSecurityFilterChain(HttpSecurity) - Method in class tech.lastbox.lastshield.security.core.CoreSecurityConfig
-
Configures the default
SecurityFilterChainwith CORS, CSRF protection, and authority-based access control. - DELETE - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP DELETE Method
- doFilterInternal(HttpServletRequest, HttpServletResponse, FilterChain) - Method in class tech.lastbox.lastshield.security.core.SecurityFilter
-
Filters HTTP requests by validating JWT tokens and setting the authentication context.
E
- EmptyTokenException - Exception Class in tech.lastbox.lastshield.security.core
-
EmptyTokenExceptionis a custom exception that extendsRuntimeException. - EmptyTokenException() - Constructor for exception class tech.lastbox.lastshield.security.core.EmptyTokenException
-
Constructs a new
EmptyTokenExceptionwith the default message "Empty token". - ErrorResponse - Class in tech.lastbox.lastshield.security.core
-
Represents a standardized error response format for API error messages.
- ErrorResponse(String, int) - Constructor for class tech.lastbox.lastshield.security.core.ErrorResponse
-
Constructs a new
ErrorResponsewith the specified error message and status code.
F
- findUserByUsername(Object, String) - Method in class tech.lastbox.lastshield.security.core.SecurityUtil
-
Finds a user by their username by invoking the "findUserByUsername" method on the provided user repository.
G
- GET - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP GET Method
- getDescription() - Method in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
Returns the description associated with this HTTP method.
- getHttpMethods() - Method in class tech.lastbox.lastshield.security.core.RouteAuthority
-
Gets the HTTP methods allowed on this route.
- getMessage() - Method in class tech.lastbox.lastshield.security.core.ErrorResponse
-
Gets the error message.
- getPath() - Method in class tech.lastbox.lastshield.security.core.RouteAuthority
-
Gets the path associated with this
RouteAuthority. - getRoles() - Method in class tech.lastbox.lastshield.security.core.RouteAuthority
-
Gets the roles associated with this
RouteAuthority. - getStatusCode() - Method in class tech.lastbox.lastshield.security.core.ErrorResponse
-
Gets the HTTP status code associated with the error.
- getTimestamp() - Method in class tech.lastbox.lastshield.security.core.ErrorResponse
-
Gets the timestamp indicating when the error occurred.
- getUserAuthorities(Object) - Method in class tech.lastbox.lastshield.security.core.SecurityUtil
-
Converts the user's roles to a list of
GrantedAuthorityobjects. - getUserRepositoryClass() - Method in class tech.lastbox.lastshield.security.core.SecurityUtil
-
Retrieves the class of the user repository annotated with
UserHandler. - GlobalExceptionHandler - Class in tech.lastbox.lastshield.security.core
-
Global exception handler that handles
RuntimeExceptionexceptions across the entire application. - GlobalExceptionHandler() - Constructor for class tech.lastbox.lastshield.security.core.GlobalExceptionHandler
-
Default constructor for the GlobalExceptionHandler class.
H
- handleResourceNotFoundException(RuntimeException) - Method in class tech.lastbox.lastshield.security.core.GlobalExceptionHandler
-
Handles
RuntimeExceptionby creating anErrorResponsewith the exception message and aHttpStatus.BAD_REQUESTstatus code, then returns it as part of aResponseEntitywith aHttpStatus.NOT_FOUNDresponse status. - HEAD - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP HEAD Method
- HttpMethod - Enum Class in tech.lastbox.lastshield.security.core.http
-
Enum
HttpMethodthat represents HTTP methods with their respective descriptions.
I
- isCalled() - Method in class tech.lastbox.lastshield.security.core.CoreSecurityConfig
-
Marks the security configuration as initialized.
L
- loadUserByUsername(String) - Method in class tech.lastbox.lastshield.security.core.CustomUserDetailsService
-
Loads the user details by username.
O
- OPTIONS - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP OPTIONS Method
P
- Password - Annotation Interface in tech.lastbox.lastshield.security.core.annotations
-
The
Passwordannotation is used to mark a field in a user entity class as containing the user's password. - PATCH - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP PATCH Method
- POST - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP POST Method
- PUT - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP PUT Method
R
- RouteAuthority - Class in tech.lastbox.lastshield.security.core
-
Represents the authorization configuration for a specific route within the application.
- RouteAuthority(String) - Constructor for class tech.lastbox.lastshield.security.core.RouteAuthority
-
Constructs a
RouteAuthoritywith the specified path and no roles. - RouteAuthority(String, String) - Constructor for class tech.lastbox.lastshield.security.core.RouteAuthority
-
Constructs a
RouteAuthoritywith the specified path and a single role. - RouteAuthority(String, String, HttpMethod...) - Constructor for class tech.lastbox.lastshield.security.core.RouteAuthority
-
Constructs a
RouteAuthoritywith the specified path, role, and HTTP methods. - RouteAuthority(String, List<String>) - Constructor for class tech.lastbox.lastshield.security.core.RouteAuthority
-
Constructs a
RouteAuthoritywith the specified path and list of roles. - RouteAuthority(String, HttpMethod...) - Constructor for class tech.lastbox.lastshield.security.core.RouteAuthority
-
Constructs a
RouteAuthoritywith the specified path and HTTP methods.
S
- SecurityFilter - Class in tech.lastbox.lastshield.security.core
-
A custom security filter that intercepts HTTP requests and performs token validation to authenticate users based on a JWT (JSON Web Token).
- SecurityFilter(JwtService, ApplicationContext, SecurityUtil) - Constructor for class tech.lastbox.lastshield.security.core.SecurityFilter
-
Constructs a new
SecurityFilter. - SecurityUtil - Class in tech.lastbox.lastshield.security.core
-
Utility class for various security-related operations, such as retrieving user roles and authorities, locating user repositories, and interacting with user entities via reflection.
- SecurityUtil() - Constructor for class tech.lastbox.lastshield.security.core.SecurityUtil
-
Default constructor for the SecurityUtil class.
- setAllowCredentials(Boolean) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets whether credentials (cookies, HTTP authentication, etc.) are allowed in cross-origin requests.
- setAllowedHeaders(String) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets the allowed headers for cross-origin requests.
- setAllowedHeaders(List<String>) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets the allowed headers for cross-origin requests.
- setAllowedMethods(String) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets the allowed HTTP methods for cross-origin requests.
- setAllowedMethods(List<String>) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets the allowed HTTP methods for cross-origin requests.
- setAllowedOrigins(String) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets the allowed origins for cross-origin requests.
- setAllowedOrigins(List<String>) - Method in class tech.lastbox.lastshield.security.core.CorsConfig
-
Sets the allowed origins for cross-origin requests.
- setCsrfProtection(boolean) - Method in class tech.lastbox.lastshield.security.core.CoreSecurityConfig
-
Enables or disables CSRF protection for the application.
- setUserRepository(Class<?>) - Method in class tech.lastbox.lastshield.security.core.SecurityFilter
-
Sets the user repository class to be used for user lookups during authentication.
- shouldNotFilter(HttpServletRequest) - Method in class tech.lastbox.lastshield.security.core.SecurityFilter
-
Determines if this filter should be applied to the given HTTP request.
T
- tech.lastbox.lastshield.security.core - package tech.lastbox.lastshield.security.core
- tech.lastbox.lastshield.security.core.annotations - package tech.lastbox.lastshield.security.core.annotations
- tech.lastbox.lastshield.security.core.http - package tech.lastbox.lastshield.security.core.http
- toString() - Method in class tech.lastbox.lastshield.security.core.RouteAuthority
-
Returns a string representation of the
RouteAuthority. - TRACE - Enum constant in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
HTTP TRACE Method
U
- UserHandler - Annotation Interface in tech.lastbox.lastshield.security.core.annotations
-
The
UserHandlerannotation is used to mark a class or method as a handler for user-related operations within the security context. - Username - Annotation Interface in tech.lastbox.lastshield.security.core.annotations
-
The
Usernameannotation is used to mark a field in a user entity class that represents the username of the user.
V
- valueOf(String) - Static method in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
Returns the enum constant of this class with the specified name.
- values() - Static method in enum class tech.lastbox.lastshield.security.core.http.HttpMethod
-
Returns an array containing the constants of this enum class, in the order they are declared.
All Classes and Interfaces|All Packages|Serialized Form