[php-src] PR #22489: Fix GH-14695: Strictly validate invalid upload_max_filesize and post_max_size values
| From: | LamentXU123 | Date: | Sat, 27 Jun 2026 16:36:04 +0000 |
| Subject: | [php-src] PR #22489: Fix GH-14695: Strictly validate invalid upload_max_filesize and post_max_size values | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-36697@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/22489
Author: LamentXU123
This PR adds strict quantity validation for upload_max_filesize and post_max_size.
For ini settings, Invalid values now emit a warning and keep the existing effective value instead of
being coerced by backwards-compatible parsing. So
upload_max_filesize=1zz is now parsed
as default value 2M instead of 1 with the warning emitted.
And for the request_parse_body() originally we emit warning and parse those malformed
input but now we are throwing ValueErrors to stuff like upload_max_filesize :
""