环境
client(192.168.313) > nginx(192.168.3.13) > 后端服务(192.168.3.11)
以下为nginx配置
location / {
proxy_connect_timeout 5s;
proxy_send_timeout 5s;
proxy_read_timeout 5s;
proxy_pass http://192.168.3.11;
}
502
在后端拒绝所有访问本地80端口的请求
iptables -I INPUT -p tcp --dport 80 -j REJECT
客户端发起访问
在nginx上抓包
tcpdump -i any port 80 -w 502.pcap
504
在后端丢弃所有对80端口的请求
iptables -I INPUT -p tcp --dport 80 -j DROP
客户端发起请求
在nginx抓包
tcpdump -i any port 80 -w 504.pcap
syn