From ade2c6bcf5cc3ba208b202e6639c7856636a9c95 Mon Sep 17 00:00:00 2001 From: b1v1r Date: Fri, 5 Feb 2010 18:17:18 +0000 Subject: [PATCH] Cleanup some regression tests. --- apache2/t/regression/config/10-misc-directives.t | 2 +- apache2/t/regression/misc/00-multipart-parser.t | 15 +++++++-------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/apache2/t/regression/config/10-misc-directives.t b/apache2/t/regression/config/10-misc-directives.t index 7968785e..0dffcaf1 100644 --- a/apache2/t/regression/config/10-misc-directives.t +++ b/apache2/t/regression/config/10-misc-directives.t @@ -96,7 +96,7 @@ return 1; }, match_log => { - debug => [ qr/Created temporary file: $ENV{TEMP_DIR}/, 1 ], + debug => [ qr/Created temporary file.*$ENV{TEMP_DIR}/, 1 ], -debug => [ qr/Failed to /, 1 ], }, match_response => { diff --git a/apache2/t/regression/misc/00-multipart-parser.t b/apache2/t/regression/misc/00-multipart-parser.t index 818dd23a..5ed94ebc 100644 --- a/apache2/t/regression/misc/00-multipart-parser.t +++ b/apache2/t/regression/misc/00-multipart-parser.t @@ -420,16 +420,15 @@ SecDebugLog $ENV{DEBUG_LOG} SecDebugLogLevel 9 SecRequestBodyAccess On - #SecRule MULTIPART_STRICT_ERROR "\@eq 1" "phase:2,deny,status:403" - SecRule MULTIPART_UNMATCHED_BOUNDARY "\@eq 1" "phase:2,deny,status:403" - SecRule REQBODY_PROCESSOR_ERROR "\@eq 1" "phase:2,deny,status:403" + SecRule MULTIPART_STRICT_ERROR "!\@eq 1" "phase:2,deny" + SecRule REQBODY_PROCESSOR_ERROR "!\@eq 1" "phase:2,deny" ), match_log => { debug => [ qr/name: a.*variable: 1.*Invalid part header \(header name missing\)/s, 1 ], -debug => [ qr/Adding request argument \(BODY\): name "b"/s, 1 ], }, match_response => { - status => qr/^403$/, + status => qr/^200$/, }, request => new HTTP::Request( POST => "http://$ENV{SERVER_NAME}:$ENV{SERVER_PORT}/test.txt", @@ -707,16 +706,16 @@ SecDebugLog $ENV{DEBUG_LOG} SecDebugLogLevel 9 SecRequestBodyAccess On - #SecRule MULTIPART_STRICT_ERROR "\@eq 1" "phase:2,deny,status:403" - SecRule MULTIPART_INVALID_QUOTING "\@eq 1" "chain,phase:2,deny,status:403" - SecRule REQBODY_PROCESSOR_ERROR "\@eq 1" + SecRule MULTIPART_STRICT_ERROR "!\@eq 1" "phase:2,deny" + SecRule MULTIPART_INVALID_QUOTING "!\@eq 1" "phase:2,deny" + SecRule REQBODY_PROCESSOR_ERROR "\@eq 1" "chain,phase:2,deny" ), match_log => { debug => [ qr/name: a.*variable: 1.*Duplicate Content-Disposition name/s, 1 ], -debug => [ qr/Adding request argument \(BODY\): name "b/s, 1 ], }, match_response => { - status => qr/^403$/, + status => qr/^200$/, }, request => new HTTP::Request( POST => "http://$ENV{SERVER_NAME}:$ENV{SERVER_PORT}/test.txt",