diff options
| author | jvoisin | 2020-12-28 20:45:33 +0100 |
|---|---|---|
| committer | jvoisin | 2020-12-31 14:14:26 +0100 |
| commit | 032718b7cb93c4143877e355e9bcb6935d8cedcf (patch) | |
| tree | 133c7dda7c02633dd2099a59ea9f28b43b0d9935 /src/tests/broken_configuration_php8/encrypt_regexp_cookies_bad_regexp.phpt | |
| parent | 72d52e5b6933b44ab9f01bc22e3d264626716cd4 (diff) | |
Add tests for broken configuration on php8
Diffstat (limited to 'src/tests/broken_configuration_php8/encrypt_regexp_cookies_bad_regexp.phpt')
| -rw-r--r-- | src/tests/broken_configuration_php8/encrypt_regexp_cookies_bad_regexp.phpt | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/tests/broken_configuration_php8/encrypt_regexp_cookies_bad_regexp.phpt b/src/tests/broken_configuration_php8/encrypt_regexp_cookies_bad_regexp.phpt new file mode 100644 index 0000000..7a8c909 --- /dev/null +++ b/src/tests/broken_configuration_php8/encrypt_regexp_cookies_bad_regexp.phpt | |||
| @@ -0,0 +1,22 @@ | |||
| 1 | --TEST-- | ||
| 2 | Cookie decryption in ipv4 | ||
| 3 | --SKIPIF-- | ||
| 4 | <?php if (!extension_loaded("snuffleupagus")) print "skip"; ?> | ||
| 5 | --INI-- | ||
| 6 | sp.configuration_file={PWD}/config/config_encrypted_regexp_cookies_bad_regexp.ini | ||
| 7 | error_reporting=1 | ||
| 8 | --COOKIE-- | ||
| 9 | super_cookie=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAP3gV9YJZL/pUeNAjCKFW0U2ywmf1CwHzwd2pWM=;awful_cookie=awful_cookie_value; | ||
| 10 | --ENV-- | ||
| 11 | return <<<EOF | ||
| 12 | REMOTE_ADDR=127.0.0.1 | ||
| 13 | HTTP_USER_AGENT=Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/59.0.3071.109 Chrome/59.0.3071.109 Safari/537.36 | ||
| 14 | EOF; | ||
| 15 | --FILE-- | ||
| 16 | <?php var_dump($_COOKIE); ?> | ||
| 17 | --EXPECT-- | ||
| 18 | Fatal error: [snuffleupagus][127.0.0.1][config][log] Invalid configuration file in Unknown on line 0 | ||
| 19 | |||
| 20 | Fatal error: [snuffleupagus][127.0.0.1][config][log] Failed to compile '^super_co[a-z+$': missing terminating ] for character class on line 2. in Unknown on line 0 | ||
| 21 | |||
| 22 | Fatal error: [snuffleupagus][127.0.0.1][config][log] '.name_r()' is expecting a valid regexp, and not '"^super_co[a-z+$"' on line 2 in Unknown on line 0 | ||
