#21739 [Opn->Csd]: remote port number not sent in host header

From: Date: Tue, 29 Apr 2003 14:12:24 +0000
Subject: #21739 [Opn->Csd]: remote port number not sent in host header
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-15712@lists.php.net to get a copy of this message
ID: 21739 Updated by: jellybob@php.net Reported By: warren at konkel dot net -Status: Open +Status: Closed Bug Type: PEAR related Operating System: linux PHP Version: 4.3.0 New Comment: This bug has been fixed in CVS. In case this was a PHP problem, snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. In case this was a documentation problem, the fix will show up soon at http://www.php.net/manual/. In case this was a PHP.net website problem, the change will show up on the PHP.net site and on the mirror sites in short time. Thank you for the report, and for helping us make PHP better. Previous Comments: ------------------------------------------------------------------------ [2003-01-18 21:15:52] warren at konkel dot net I noticed that when giving WSDL the URL of a dynamically generated WSDL (such as Java's tomcat web services server), the server was returning a port number of 80 rather than 8080... I looked into and found out that the request sent to the server doesn't include the remote port... this fixed it: on line 191 of HTTP/Request.php, currently there is: ------------------------------------------------------ if (HTTP_REQUEST_HTTP_VER_1_1 == $this->_http) { $this->addHeader('Host', $this->_url->host); } ------------------------------------------------------ it SHOULD be: ------------------------------------------------------ if (HTTP_REQUEST_HTTP_VER_1_1 == $this->_http) { if ($this->_url->port) { $this->addHeader('Host', $this->_url->host . ":" . $this->_url->port); } else { $this->addHeader('Host', $this->_url->host); } } ------------------------------------------------------ -Warren ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=21739&edit=1

« previous php.pear.dev (#15712) next »