How did I get this Windows share to prompt for login?

This really piqued my interest. I was able to replicate your findings in my lab with the same pattern of results that you describe. I used Procmon to to try to see what changes are made and almost gave up until I saw the following: That shows lsass.exe (Local Security Authority) writing to the local … Read more

IIS 7.5: How to configure custom Authentication Error page with Windows Authentication. 401 header problems

Try this: change: <error statusCode=”401″ subStatusCode=”2″ prefixLanguageFilePath=”” path=”/not_restricted/401.htm” responseMode=”ExecuteURL” /> to <error statusCode=”401″ subStatusCode=”2″ prefixLanguageFilePath=”” path=”not_restricted\401.htm” responseMode=”File” /> With the response mode ‘File’ IIS just loads the content of that file and displays it, it still sends the 401 status back to the client. I used to use ‘ExecuteURL’ but have learned that File mode … Read more

Connection string using Windows Authentication

Replace the username and password with Integrated Security=SSPI; So the connection string should be <connectionStrings> <add name=”NorthwindContex” connectionString=”data source=localhost; initial catalog=northwind;persist security info=True; Integrated Security=SSPI;” providerName=”System.Data.SqlClient” /> </connectionStrings>

IIS Express Windows Authentication

Visual Studio 2010 SP1 and 2012 added support for IIS Express eliminating the need to edit angle brackets. If you haven’t already, right-click a web-flavored project and select “Use IIS Express…”. Once complete, select the web project and press F4 to focus the Properties panel. Set the “Windows Authentication” property to Enabled, and the “Anonymous … Read more