summaryrefslogtreecommitdiff
path: root/tests/filter
diff options
context:
space:
mode:
authorBen Fuhrmannek2014-09-22 18:51:57 +0200
committerBen Fuhrmannek2014-09-22 18:51:57 +0200
commit3a569c100c5b5c359cda16e0ac311032450df02e (patch)
tree9a0bc533421c029daf9f2890a12220ffd5814e56 /tests/filter
parent17a1a8e7dbfab2e9a8a7b236b3aa2c7cc6d5c895 (diff)
test case for suhosin.cookie.max_vars
Diffstat (limited to 'tests/filter')
-rw-r--r--tests/filter/input_filter_cookie_max_vars.phpt27
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/filter/input_filter_cookie_max_vars.phpt b/tests/filter/input_filter_cookie_max_vars.phpt
new file mode 100644
index 0000000..9047df3
--- /dev/null
+++ b/tests/filter/input_filter_cookie_max_vars.phpt
@@ -0,0 +1,27 @@
1--TEST--
2suhosin input filter (suhosin.cookie.max_vars)
3--SKIPIF--
4<?php include "../skipif.inc"; ?>
5--INI--
6suhosin.log.syslog=0
7suhosin.log.sapi=0
8suhosin.log.stdout=255
9suhosin.log.script=0
10suhosin.cookie.max_vars=3
11--COOKIE--
12a=1; b=2; c=3; d=4
13--FILE--
14<?php
15var_dump($_COOKIE);
16?>
17--EXPECTF--
18array(3) {
19 ["a"]=>
20 string(1) "1"
21 ["b"]=>
22 string(1) "2"
23 ["c"]=>
24 string(1) "3"
25}
26ALERT - configured COOKIE variable limit exceeded - dropped variable 'd' - all further COOKIE variables are dropped (attacker '%s', file '%s')
27ALERT - dropped 1 request variables - (0 in GET, 0 in POST, 1 in COOKIE) (attacker 'REMOTE_ADDR not set', file '%s')