From 605ba02a8940e8427f164b8e4aeb83662c409b2c Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Tue, 27 Oct 2009 21:35:22 -0400 Subject: Add downloaded from location --- config/apache_mod_security/apache_mod_security.inc | 9 +++++++++ config/apache_mod_security/apache_mod_security.xml | 5 +++++ config/apache_mod_security/apache_mod_security_settings.xml | 10 +++++++++- config/apache_mod_security/rules/snortmodsec-rules.txt | 2 ++ 4 files changed, 25 insertions(+), 1 deletion(-) (limited to 'config/apache_mod_security') diff --git a/config/apache_mod_security/apache_mod_security.inc b/config/apache_mod_security/apache_mod_security.inc index eee5af4c..76aecabe 100644 --- a/config/apache_mod_security/apache_mod_security.inc +++ b/config/apache_mod_security/apache_mod_security.inc @@ -179,6 +179,12 @@ function generate_apache_configuration() { else $secrequestbodylimit = "10485760"; + // ErrorDocument + if($config['installedpackages']['apachemodsecuritysettings']['config'][0]['errordocument']) + $errordocument = $config['installedpackages']['apachemodsecuritysettings']['config'][0]['errordocument']; + else + $errordocument = ""; + // SecAuditEngine if($config['installedpackages']['apachemodsecuritysettings']['config'][0]['secauditengine']) $secauditengine = $config['installedpackages']['apachemodsecuritysettings']['config'][0]['secauditengine']; @@ -798,6 +804,9 @@ DefaultType text/plainm # 1) plain text 2) local redirects 3) external redirects # # Some examples: + +{$errordocument} + #ErrorDocument 500 "The server made a boo boo." #ErrorDocument 404 /missing.html #ErrorDocument 404 "/cgi-bin/missing_handler.pl" diff --git a/config/apache_mod_security/apache_mod_security.xml b/config/apache_mod_security/apache_mod_security.xml index c4196e7d..23447a89 100644 --- a/config/apache_mod_security/apache_mod_security.xml +++ b/config/apache_mod_security/apache_mod_security.xml @@ -72,6 +72,11 @@ 0644 http://www.pfsense.com/packages/config/apache_mod_security/rules/10_asl_rules.conf + + /usr/local/apachemodsecurity/rules/ + 0644 + http://www.pfsense.com/packages/config/apache_mod_security/rules/snortmodsec-rules.txt + Proxy Server Settings diff --git a/config/apache_mod_security/apache_mod_security_settings.xml b/config/apache_mod_security/apache_mod_security_settings.xml index 2c2b6c7d..31ffe5fe 100644 --- a/config/apache_mod_security/apache_mod_security_settings.xml +++ b/config/apache_mod_security/apache_mod_security_settings.xml @@ -170,6 +170,14 @@ + + Custom mod_security ErrorDocument + errordocument + + textarea + 10 + 75 + Custom mod_security rules modsecuritycustom @@ -177,7 +185,7 @@ textarea 10 75 - + apache_mod_security_resync(); diff --git a/config/apache_mod_security/rules/snortmodsec-rules.txt b/config/apache_mod_security/rules/snortmodsec-rules.txt index 0e46aa1e..43713069 100644 --- a/config/apache_mod_security/rules/snortmodsec-rules.txt +++ b/config/apache_mod_security/rules/snortmodsec-rules.txt @@ -1,3 +1,5 @@ +# Downloaded from http://www.modsecurity.org/documentation/snortmodsec-rules.txt + # WEB-ATTACKS ps command attempt SecFilterSelective THE_REQUEST "/bin/ps" -- cgit v1.2.3