locked
Web service gets 401.1 unauthorized error on windows server 2012 IIS8 RRS feed

  • Question

  • User-1764133772 posted

    Hello,

    We are upgrading an asmx web service and installing it on windows server 2015.

    The issue is that the web service asmx page can not be hit with the browser on the web server due to a 401.1 unauthorized error.

    We can hit the web service fine from other machines.  We just can't run it in the browser on the web server itself.

    We need this ability as we have diagnostics that we run on the web service to verify it is functional.

    Background info:

    - When prompted to login, we use credentials that are already working elsewhere. 

    - Same credentials work from a client machine, just not on server in the browser.

    - Upgraded a classic asmx web service to .net 4.5 and Visual Studio 2013.

    - THe web service has been installed on a new windows 2012 web server. 

    - The application and asp.net roles have been activated.

    - The web service is running under an app pool using windows authentication and running under a custom service account.

    - aspnet_regiis has been executed for the app pool account on both framework and framework64

    - Appropriate permissions have been applied to the web site folder.

    - This is all working on other older web servers and the configuration is documented which we have followed. 

    - Checked event viewer and IIS logs but it doesn't log anything....must not be getting far enough?

    - Windows server 2012, Asp.Net 4.5, .Net 4.5, Visual Studio 2013, IIS 8.5,

    We are out of ideas at this point and have exhausted the blogs. 

    Another developer has hit the same thing with another asp.net web site what we are upgrading.

    If anybody has ideas, we are all ears.  These generic 404 and 401 errors are so hard to debug...suggestions there as well would be appreciated.

    Thanks!

    Dan

    Wednesday, May 6, 2015 6:16 PM

Answers

  • User-1764133772 posted

    Found the fix.  Had to modify the registry per this article.  Originally it seemed this was an old article but it applied even on Win 2012.

    https://support.microsoft.com/en-us/kb/896861

    In that article, these steps specifically fixed it.

    • In Registry Editor, locate and then click the following registry key:
      HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\MSV1_0
    • Right-click MSV1_0, point to New, and then click Multi-String Value.
    • Type BackConnectionHostNames, and then press ENTER.
    • Right-click BackConnectionHostNames, and then click Modify.
    • In the Value data box, type the host name or the host names for the sites that are on the local  computer, and then click OK.
    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, May 7, 2015 6:30 PM