PHP Classes

File: init.d/

Recommend this page to a friend!
  Classes of Rolands Kusins   PHP Block Host   init.d/   Download  
File: init.d/
Role: Auxiliary data
Content type: text/plain
Description: Init.d script for Gentoo
Class: PHP Block Host
Parse logs and block suspicious hosts
Author: By
Last change:
Date: 9 years ago
Size: 806 bytes


Class file image Download
#!/sbin/runscript extra_commands="stats list dlist" description="HostBlock analyzes log files and updates access files to deny access" description_stats="Shows statistics about blacklisted IPs" description_list="Lists all blacklisted IPs" description_dlist="Detailed list with all blacklisted IPs (includes count and last activity)" depend() { use logger } start() { ebegin "Starting HostBlock daemon" start-stop-daemon --start -exec /usr/bin/hostblock --pidfile /var/run/ -- --daemon eend $? } stop() { ebegin "Stopping HostBlock daemon" start-stop-daemon --stop --pidfile /var/run/ eend $? } stats() { /usr/bin/hostblock --statistics } list() { /usr/bin/hostblock --list } dlist() { /usr/bin/hostblock --list --time --count }