How do I see the raw HTTP request that the HttpWebRequest class sends?

后端 未结 8 696
伪装坚强ぢ
伪装坚强ぢ 2020-11-29 01:19

I know you are all going to answer \"use a debugging proxy server like Fiddler\" but it\'s not that simple.

Here\'s my situation: I have some code that runs on a ser

8条回答
  •  孤城傲影
    2020-11-29 01:35

    You say that you think .NET is lying to you, and the specific example you give is that the header Content-Length is missing from the HTTP response.

    But the header Content-Length is not required from an HTTP response. In fact, if the body of the response is in any dynamic, and if its length is not known in advance, then it is highly likely that the Content-Length header will be omitted!

提交回复
热议问题