views:

84

answers:

3

I recently made a change to a working web application with a wcf service in it. After publishing the thing I get error Security settings for this service require 'Anonymous' Authentication but it is not enabled for the IIS application that hosts this service..

I have been searching the net for the past five hours trying to make heads or tails on this

I have anoynous authorization unchecked...

Here is the web service section from my web.config, please help!!!

<bindings>
<wsHttpBinding>
<binding name="WSHttpBinding_IService1" >

  <security mode="TransportWithMessageCredential">
    <transport clientCredentialType="Windows"/>
  </security>

</binding>
</wsHttpBinding>



</bindings>
<client>
<!--http://localhost:2083/Service1.svc--&gt;
 <endpoint address="" binding="wsHttpBinding"
bindingConfiguration="WSHttpBinding_IService1" contract="ServiceReference1.IService1"
 name="WSHttpBinding_IService1">
 <identity>
 <dns value="issupport03" />
 </identity>
 </endpoint>
</client>
 <services>
 <service name="WcfService1.AjaxWcf">
 <endpoint address="" behaviorConfiguration="WcfService1.AjaxWcfAspNetAjaxBehavior"
 binding="webHttpBinding" contract="WcfService1.AjaxWcf" />
 </service>
 </services>
 <behaviors>
<endpointBehaviors>
<behavior name="WcfService1.AjaxWcfAspNetAjaxBehavior">
 <enableWebScript />
</behavior>
 </endpointBehaviors>
<serviceBehaviors>
 <behavior name="WcfService1.AjaxWcfAspNetAjaxBehavior">
   <serviceDebug includeExceptionDetailInFaults="True"/>
 </behavior>
</serviceBehaviors>
</behaviors>
A: 

Check the identity that your application pool is running under. This user may not have access to any resources it could be using.

Russell
A: 

I recommend that you backup your current code, then revert to the previous version from source control. Build and deploy that version, then make sure it works in production.

If that worked, then diff the production version against your backup version. See what changed. Change it back little by little until it works again.

John Saunders
I think this is part of what got me deeper in the mess I made...after about a hour of trying to fix it I published an older version over the top of the current one. It didn't fix the problem, but once I did all of the older "changes" were made, causing it to revert back to previous problems, basically downgrading the app...Thanks, though!
wali
A: 

Basically what I did to fix it was change from wsHttpBinding to webHttpBinding with:

<security mode="TransportCredential">
 <transport clientCredentialType="Windows"/>
</security>

It works now, and since its on an intranet I'm not worried about security issues at this point...however, I really wish I knew why it broke and what I should have done to fix it...

Thanks to all who helped!!!

wali