× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi all,

Have an interesting one that is stumping me.

I am trying to get a simple C#.Net application to do an HTTP POST to an
Apache instance on an i5, but when I read from standard input in my RPG
there is no data. We know the RPG program is being invoked because we
started a service job and set a breakpoint, it's just the data that isn't
making it there.

Let me lay out a couple facts:

1) dotNet_PC1 does HTTP POST to i5_V5R4 (intranet) and the post content is
blank when I try to read it with qtmhrdstin.
2) dotNet_PC1 does HTTP POST to i5_V5R3 (internet) and the post content
comes through fine.
3) java_PC1 does HTTP POST to i5_V5R4 (intranet) and the post content comes
through just fine.

Basically we have a Windows server with Biztalk on it and the dotNet code
can't post content to the i5 with V5R4 which is on the same LAN, but a Java
app on the same Windows Biztalk server _can_ send the post through
successfully. So then we thought we would try to see if a different i5
(which is on V5R3) could receive the post content from the Windows Biztalk
server and it was _successful_! Both the V5R4 and V5R3 machines have the
same Apache setup except url and library mappings.

So from there we downloaded WireShark and were peeking at packets going
across the wire. The dotNet app is definitely sending the post content out,
but for some reason it isn't making it to the i5_V5R4 machine. Note that
when we execute the dotNet vs. Java that the communication does look
slightly different.

I am curious to know if it is the "Expect: 100-Continue" in the .NET one
that is causing the problem? In the .NET one Apache DOES respond with an
"HTTP/1.1 100", and _then_ the dotNET sends the POST content. In my mind I
shouldn't have to worry about this as Apache should be taking care of the
communication and deliver the POST content as soon as I request it via
qtmhrdstin.

I read about some fixes IBM had to do to Apache because of scripting attacks
with "Expect:" headers, but I don't believe that would apply in this case.
Here is what I am talking about:
http://www-1.ibm.com/support/docview.wss?uid=swg1PK24631

Anybody have ideas?

Java Wireshark trace of first communication with Apache:

0000 00 11 25 39 1a 84 00 03 ff ec e3 93 08 00 45 00 ..%9..........E.
0010 01 2b f7 cc 40 00 80 06 a4 49 ac 10 03 a4 ac 10 .+..@....I......
0020 01 f2 10 0a 1f f5 99 51 4d e2 64 a3 52 0c 50 18 .......QM.d.R.P.
0030 ff ff e0 15 00 00 50 4f 53 54 20 2f 41 49 54 52 ......POST /AITR
0040 58 53 2f 63 61 6c 63 70 72 63 20 48 54 54 50 2f XS/calcprc HTTP/
0050 31 2e 31 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 1.1..Content-Typ
0060 65 3a 20 74 65 78 74 2f 78 6d 6c 0d 0a 43 61 63 e: text/xml..Cac
0070 68 65 2d 43 6f 6e 74 72 6f 6c 3a 20 6e 6f 2d 63 he-Control: no-c
0080 61 63 68 65 0d 0a 50 72 61 67 6d 61 3a 20 6e 6f ache..Pragma: no
0090 2d 63 61 63 68 65 0d 0a 55 73 65 72 2d 41 67 65 -cache..User-Age
00a0 6e 74 3a 20 4a 61 76 61 2f 31 2e 35 2e 30 5f 30 nt: Java/1.5.0_0
00b0 38 0d 0a 48 6f 73 74 3a 20 31 37 32 2e 31 36 2e 8..Host: 999.99.
00c0 31 2e 32 34 32 3a 38 31 38 31 0d 0a 41 63 63 65 9.999:8181..Acce
00d0 70 74 3a 20 74 65 78 74 2f 68 74 6d 6c 2c 20 69 pt: text/html, i
00e0 6d 61 67 65 2f 67 69 66 2c 20 69 6d 61 67 65 2f mage/gif, image/
00f0 6a 70 65 67 2c 20 2a 3b 20 71 3d 2e 32 2c 20 2a jpeg, *; q=.2, *
0100 2f 2a 3b 20 71 3d 2e 32 0d 0a 43 6f 6e 6e 65 63 /*; q=.2..Connec
0110 74 69 6f 6e 3a 20 6b 65 65 70 2d 61 6c 69 76 65 tion: keep-alive
0120 0d 0a 43 6f 6e 74 65 6e 74 2d 4c 65 6e 67 74 68 ..Content-Length
0130 3a 20 33 30 34 0d 0a 0d 0a : 304....

.NET Wireshark trace of first communication with Apache:

0000 00 11 25 39 1a 84 00 03 ff ec e3 93 08 00 45 00 ..%9..........E.
0010 01 cf 31 d7 40 00 80 06 69 9b ac 10 03 a4 ac 10 ..1.@...i.......
0020 01 f2 10 46 1f f5 78 38 77 07 65 43 1e 34 50 18 ...F..x8w.eC.4P.
0030 ff ff 34 8f 00 00 50 4f 53 54 20 2f 61 69 74 72 ..4...POST /aitr
0040 78 73 2f 63 61 6c 63 70 72 63 20 48 54 54 50 2f xs/calcprc HTTP/
0050 31 2e 31 0d 0a 55 73 65 72 2d 41 67 65 6e 74 3a 1.1..User-Agent:
0060 20 4d 6f 7a 69 6c 6c 61 2f 34 2e 30 20 28 63 6f Mozilla/4.0 (co
0070 6d 70 61 74 69 62 6c 65 3b 20 4d 53 49 45 20 36 mpatible; MSIE 6
0080 2e 30 3b 20 4d 53 20 57 65 62 20 53 65 72 76 69 .0; MS Web Servi
0090 63 65 73 20 43 6c 69 65 6e 74 20 50 72 6f 74 6f ces Client Proto
00a0 63 6f 6c 20 32 2e 30 2e 35 30 37 32 37 2e 38 33 col 2.0.50727.83
00b0 32 29 0d 0a 56 73 44 65 62 75 67 67 65 72 43 61 2)..VsDebuggerCa
00c0 75 73 61 6c 69 74 79 44 61 74 61 3a 20 75 49 44 usalityData: uID
00d0 50 6f 2b 56 47 57 57 33 36 38 55 42 46 76 68 41 Po+VGWW368UBFvhA
00e0 6c 76 63 67 6d 51 62 77 41 41 41 41 41 36 42 31 lvcgmQbwAAAAA6B1
00f0 65 64 76 55 6f 44 30 47 6b 54 4c 68 70 6b 72 49 edvUoD0GkTLhpkrI
0100 37 62 6b 35 4d 77 54 68 6b 69 2f 42 42 75 69 34 7bk5MwThki/BBui4
0110 4c 72 68 68 75 54 32 38 41 43 41 41 41 0d 0a 43 LrhhuT28ACAAA..C
0120 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 74 65 78 ontent-Type: tex
0130 74 2f 78 6d 6c 3b 20 63 68 61 72 73 65 74 3d 75 t/xml; charset=u
0140 74 66 2d 38 0d 0a 53 4f 41 50 41 63 74 69 6f 6e tf-8..SOAPAction
0150 3a 20 22 68 74 74 70 3a 2f 2f 41 42 43 43 6f 6d : "http://ABCCom
0160 70 61 6e 79 2e 63 6f 6d 2f 4f 72 64 65 72 53 65 pany.com/OrderSe
0170 72 76 69 63 65 73 2f 4e 65 77 4f 70 65 72 61 74 rvices/NewOperat
0180 69 6f 6e 22 0d 0a 48 6f 73 74 3a 20 61 73 37 32 ion"..Host: zz99
0190 30 3a 38 31 38 31 0d 0a 43 6f 6e 74 65 6e 74 2d 0:8181..Content-
01a0 4c 65 6e 67 74 68 3a 20 33 38 37 0d 0a 45 78 70 Length: 387..Exp
01b0 65 63 74 3a 20 31 30 30 2d 63 6f 6e 74 69 6e 75 ect: 100-continu
01c0 65 0d 0a 43 6f 6e 6e 65 63 74 69 6f 6e 3a 20 4b e..Connection: K
01d0 65 65 70 2d 41 6c 69 76 65 0d 0a 0d 0a eep-Alive....




Aaron Bartell
http://mowyourlawn.com


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.