php-src/sapi/cli
Arnaud Le Blanc c561f7da85
Refresh zend_mm shadow key on fork
The shadow key is refreshed when resetting the memory manager between two
requests. But in forking SAPIs the first request of a child process inherits the
shadow key of the parent. As a result, a leak of the shadow key during the first
request of one process gives away the shadow key used during the first request
of other processes. This makes the key refresh mechanism less useful.

Here I ensure that we refresh the shadow key after a fork. We can not reset the
manager as there may be active allocations. Instead, we have to recompute shadow
pointers with the new key.

Closes GH-16765
2025-07-29 14:00:37 +02:00
..
tests Fix expectations in version string tests 2025-07-27 09:40:23 +02:00
cli.h sapi/cli: Print non-default INI settings for --ini=diff (#17762) 2025-03-04 08:42:06 +01:00
cli_win32.c
config.m4 Autotools: Sync CS in sapi/cli (#15410) 2024-08-14 21:39:19 +02:00
config.w32 Avoid duplicate build rules 2025-02-01 11:21:09 +01:00
CREDITS
generate_mime_type_map.php Update mime-db from 1.45.0 to 1.52.0 2022-07-08 07:39:38 +01:00
Makefile.frag Sync leading and final newlines in source code files 2018-10-14 12:56:38 +02:00
mime_type_map.h Update mime-db from 1.45.0 to 1.52.0 2022-07-08 07:39:38 +01:00
php.1.in Drop support for -z CLI/CGI option 2025-03-03 08:21:56 +01:00
php_cli.c cli: Fix swapped output in php --ini (#18557) 2025-05-14 21:36:20 +02:00
php_cli_process_title.c sapi/cli: Refactor process title setting code (#17177) 2024-12-16 22:50:06 +00:00
php_cli_process_title.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
php_cli_process_title.stub.php Add stubs for SAPIs 2020-07-10 14:20:18 +02:00
php_cli_process_title_arginfo.h Do not generate frameless info items when func info generation is disabled 2024-02-18 11:39:00 +01:00
php_cli_server.c Refresh zend_mm shadow key on fork 2025-07-29 14:00:37 +02:00
php_cli_server.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
php_cli_server.stub.php Add stubs for SAPIs 2020-07-10 14:20:18 +02:00
php_cli_server_arginfo.h Do not generate frameless info items when func info generation is disabled 2024-02-18 11:39:00 +01:00
php_http_parser.c Merge branch 'PHP-7.4' into PHP-8.0 2021-07-29 13:28:52 +02:00
php_http_parser.h Preferably include from build dir (#13516) 2024-06-26 00:26:43 +02:00
ps_title.c sapi/cli: Refactor process title setting code (#17177) 2024-12-16 22:50:06 +00:00
ps_title.h sapi/cli: Refactor process title setting code (#17177) 2024-12-16 22:50:06 +00:00