WCF Metadata, Proxies and real Proxies

I was just about to generate a client (proxy) for a WCF service on a computer (in a domain) on customer site when svcutil.exe returned the following:

Microsoft (R) Service Model Metadata Tool
[Microsoft (R) Windows (R) Communication Foundation, Version 3.0.4506.30]
Copyright (c) Microsoft Corporation. All rights reserved.

Error: Cannot obtain Metadata from

If this is a Windows (R) Communication Foundation service to which you have access, please check that you have enabled metadata publishing at the specified address. For help enabling metadata publishing, please refer to the MSDN documentation at http://go.microsoft.com/fwlink/?LinkId=65455.

WS-Metadata Exchange Error

Metadata contains a reference that cannot be resolved: ''.
<?xml version="1.0" encoding="utf-16"?><Fault xmlns="http://www.w3.org/2003/05/soap-envelope"><Code><Value> Sender </Value><Subcode><Value xmlns:a="http://schemas.xmlsoap.org/ws/2005/02/sc"> a:BadContextToken </Value></Subcode></Code><Reason><Text xml:lang="de-DE">The message could not be processed. This is most likely because the action 'http://schemas.xmlsoap.org/ws/2004/09/transfer/Get' is incorrect or because the message contains an invalid or expired security context token or because there is a mismatch between bindings. The security context token would be invalid if the service aborted the channel due to inactivity. To prevent the service from aborting idle sessions prematurely increase the Receive timeout on the service endpoint's binding.</Text></Reason></Fault>


The document was understood, but it could not be processed.
- The WSDL document contains links that could not be resolved.
- There was an error downloading 'http://dpc00000198.clients.eden/CallahanWeb/service.svc?wsdl=wsdl0'.
- The request failed with HTTP status 407: Proxy Authentication Required ( The ISA Server requires authorization to fulfill the request. Access to the Web Proxy service is denied. ).

If you would like more help, type "svcutil /?"

Seems that svcutil does not support http proxies that require authentication... After i disabled the proxy in IE's settings it worked ;-)

Comments (2) -

  • Hi Daniel,

    I got exactly the same error, but instead of a local proxy I am using the ISA Server 2006 as a (reverse) proxy server. It might be understandable that I didn't want to disable it Smile

    This error isn't really often found in the web. I think it is a result of the proxy behaviour, because the ISA doesn't route the original request to my IIS Server. Or something ugly happens with the secur
  • Hi! I could have sworn I've been to this blog before but after reading through
    some of the post I realized it's new to me. Anyhow, I'm definitely happy I found it and
    I'll be book-marking and checking back frequently!

Add comment