mirror of
https://github.com/elicpeter/nyx.git
synced 2026-06-09 19:45:13 +02:00
Dynamic (#77)
This commit is contained in:
parent
55247b7fcd
commit
991c84a1eb
1464 changed files with 225448 additions and 1985 deletions
13
tests/dynamic_fixtures/header_injection/java/Vuln.java
Normal file
13
tests/dynamic_fixtures/header_injection/java/Vuln.java
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
// Phase 08 (Track J.6) — Java HEADER_INJECTION vuln fixture.
|
||||
//
|
||||
// The function string-concatenates the attacker-controlled `value`
|
||||
// directly into a `Set-Cookie` header set via
|
||||
// `HttpServletResponse.setHeader`. A payload carrying `\r\nSet-Cookie:
|
||||
// nyx-injected=pwn` splits the single header into two on the wire.
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
public class Vuln {
|
||||
public static void run(HttpServletResponse response, String value) {
|
||||
response.setHeader("Set-Cookie", value);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue