mirror of
https://github.com/elicpeter/nyx.git
synced 2026-06-06 19:35:13 +02:00
10 lines
374 B
Java
10 lines
374 B
Java
// Safe: no XML parser sink reached, body just stored. Used as a baseline
|
|
// to confirm taint-xxe does not fire when the dangerous API is absent.
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
|
public class SafeXxe {
|
|
public String handle(HttpServletRequest req) {
|
|
String body = req.getParameter("xml");
|
|
return body.length() > 0 ? body : "empty";
|
|
}
|
|
}
|