Help: How to enable Windows Authentication on ASP.NET Development Server?

前端 未结 4 724
梦如初夏
梦如初夏 2020-12-06 11:04

I hope any of you guys knows how to fix this issue we are having.

We are trying to host a WCF service via the web. We set the web.config to have the service require

相关标签:
4条回答
  • 2020-12-06 11:46

    The solution to my authorization issue was to go into the F4 project properties and set the following:

    Anonymous Authentication: Disabled
    
    Windows Authentication: Enabled
    

    Apparently these properties update the IIS applicationHost.config directly.

    http://provenstyle.com/blog/2015/10/02/Visual-Studio-2015-Windows-Authentication-And-IIS-Express/

    0 讨论(0)
  • 2020-12-06 11:49

    In order to configure IIS Express security settings:

    1. look for the IIS express symbol in the taskbar (system tray).
    2. Right click and select "All Applications".
    3. Click on the name of the site you want to change (although I believe the change is site wide)
    4. Click on the path in the config section below (it will open the applicationhost.config file)
    5. Search for the authentication section and make your changes

    Example changes can be found here:

    http://toadcode.blogspot.ca/2011/08/security-config-in-iis-express.html

    0 讨论(0)
  • 2020-12-06 11:49

    ASP.Net Development Server is very limited. It only serves requests originating from the same machine that it is running on, and it will not serve files that are outside of its application scope. It is based on the Cassini server. Cassini does not support WCF web services. Documentation for ASP.Net Development Server says that it does support NTLM. If you are just browsing to a page from the local machine it should work fine unless the page is referencing an unavailable resource.

    check out http://msdn.microsoft.com/en-us/library/58wxa9w5.aspx for more info.

    0 讨论(0)
  • 2020-12-06 11:51

    I would install and configure IIS on your local dev machine and use that in preference to using the inbuilt webserver. To use local IIS to debug select "User Local IIS web server" on the web tab of the project properties. Using IIS rather than the inbuilt webserver also means that you can configure your app in exactly the same way as it will be configured on the production server and this will reduce the no of potential surprises when you move to the production environment.

    0 讨论(0)
提交回复
热议问题