I am starting out in the world of creating Custom Rules for Fortify in order to maximize the analysis. I would like to detect a specific case that occurs when a GetMapping method controller receives a personal identification document as a PathVariable. This issue could lead to an information exposure vulnerability and serve as an entry point.
The structure of the method in question is as follows:
@GetMapping(value = "/{nif}", produces = MediaType.APPLICATION_JSON_VALUE)
@RequestBody
public ResponseEntity search(@PathVariable String nif){
...
}
I was unsure how to correctly express this in a .
So far, I have tried to implement it using the manual and GPT, but I am encountering syntax errors and I am also not sure if the implementation is correct.