ZF-11188: Ipv6 host


Actualy it's not possible to validate an url contains an ipv6 host with Zend_Uri, like

This affect many others componements, like Zend_Http_Client_Adapter, that could run fine if validation passed.


Code to reproduce:

require_once 'Zend/Uri.php';

var_dump(Zend_Uri::check('http://[::1]/foo.html', 'Uri'));

I would propose to use Zend_Validate_Hostname for the hostname part, I think running the zend_validate_hostname unittests on zend_uri_http would reveal more flaws.

Zend_Validate_Hostname does not detect IPv6 addresses with hex decimal f in them before r23900

Reproducing test case plus fix. Applying patch had no visible consequence w.r.t execution of test suite.

NOTE: Your ZF repo must be at r23900 or higher due to dependence on fix for ZF-11334

Fixed in trunk r23901

Fixed in release branch 1.11 at r23970