NGINX Warden Changelog & Release Notes
All notable changes to NGINX Warden (github.com/routewarden/nginx-warden) are documented here.
The format is based on Keep a Changelog, and NGINX Warden adheres to Semantic Versioning.
[v1.4.1] - 2026-10-07 (Latest)
Key Highlights
- Strict Status Code Canonicalization (
status_code):- Removed deprecated
opts.statusandopts.response.statusalias fallbacks in OpenResty Lua configuration (init.lua) in favor of strictly canonicalstatus_code.
- Removed deprecated
- Comprehensive Pattern Test Suite:
- Added full test suite verifying
block_patternsandallow_patternsprecedence, exact URI matching, and custom pattern override behavior across OpenResty phases.
- Added full test suite verifying
[v1.4.0] - 2026-10-05
Key Highlights
- Large Request Body Disk Buffer Fallback (
ngx.req.get_body_file):- Fixed request body inspection bypass when payload size exceeds OpenResty's
client_body_buffer_size. OpenResty buffers large request bodies to temporary disk files wherengx.req.get_body_data()returnsnil. RouteWarden now reads up tocheck_body_max_bytesfromngx.req.get_body_file(), ensuring malicious payloads in large requests are inspected.
- Fixed request body inspection bypass when payload size exceeds OpenResty's
- Canonical Directive Standardization & Duplicate Alias Removal:
- Standardized OpenResty Lua configuration on canonical
enable_default_patternsandenable_default_allow_patterns. - Standardized on
block_patternstable replacingpath_patterns. - Standardized on
mode(replacingaction),status_code(replacingstatus),check_body_patterns, andcheck_body_max_bytes. - Removed duplicate aliases in
config.luaandinit.lua.
- Standardized OpenResty Lua configuration on canonical
[v1.3.1] - 2026-10-02
Key Highlights
- Protocol-Relative Open Redirect Prevention (
response.lua):- Hardened redirect destination validation against protocol-relative URL evasion vectors (e.g.,
//attacker.com). - Protocol-relative destinations are safely detected, discarded, and fallback to root
/, preventing open-redirect exploitation.
- Hardened redirect destination validation against protocol-relative URL evasion vectors (e.g.,
- Security Log Schema Normalization (
level: "warn"):- Added
"level": "warn","status_code", and"matched_pattern"across both standard JSON logger (logger.lua) and emergency fallback logging (init.lua). - Ensures field parity with Grafana Loki and Alloy observability stacks.
- Added
- CI / Version Scripting Portability:
- Improved in-place sed editing in
scripts/update-version.shfor reliable multi-platform execution across macOS (BSD) and Linux (GNU).
- Improved in-place sed editing in
[v1.3.0] - 2026-10-01
Key Highlights
- Trusted Proxies Support (
trusted_proxies):- Added support for
trusted_proxiesinip_filter.luaandconfig.luasupporting exact IP addresses and CIDR subnets across both IPv4 and IPv6. - Forwarded headers (
X-Forwarded-ForandX-Real-IP) are now only trusted whenngx.var.remote_addrmatches a declared trusted proxy. - Neutralizes IP spoofing vectors where attackers attempt to bypass
allowed_ipsrestrictions by injecting forged headers directly into NGINX.
- Added support for
- Redirect Mode Security Hardening:
- Restricts redirect destination targets to safe protocols (
http,https) or relative paths starting with/. - Malformed or dangerous URI schemes (such as
javascript:) are safely discarded and fallback to/.
- Restricts redirect destination targets to safe protocols (
- RFC 1951 DEFLATE Gzip Bomb Compliance:
- Standardized
gzipbombresponse generation with valid RFC 1951 uncompressed DEFLATE blocks, explicit block lengths, final block markers, and gzip trailers. - Resolves decompression errors across strict HTTP clients and vulnerability scanners while maximizing memory consumption on attacker tooling.
- Standardized
- Structured Log Escaping:
- Enhanced JSON escaping in
logger.luato convert all ASCII control characters ([\1-\31%z]) into standard\u00XXunicode escape sequences. - Prevents log corruptions and malformed JSONL outputs when handling malicious binary payloads or control-character injection attempts.
- Enhanced JSON escaping in
- Response Content-Type Headers:
- Explicitly sets
Content-Typeheaders forgzipbombandinfinitestreamresponse modes.
- Explicitly sets
- Normalizer Scope Fix:
- Resolved local variable scoping issue for
raw_uri_pathinnormalizer.lua.
- Resolved local variable scoping issue for
[v1.2.1] - 2026-09-24
Key Highlights
- Query Parameter Attack Surface Hardening (
check_query):- OpenResty Lua inspector evaluates both parameter keys and parameter values.
- Prevents query key injection bypasses (
/?sensitive_file=valueor/?settings.py=).
- Client IP Extraction & Port/Bracket Normalization (
clean_ip):- Automatically strips port suffixes (
:8080) and IPv6 brackets ([...]) fromX-Forwarded-ForandX-Real-IPheaders prior to CIDR evaluation.
- Automatically strips port suffixes (
- OpenResty Concurrency Bug Fix:
- Made the
compiledcache table strictly local withincompile_regexto prevent race conditions across concurrent requests in OpenResty worker processes.
- Made the
- Default Security Logging (
security_log = true):- Enabled
security_log = trueby default inconfig.luafor multi-gateway parity with Traefik and Caddy.
- Enabled
- Lua Regex Hyphen Escaping:
- Escaped hyphens (
%-) outside character classes in fallback pure-Lua pattern matching, preventing Lua's-magic quantifier from misinterpreting regexes in environments without PCRE.
- Escaped hyphens (
- Configuration Parsing Aliases:
- Added support for singular aliases (
path_pattern,block_pattern,allow_pattern,allowed_ip) and single-string values in configuration tables.
- Added support for singular aliases (
- Silent Drop Event Parity:
- Fixed security event logger to accurately emit
action = "silentDrop"when silent drop (HTTP 444) triggers.
- Fixed security event logger to accurately emit
[v1.2.0] - 2026-09-24
Key Highlights
- RouteWarden CLI Compilation Target (
--target nginx):rwarden generate --target nginxgenerates production-readyinit_by_lua_blockLua configuration tables directly fromroutewarden.json.
- Enhanced Test Suites (
test_config.lua):- Comprehensive unit test suites validating configuration tables, singular aliases, and CIDR checks.
[v1.1.0] - 2026-09-20
Key Highlights
- Worker-Level Regex Caching:
- Reuses compiled PCRE matchers across repeated requests and instances to minimize LuaJIT GC pressure.
- Context Auto-Population:
- Enhanced
warden:check()to automatically extract HTTP method, URI, query string, remote address, and headers directly fromngxcontext when called without arguments.
- Enhanced
- Expanded Default Block Patterns:
- Coverage for private keys (
*.pem,*.key), container manifests (Dockerfile*),.DS_Store, and CMS configs.
- Coverage for private keys (
[v1.0.0] - 2026-09-20
Key Highlights
- Initial GA Release of
nginx-warden:- Production-ready Lua middleware for OpenResty and NGINX with
lua-nginx-module. - Executes directly inside worker memory during the
access_by_luaphase without extra proxy latency. - Zero external dependencies: pure OpenResty standard libraries (
ngx.re,resty.string, bit operations). - Complete parity with Go implementations:
- Multi-layer recursive percent-decoding (
%252e%252e). - Semicolon matrix parameter stripping (
/;param/.env). - Windows backslash normalization (
\..\). - Null-byte injection scrubbing (
%00). - Canonical path resolution and dot-segment traversal protection.
- Multi-layer recursive percent-decoding (
- Full suite of 13 response modes supported including HTTP 444 silent drops and reverse slowloris tarpits.
- Structured JSON security logging compatible with CrowdSec parsers.
- Production-ready Lua middleware for OpenResty and NGINX with