nbs-system / naxsi

NAXSI is an open-source, high performance, low rules maintenance WAF for NGINX
GNU General Public License v3.0
4.8k stars 606 forks source link

naxsi whitelist rules on domain vhost #570

Closed vncloudsco closed 11 months ago

vncloudsco commented 3 years ago

I'm using the software on a load balancer server that contains multiple vhosts, How do I whitelist only a specific domain in a file whitelist? I don't want to use each vhost to have a separate whitelist file, I want to merge them, is it possible? Currently I am configuring whitelist for all domains but there is a problem that domains have different api systems, so it is not possible to apply all the same rules to all domains.

wargio commented 3 years ago

i do not understand what you mean with "whitelist a domain", but you can create a file, fill it with whatever you need and use the NGINX directive include

vncloudsco commented 3 years ago

@wargio i have created a detailed issue here can you help me to solve it? https://github.com/nbs-system/naxsi-rules/issues/40