nginx设置ip黑名单的方法

在 nginx.conf 中新增一行配置

include deny.conf;

在 deny.conf 中新增一行配置

deny  127.0.0.1

重载nginx,则 127.0.0.1 请求 nginx 时,返回 403

作者: 二皮

Hackers please go away