Bug #74282 [Opn->Dup]: parse_url returns wrong result
| From: | requinix@php.net | Date: | Tue, 21 Mar 2017 11:43:40 +0000 |
| Subject: | Bug #74282 [Opn->Dup]: parse_url returns wrong result | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-207975@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=74282&edit=1
ID: 74282
Updated by: requinix@php.net
Reported by: alex at 2sun dot su
Summary: parse_url returns wrong result
-Status: Open
+Status: Duplicate
Type: Bug
Package: URL related
PHP Version: 7.1.3
Block user comment: N
Private report: N
Previous Comments:
------------------------------------------------------------------------
[2017-03-21 11:42:56] alex at 2sun dot su
Description:
------------
URL like
scheme://example_login:#Password?@ZZZ@127.0.0.1/some_path
parse_url returns wrong result in PHP 7.1.3, 7.0.14, 5.6.29 (I have them available)
But all works as expected in PHP 7.0.5, 5.6.20
Test script:
---------------
var_dump( parse_url("scheme://example_login:#Password?@ZZZ@127.0.0.1/some_path") );
Expected result:
----------------
array(5) {
["scheme"]=>
string(6) "scheme"
["host"]=>
string(9) "127.0.0.1"
["user"]=>
string(13) "example_login"
["pass"]=>
string(14) "#Password?@ZZZ"
["path"]=>
string(10) "/some_path"
}
Actual result:
--------------
array(3) {
["scheme"]=>
string(6) "scheme"
["host"]=>
string(13) "example_login"
["fragment"]=>
string(33) "Password?@ZZZ@127.0.0.1/some_path"
}
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=74282&edit=1