Christian V. wrote:
Nick Kew wrote:
On Tue, 07 Nov 2006 11:24:05 +0100 Christian V.
[EMAIL PROTECTED] wrote:
Hi ,
i 'm running a third-party web service authentication module that
hangs when the request coming from the client is splitted out in
different chunks. I don't have access to the module and to the
client neither, so I'm thinking to write an input filter that
collects all the chunks and pass'em to the downstream filter or
handler . Is that possible?
It's possible, yes.
Whether it'll fix the problem for you is not certain. I'd suggest
starting with a quick hack (or a dechunking proxy in front of your
server) to test it first, if you really can't get the source.
Maybe the Proxy will fix it but it will not be the solution, so i
think i'm gonna write the module-filter. But i need to know how
Apache handle multi chunk request, as im not able to find this
information. Is request coming entirely to my filter in the form of
bucketbrigades then passed to down-streams module or brigades are
passed down as soon as they come? (I hope i explained it well)
Tnx a lot, Chris.
Let me explain well as im not 100% sure the problem is the 3rd party
module, and other people may had met the same issue:
[ CLIENT ] -- [ APACHE R.PROXY (SSL) + 3rd MODULE ] -- [WEB SERVICE]
The Web Service receives requests from both Java and .net clients.
Our problem is the following.
The .Net clients (we have one in c# and one in VB, both programmed with
visual studio 2005 ) will split the client's XML request in multiple
1024 byte packets. This happens only over HTTPS, and causes problems
with the 3rd party module
To debug this we have programmed an apache module on the reverse proxy
that dumps the stream of data as it receives it from the clients, and
our .Net client, over HTTPS, splits it up in multiple chunks, as seen here:
[Tue Oct 31 15:09:56 2006] [notice] (IN) bucketdumper: mode READBYTES;
blocking; 8192 bytes
[Tue Oct 31 15:09:57 2006] [notice] (IN) - (AFTER bucket_read)
-\tbucketdumper:\tbytes: 1024 - lenght read: 1024 - data: ?xml
version=1.0 encoding=utf-8?soap:Envelope
xmlns:soap=http://schemas.xmlsoap.org/soap/envelope/;
xmlns:soapenc=http://schemas.xmlsoap.org/soap/encoding/;
xmlns:tns=http://www.acme.com.com/wsdl/HelloMoto.wsdl;
xmlns:types=http://www.acme.com.com/wsdl/HelloMoto.wsdl/encodedTypes;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xmlns:xsd=http://www.w3.org/2001/XMLSchema;soap:Body
soap:encodingStyle=http://schemas.xmlsoap.org/soap/encoding/;q1:sayHello
xmlns:q1=urn:examples:HelloMotoTAG1
xsi:type=xsd:stringTES/TAG1TAG2
xsi:type=xsd:stringTES/TAG2TAG3
xsi:type=xsd:stringTES/TAG3TAG4
xsi:type=xsd:stringTES/TAG4TAG5
xsi:type=xsd:stringTES/TAG5TAG6
xsi:type=xsd:stringTES/TAG6TAG7
xsi:type=xsd:stringTES/TAG7TAG8
xsi:type=xsd:stringTES/TAG8TAG9
xsi:type=xsd:stringTES/TAG9TAG10
xsi:type=xsd:stringTES/TAG10TAG11
xsi:type=xsd:stringTES/TAG11TAG12
xsi:type=xsd:stringTEST/TAG12/q1:sayHello/soap:Body/soap:Envelope
-
[Tue Oct 31 15:09:57 2006] [notice] (IN) Complete Bucket :
[Tue Oct 31 15:09:57 2006] [notice] (IN) bucketdumper: mode READBYTES;
blocking; 8192 bytes
[Tue Oct 31 15:09:58 2006] [notice] (IN) - (AFTER bucket_read)
-\tbucketdumper:\tbytes: 1 - lenght read: 1 - data: -
[Tue Oct 31 15:09:58 2006] [notice] (IN) - (AFTER bucket_read)
-\tbucketdumper:\tbytes: 0 - lenght read: 0 - data: -
Note how the XML is 1025 bytes long, and gets send in one 1024 byte
packet first, followed by a second 1 byte packet (that contains just the
final ).
This does not happen over HTTP, where the entire XML arrives in one 1025
byte long data chunk.
Also, our Java clients do not split up the XML when posting in HTTPS,
independently of how long it is. Here is a request made by one of our
java clients:
[Tue Oct 31 15:12:57 2006] [notice] (IN) bucketdumper: mode READBYTES;
blocking; 8192 bytes
[Tue Oct 31 15:12:57 2006] [notice] (IN) - (AFTER bucket_read)
-\tbucketdumper:\tbytes: 4333 - lenght read: 4333 - data: ?xml
version=1.0 encoding=UTF-8?soapenv:Envelope
xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
xmlns:xsd=http://www.w3.org/2001/XMLSchema;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;soapenv:BodyberegnLivorno
xmlns=http://prognosiRiservata.acme.com;startinputns1:channel
xmlns:ns1=http://;LIV/ns1:channelns2:clientId
xmlns:ns2=http://;TEST/ns2:clientIdns3:clientPassword
xsi:nil=true xmlns:ns3=http:///ns4:test
xmlns:ns4=http://;false/ns4:testns5:useCache
mlns:ns36=http://data.prognosiRiservata.acme.com;true/ns36:returnerBeskrivelserns37:returnerThreadSide
xmlns:ns37=http://Livorno.data.prognosiRiservata.acme.com;true/ns37:returnerThreadSidens38:returnerResultaterAvtale
xmlns:ns38=http://Livorno.data.prognosiRiservata.acme.com;true/ns38:returnerResultaterAvtale/prognosiRiservatainput/beregnLivorno/soapenv:Body/soapenv:Envelope
-
[Tue Oct 31 15:12:57 2006] [notice