Reputation: 8122
Exception:
You do not have permission to view this directory or page because of the access control list (ACL) configuration or encryption settings for this resource on the Web server.
I am learning WCF for the first time and I am trying to host it on IIS. I am a complete beginner so I might have done any silly mistakes.
Running WCF from Visual Studio:
I am able to open the WSDL document and able to browse when I run locally.
Now when I add this as a website in IIS Manager I get the exception mentioned above.
Config File:
<?xml version="1.0"?>
<configuration>
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior name="mexBehavior">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true"/>
</behavior>
</serviceBehaviors>
</behaviors>
<services>
<service behaviorConfiguration="mexBehavior" name="WSHttpService.WSHttpService">
<endpoint address="WSHttpService" binding="wsHttpBinding" contract="WSHttpService.IWSHttpService" />
<host>
<baseAddresses>
<add baseAddress="http://localhost:8080" />
</baseAddresses>
</host>
</service>
</services>
</system.serviceModel>
<system.web>
<compilation debug="true"/>
</system.web>
</configuration>
Microsoft is known for displaying errors which are totally misguiding. Please some one help me as I might be doing some other silly mistake.
Solution I looked into SO Link
Upvotes: 0
Views: 760
Reputation: 8122
IUSR and IIS_IUSRS
and give all the permissionsHTTP Error 404.3 - Not Found
The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map. Detailed Error Information
Solution:
Go to Control Panel -> Windows Feature turn on/off and there apply below config.
Upvotes: 1
Reputation: 21
A few things to check. Make sure your IIS user account has permissions to view the folder where your code lives.
I would change the bindings to basic http until you can get IIS responding as you would expect.
Also, if your hosting in iis vs an iisExpress host, the "add baseAddress="http://localhost:8080" " will have an effect on how IIS tries to service the endpoint.
Upvotes: 0