Skip to content

Fix user.ini handling when the script directory prefixes doc_root - #23414

Open
iliaal wants to merge 1 commit into
php:PHP-8.4from
iliaal:fix/fpm-user-ini-prefix-scan
Open

Fix user.ini handling when the script directory prefixes doc_root#23414
iliaal wants to merge 1 commit into
php:PHP-8.4from
iliaal:fix/fpm-user-ini-prefix-scan

Conversation

@iliaal

@iliaal iliaal commented Aug 22, 2026

Copy link
Copy Markdown
Contributor

php_cgi_ini_activate_user_config() swapped the scan base when the script directory was shorter than DOCUMENT_ROOT, so a prefixing script dir never loaded .user.ini. Scan the tree only when path descends from doc_root. Same change in sapi/cgi and sapi/fpm.

php_cgi_ini_activate_user_config() swapped the scan base when path was
shorter than DOCUMENT_ROOT, so a script dir that prefixes doc_root
never parsed .user.ini. Scan the tree only when path descends from
doc_root; otherwise parse the current directory. Same change in
sapi/cgi and sapi/fpm.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant