[php-src] PR #25026: Fix GH-25019: Uri\Rfc3986\Uri rejects a port with leading zeros as out of range
| From: | lazerg | Date: | Thu, 29 Oct 2026 01:24:37 +0000 |
| Subject: | [php-src] PR #25026: Fix GH-25019: Uri\Rfc3986\Uri rejects a port with leading zeros as out of range | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-40044@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/25026
Author: lazerg
port_str_to_zend_long_checked() rejected any port longer than
MAX_LENGTH_OF_LONG digits before looking at its value, so http://example.com:000000000000000000008080/
threw "The port is out of range" even though the port is 8080. RFC 3986 allows any number
of digits, and Uri\WhatWg\Url` already accepts it. The leading zeros are now skipped before
the length check.
Fixes #25019