ZF-4835: Zend_Soap_Autodiscover should use REQUEST_URI instead of SCRIPT_NAME

Issue Type: Bug Created: 2008-11-06T11:12:01.000+0000 Last Updated: 2008-11-13T14:10:13.000+0000 Status: Resolved Fix version(s): - 1.7.0 (17/Nov/08)

Reporter: Thomas Gelf (tgelf) Assignee: Benjamin Eberlei (beberlei) Tags: - Zend_Soap_Server

Related issues: Attachments: - Zend_Soap_AutoDiscover.REQUEST_URI.patch


Zend_Soap_Autodiscover tries to automatically discover the correct script URI. While when configuring rewrite-rules in your Apache config there is no difference between REQUEST_URI and SCRIPT_NAME in PHP, this changes when you are going to use .htaccess files. Here a short overview of related $_SERVER variables in different environments when rewrite is in use (in this example /index/test -> /index.php):

Rewrite rules in Apache conf:

<pre class="literal">
[REQUEST_URI] => /index/test
[SCRIPT_NAME] => /index/test
[PHP_SELF] => /index/test

Rewrite rules in .htaccess file:

<pre class="literal">
[REQUEST_URI] => /index/test
[SCRIPT_NAME] => /index.php
[PHP_SELF] => /index.php/test

In my opinion the only correct URI for Autodiscover is REQUEST_URI.

Best regards, Thomas Gelf


Posted by Thomas Gelf (tgelf) on 2008-11-06T11:12:53.000+0000

Attaching patch changing SCRIPT_NAME to REQUEST_URI

Posted by Benjamin Eberlei (beberlei) on 2008-11-07T00:22:44.000+0000

AutoDiscover now uses REQUEST_URI without the parameters after the ?. This way you can still provide the WSDL via Autodiscovering on script.php?wsdl and the uri is autodiscovered to be script.php (where the SOAP Server resides).

Additionally to this behaviour AutoDiscover did not detect automatically the path for non apache webservers. This was fixed too.

Posted by Wil Sinclair (wil) on 2008-11-13T14:10:13.000+0000

Changing issues in preparation for the 1.7.0 release.

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.