13 lines
254 B
Plaintext
Raw Normal View History

# Nginx WAF rules for LFI
location / {
set $attack_detected 0;
2025-01-07 18:00:52 +00:00
if ($request_uri ~* "(?:(?:^|[x5c/;]).{2,3}[x5c/;]|[x5c/;].{2,3}(?:[x5c/;]|$))") {
set $attack_detected 1;
}
if ($attack_detected = 1) {
return 403;
}
}