Can't get netTcpBinding requests to show up in Fiddler

天大地大妈咪最大 提交于 2019-12-21 07:54:36

问题


I have a WCF service that has two endpoints. One with basicHttpBinding and one with netTcpBinding. Here is my config...

<services>
      <service name="SomeService.Service">
        <endpoint address="" binding="basicHttpBinding" bindingConfiguration=""
          name="EndPointHttp" contract="SomeService.IService" />
        <endpoint address="" binding="netTcpBinding" bindingConfiguration=""
          name="EndPointTcp" contract="SomeService.IService" />
        </service>
</services>

However, when I consume the service I am trying to compare the difference between to two requests. So I am running fiddler to do this. I can see the basicHttpBinding requests in Fiddler but I can't get the net.tcp:// requests to show up. What can I do to see this traffic?


回答1:


Fiddler is a HTTP proxy, so it will only capture requests which use HTTP protocol - it will not capture requests made using socket directly. You can use the Network Monitor or some other low-level capture tool to do that, but the interface is not as nice as the one you may be used to with Fiddler.

Also, as pointed out in another answer by Ladislav Mrnka, you'll be looking at the binary bytes for the .NET Message Framing and the binary XML encoding, so unless you're familiar with them most of the capture will look like gibberish.




回答2:


Fiddler is HTTP sniffer not TCP sniffer. You can see only HTTP and HTTPS communication in fiddler. If you want to see messages passed over TCP you must use another tool working on lower level. For example WireShark but be prepared that you will see only some binary data.




回答3:


Fiddler is an HTTP debugger. If you're not using HTTP, such as with a netTcpBinding, you won't be able to capture traffic with it. You could try Wireshark or something similar.




回答4:


If you are interested into how the actual messages look like then try using Service Trace.

https://msdn.microsoft.com/en-us/library/ms732023%28v=vs.110%29.aspx?f=255&MSPPError=-2147217396



来源:https://stackoverflow.com/questions/6336626/cant-get-nettcpbinding-requests-to-show-up-in-fiddler

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!