I am having a strange issue with IIS where I suddenly receive HTTP 500 errors after a few seconds or minutes when navigating around in my website. After a while I found out that I had anonymous authentication enabled in the IIS settings and this seems to have caused the problem because the site needs Windows authentication in order to work. While both anyonymous and Windows authentication were enabled, it seems to just suddenly switch between those methods so sometimes the IIS would receive requests with and sometimes without the user being logged in the IIS logfiles. How does it determine wether or not anonymous or Windows authentication should be used and why does it seem to randomly switch between them if both methods are enabled?
Source: Windows Questions