2017-03-16 1 views
0

WCF를 사용하여 간단한 클라이언트 응용 프로그램 (콘솔 응용 프로그램)과 서버 응용 프로그램 (WCF 라이브러리 프로젝트)이 있습니다. Fiddler에서 WCF 메시지가 어떻게 보이는지보고 싶습니다.Fiddler에서 로컬 WCF 요청을 수신하도록 클라이언트를 구성하는 방법은 무엇입니까?

나는 클라이언트의 app.config에 코드를 다음 추가 된 :

<configuration>  
    <system.net> 
    <defaultProxy> 
     <proxy bypassonlocal="False" usesystemdefault="True" proxyaddress="http://127.0.0.1:8888" />  
    </defaultProxy> 
    </system.net> 

내 피들러는 URL에 단어 "vshub"를 가진 제외한 브라우저의 모든 연결을 보여 주지만, 표시 WCF 클라이언트/서버 응용 프로그램 사이에 연결이 없습니다 . 그것을 구성하는 방법?

갱신 1 :

내 WCF 서비스 라이브러리 (서버 응용 프로그램)은 다음과 같은 방법으로 구성됩니다

<system.serviceModel> 
    <services> 
     <service name="WcfServer.Service1"> 
     <host> 
      <baseAddresses> 
      <add baseAddress = "http://localhost:8733/Design_Time_Addresses/WcfServer/Service1/" /> 
      </baseAddresses> 
     </host> 
     <!-- Service Endpoints --> 
     <!-- Unless fully qualified, address is relative to base address supplied above --> 
     <endpoint address="" binding="basicHttpBinding" contract="WcfServer.IService1"> 
      <!-- 
       Upon deployment, the following identity element should be removed or replaced to reflect the 
       identity under which the deployed service runs. If removed, WCF will infer an appropriate identity 
       automatically. 
      --> 
      <identity> 
      <dns value="localhost"/> 
      </identity> 
     </endpoint> 
     <!-- Metadata Endpoints --> 
     <!-- The Metadata Exchange endpoint is used by the service to describe itself to clients. --> 
     <!-- This endpoint does not use a secure binding and should be secured or removed before deployment --> 
     <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/> 
     </service> 
    </services> 
    <behaviors> 
     <serviceBehaviors> 
     <behavior> 
      <!-- To avoid disclosing metadata information, 
      set the values below to false before deployment --> 
      <serviceMetadata httpGetEnabled="True" httpsGetEnabled="True"/> 
      <!-- To receive exception details in faults for debugging purposes, 
      set the value below to true. Set to false before deployment 
      to avoid disclosing exception information --> 
      <serviceDebug includeExceptionDetailInFaults="False" /> 
     </behavior> 
     </serviceBehaviors> 
    </behaviors> 
    </system.serviceModel> 

답변

0

현지 요청은 피들러에 의해 사로 잡았되지 않습니다. 피들러는 실제로 전선을 통과하는 요청 만 잡습니다. 로컬 요청은 Windows에서 바로 처리됩니다.

대체 목록과 함께 an old post이 있는데, 실제로 그 목록이 실제로 어떻게되는지는 알지 못합니다.

0

클라이언트 구성에서 아무 작업도 수행하지 않고 프록시 설정을 제거 할 수 있습니다. Fiddler는 "localhost"를 사용하지 않고 "MyMachineName"으로 바꾸면 작동합니다.

+0

업데이트 방법은 무엇입니까? –

+0

내가 아는 한 중요하지 않습니다. OS는 컴퓨터 이름을 localhost에 매핑 할만큼 똑똑합니다. –

+0

서버가 localhost에서 수신 대기 할 수 있지만 클라이언트 끝점을 와 같은 machinename으로 변경하면 이것은 피들러 용입니다 ... 시스템 용이 아닙니다. – GCamel

관련 문제