Bug #47762 [Com]: SoapClient does not fetch WSDL requiring Digest auth
| From: | weekdeepsaghi at gmail dot com | Date: | Tue, 02 May 2023 05:57:30 +0000 |
| Subject: | Bug #47762 [Com]: SoapClient does not fetch WSDL requiring Digest auth | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-244321@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=47762&edit=1
ID: 47762
Comment by: weekdeepsaghi at gmail dot com
Reported by: marques at displague dot com
Summary: SoapClient does not fetch WSDL requiring Digest auth
Status: Open
Type: Bug
Package: SOAP related
Operating System: *
PHP Version: 5.2.9
Block user comment: N
Private report: N
New Comment:
Insider Business Blog are sharing latest news about business, finance, loan, tax, banking, share
market, trading etc. More info to visit our website: (https://insiderbusinessblog.com)github.com
Previous Comments:
------------------------------------------------------------------------
[2009-10-23 13:49:33] marques at displague dot com
The problem expressed here is still present in 5.2.11.
As a user, I've had to implement my own stream_filter for HTTP chunked
data and I've extended SoapClient with a class I call
SoapClientWithDigest that fetches the wsdl using http/1.1 headers,
Digest auth, and the chunk stream filter. It also stores the session
cookie in the properties exported by the soapclient class so that
subsequent __calls to the methods of the soap server can take
advantage of the session cookie acquired fetching the wsdl and skip
further authentication.
A way around this is to store the wsdl file locally (or fetching it
with curl extensions or other external tools).
PHP 5.3.0 has a broken chunk stream filter (can't handle chunks beyond
8k). Because it thought it was handling the situation it removes the
"Transfer-Encoding: chunked" header. This prevents my working filter
from detecting that the data was chunked. There is no way to remove
one of these default stream_filters (stream_filter_remove requires the
resource obtained when the stream_filter was prepended/appended -
This isn't available to me.).
Stream wrapper has a register and unregister function. If
stream_filter (which has a register function) had an unregister
function, I imagine I would be able to use that to unregister the
chunked filter. Point being, I can't work around the problem in PHP
5.3.0.
In PHP 5.3.1, I hope all of these problems are resolved (chunking is),
but I'm not sure about the wsdl fetch behavior - which is the reason
for this bug report.
------------------------------------------------------------------------
[2009-10-23 07:42:23] florin dot daneliuc at iquestint dot com
Is there a plan for fixing this?
------------------------------------------------------------------------
[2009-03-24 14:17:13] marques at displague dot com
Description:
------------
SoapClient does not fetch a WSDL file if Digest auth is required to retrieve the WSDL file. Aside
from Bug #47761, which states that Basic auth for WSDL is broken in 5.2.9, Basic auth has been used
in previous PHP versions.
Digest auth should be attempted when retrieving a WSDL file if the login and password options are
set. Especially when 'authentication' is set to SOAP_AUTHENTICATION_DIGEST.
I can understand if a separate set of options are needed to distinguish between WSDL credentials and
Soap service credentials. In practice, I would imagine most WSDL files will be retrieved from the
same server as the soap service so the extra authentication options may not be necessary.
Another issue is that Digest requires HTTP/1.1 and that isn't fully supported. Bug #47759
blocks HTTP/1.1 usage because "Transfer Encoding: chunked" must be handled properly. Bug
#46539 notes that SoapClient incorrectly uses HTTP/1.1 options over HTTP/1.0.
This posting is related and sums up how some of these problems are connected:
http://marc.info/?l=php-internals&m=123293240706762&w=2
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=47762&edit=1