mirror of
https://github.com/php/php-src.git
synced 2026-03-24 16:22:37 +01:00
Adds a setting "access.suppress_path" to php-fpm pool configurations which causes successful GET requests to the specified URIs to be excluded from the access log. This is to reduce noise caused by automated health checks. Requests with response codes outwith the successful range 200 - 299, requests made with query parameters and requests which have a Content-Length other than 0 will ignore this setting as a security precaution. Closes GH-8174, #80428 [1] [1] https://bugs.php.net/bug.php?id=80428
35 lines
580 B
PHP
35 lines
580 B
PHP
--TEST--
|
|
FPM: Validates arrays in configuration are correctly set - php_value array must be passed a key
|
|
--SKIPIF--
|
|
<?php include "skipif.inc"; ?>
|
|
--FILE--
|
|
<?php
|
|
|
|
require_once "tester.inc";
|
|
|
|
$cfg = <<<EOT
|
|
[global]
|
|
error_log = {{FILE:LOG}}
|
|
pid = {{FILE:PID}}
|
|
[unconfined]
|
|
listen = {{ADDR}}
|
|
php_value[] = E_ALL
|
|
pm = static
|
|
pm.max_children = 5
|
|
EOT;
|
|
|
|
$tester = new FPM\Tester($cfg);
|
|
$tester->start(['-tt']);
|
|
$tester->expectLogError("\[%s:%d\] You must provide a key for field 'php_value'");
|
|
|
|
?>
|
|
Done
|
|
--EXPECT--
|
|
|
|
Done
|
|
--CLEAN--
|
|
<?php
|
|
require_once "tester.inc";
|
|
FPM\Tester::clean();
|
|
?>
|