<img src="https://cdn.jsdelivr.net/gh/ADD-SP/ngx_waf@master/assets/logo.png" width=200 height=200/>
English | 简体中文
Handy, High performance Nginx firewall module.
Current version.Current version.Current version.Hope you can help promote this project. The more stars got, the better this project is. :)
This module comes with a Perl-driven test suite. The test cases are declarative too. Thanks to the Test::Nginx module in the Perl world.
To run it on your side:
## It will take a lot of time, but it only needs to be run once.
cpan Test::Nginx
# You need to specify a temporary directory.
# If the directory does not exist it will be created automatically.
# If the directory already exists it will be **removed** first and then created.
export MODULE_TEST_PATH=/path/to/temp/dir
# You need to specify the absolute path to the dynamic module if you have it installed,
# otherwise you do not need to run this line.
export MODULE_PATH=/path/to/ngx_http_waf_module.so
cd ./test/test-nginx
sh ./init.sh
sh ./start.sh ./t/*.t
Some parts of the test suite requires standard modules proxy, rewrite and SSI to be enabled as well when building Nginx.
$ claude mcp add ngx_waf \
-- python -m otcore.mcp_server <graph>