Take the 2-minute tour ×

I've written my first WCF web service, which works great on my own local test webserver, however I'm getting an error when I deploy it to IIS.

Our IIS server uses integrated auth, and does not allow anonymous access. From what I've read, I need to set the security mode on the binding to TransportCredentialOnly. The entire section in web.config is:

        <behavior name="VZW.TrainingPortfolioManager.Website.TPMAspNetAjaxBehavior">
          <enableWebScript />
      <service name="VZW.TrainingPortfolioManager.Website.TPM">
        <endpoint address="" behaviorConfiguration="VZW.TrainingPortfolioManager.Website.TPMAspNetAjaxBehavior"
          binding="webHttpBinding" contract="VZW.TrainingPortfolioManager.Website.TPM" />
          <security mode="TransportCredentialOnly">
            <transport clientCredentialType="Windows" />

However, when I load the web service in the browser, I get the error message:


Is there anything else I need to change or configure to get this working?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

Figured it out. The binding attribute on the endpoint has to match the node in the <bindings> collection. The following will work:

      <security mode="TransportCredentialOnly">
        <transport clientCredentialType="Windows" />
share|improve this answer

Your Answer


