diff --git a/spring-security-modules/spring-security-web-rest/pom.xml b/spring-security-modules/spring-security-web-rest/pom.xml
index 76d9ad37de..6bc9131e3e 100644
--- a/spring-security-modules/spring-security-web-rest/pom.xml
+++ b/spring-security-modules/spring-security-web-rest/pom.xml
@@ -10,9 +10,9 @@
com.baeldung
- parent-spring-5
+ parent-boot-3
0.0.1-SNAPSHOT
- ../../parent-spring-5
+ ../../parent-boot-3
@@ -144,6 +144,12 @@
commons-fileupload
${commons-fileupload.version}
+
+ jakarta.servlet
+ jakarta.servlet-api
+ ${jakarta.servlet.version}
+ provided
+
@@ -155,6 +161,13 @@
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+ true
+
+
org.codehaus.cargo
cargo-maven2-plugin
@@ -237,6 +250,9 @@
2.9.0
1.6.1
+ 6.0.13
+ 6.1.5
+ 6.0.0
\ No newline at end of file
diff --git a/spring-security-modules/spring-security-web-rest/src/main/java/com/baeldung/errorhandling/CustomRestExceptionHandler.java b/spring-security-modules/spring-security-web-rest/src/main/java/com/baeldung/errorhandling/CustomRestExceptionHandler.java
index 02bc0a2512..a98acd2f9a 100644
--- a/spring-security-modules/spring-security-web-rest/src/main/java/com/baeldung/errorhandling/CustomRestExceptionHandler.java
+++ b/spring-security-modules/spring-security-web-rest/src/main/java/com/baeldung/errorhandling/CustomRestExceptionHandler.java
@@ -9,8 +9,8 @@ import javax.validation.ConstraintViolationException;
import org.springframework.beans.TypeMismatchException;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpStatus;
+import org.springframework.http.HttpStatusCode;
import org.springframework.http.ResponseEntity;
-import org.springframework.validation.BindException;
import org.springframework.validation.FieldError;
import org.springframework.validation.ObjectError;
import org.springframework.web.HttpMediaTypeNotSupportedException;
@@ -31,7 +31,7 @@ public class CustomRestExceptionHandler extends ResponseEntityExceptionHandler {
// 400
@Override
- protected ResponseEntity