JAVA-060 / Beginner
Using @RequestBody without input validation (missing Bean Validation)
Why is this a problem?
Length, range and format are not checked before forwarding data to the DB or external APIs.
How to fix it
java
@PostMapping void create(@Valid @RequestBody ProductDto dto) { ... }
record ProductDto(@NotBlank @Size(max=100) String name, @PositiveOrZero int price) {}