Categories

Updated: 11/14/2007

IIS-IP-block

This script uses a custom 404 page that logs the IP address and amount of times it has loaded the 404_error.pl .If someone loads the 404 page 3 times in succession their IP address is logged to the banned_ip_list.log file. Every 60 seconds build_deny_list.pl opens the banned_ip_list.log file and gets the IP address to block. It then generates some C# code, adds that banned IP to the C sharp code, compiles the C code into an executable binary. This C sharp program is actually what adds the IP to the IIS deny list. After the build_deny_list.pl generates and executes the binary, it deletes the original source and executable file.
©2019 A--9.com