aboutsummaryrefslogtreecommitdiffstats
path: root/config/denyhosts/denyhosts.inc
diff options
context:
space:
mode:
authormcrane <mctch@yahoo.com>2009-08-01 04:58:18 -0600
committermcrane <mctch@yahoo.com>2009-08-01 04:58:18 -0600
commitd8e5677bab893603613adefb6f839f19550a64a3 (patch)
tree7b0e9fdb3cacedd46db608b79999611dee584f02 /config/denyhosts/denyhosts.inc
parente0660de17552d5a859b6215d1b8fa3132119bc8c (diff)
downloadpfsense-packages-d8e5677bab893603613adefb6f839f19550a64a3.tar.gz
pfsense-packages-d8e5677bab893603613adefb6f839f19550a64a3.tar.bz2
pfsense-packages-d8e5677bab893603613adefb6f839f19550a64a3.zip
DenyHosts change startup script
Diffstat (limited to 'config/denyhosts/denyhosts.inc')
-rw-r--r--config/denyhosts/denyhosts.inc50
1 files changed, 25 insertions, 25 deletions
diff --git a/config/denyhosts/denyhosts.inc b/config/denyhosts/denyhosts.inc
index 1efb250a..4d4188b2 100644
--- a/config/denyhosts/denyhosts.inc
+++ b/config/denyhosts/denyhosts.inc
@@ -99,24 +99,25 @@ function php_install_command()
unlink_if_exists("/tmp/denyhosts_log.tmp");
- $denyhosts_sh = "\n";
- $denyhosts_sh .= "name=\"denyhosts\"\n";
- $denyhosts_sh .= "rcvar=\${name}_enable\n";
- $denyhosts_sh .= "\n";
- $denyhosts_sh .= "command=\"/usr/local/bin/denyhosts.py\"\n";
- $denyhosts_sh .= "command_interpreter=\"/usr/local/bin/python2.5\"\n";
- $denyhosts_sh .= "command_args=\"--config /usr/local/etc/denyhosts.conf --daemon\"\n";
- $denyhosts_sh .= "pidfile=\"/var/run/\${name}.pid\"\n";
- $denyhosts_sh .= "\n";
- $denyhosts_sh .= "load_rc_config \$name\n";
- $denyhosts_sh .= "\n";
- $denyhosts_sh .= ": \${denyhosts_enable=\"YES\"}\n";
- $denyhosts_sh .= "\n";
- $denyhosts_sh .= "run_rc_command \"\$1\"\n";
- $fout = fopen("/usr/local/etc/rc.d/denyhosts.sh","w");
- fwrite($fout, $denyhosts_sh);
- unset($denyhosts_sh);
- fclose($fout);
+ //$denyhosts_sh = "\n";
+ //$denyhosts_sh .= "name=\"denyhosts\"\n";
+ //$denyhosts_sh .= "rcvar=\${name}_enable\n";
+ //$denyhosts_sh .= "\n";
+ //$denyhosts_sh .= "command=\"/usr/local/bin/denyhosts.py\"\n";
+ //$denyhosts_sh .= "command_interpreter=\"/usr/local/bin/python2.5\"\n";
+ //$denyhosts_sh .= "command_args=\"--config /usr/local/etc/denyhosts.conf --daemon\"\n";
+ //$denyhosts_sh .= "pidfile=\"/var/run/\${name}.pid\"\n";
+ //$denyhosts_sh .= "\n";
+ //$denyhosts_sh .= "load_rc_config \$name\n";
+ //$denyhosts_sh .= "\n";
+ //$denyhosts_sh .= ": \${denyhosts_enable=\"YES\"}\n";
+ //$denyhosts_sh .= "\n";
+ //$denyhosts_sh .= "run_rc_command \"\$1\"\n";
+ //$fout = fopen("/usr/local/etc/rc.d/denyhosts.sh","w");
+ //fwrite($fout, $denyhosts_sh);
+ //unset($denyhosts_sh);
+ //fclose($fout);
+ //exec("chmod 755 /usr/local/etc/rc.d/denyhosts.sh");
$filename = "/usr/local/etc/denyhosts.conf";
@@ -140,13 +141,12 @@ function php_install_command()
fclose($fout);
- //Error reading file: denyhosts.cfg
- //write_rcfile(array(
- // "file" => "denyhosts.sh",
- // "start" => "start command",
- // "stop" => "rm /var/run/nameofservice.pid"
- // )
- //);
+ write_rcfile(array(
+ "file" => "denyhosts.sh",
+ "start" => "/usr/local/bin/python2.5 /usr/local/bin/denyhosts.py --config /usr/local/etc/denyhosts.conf --daemon",
+ "stop" => "rm /var/run/denyhosts.pid"
+ )
+ );
php_sync_package();