Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Microsoft Edge not loading CSS files with activated Windows Authentication

I'm creating an intranet website and using the ASP.NET MVC template with Windows Authentication. After compiling and logging in with my credentials, the CSS hasn't loaded.

I'm using Windows 10, Visual Studio 2015. Everything works fine in Internet Explorer 11. I've not written one line of code in this brand new project but Edge doesn't load the CSS. Moreover, it seems like the problem only appears with activated windows authentication as a login method. I've created some new projects with no login method and with the custom user account method and it all works fine in Edge. Why is it not working with windows authentication in Edge?

So basically what happens is I see the raw site without the styles. I opened the developer tools and saw that the bootstrap.css and the Site.css file weren't loaded. I tried to open the path in Edge and I got a 500.0 Internal Server Error. Again Internet Explorer does his job.

See this picture to see the website and debugger Home page with debugger

Here is the internal server error: Internal Server Error 500.0

Sorry for the German version.

enter image description here

enter image description here

like image 760
MarvinS Avatar asked May 16 '26 21:05

MarvinS


1 Answers

I googled for hours and tried so many things without success.
Finally I found a working solution for me and so I thought I'd share it.

I'm using Windows 10, Visual Studio 2015.

In the project configuration file [SolutionFolder].vs\config\applicationhost.config
I changed from this:

<windowsAuthentication enabled="false">
    <providers>
        <add value="Negotiate" />
        <add value="NTLM" />            
    </providers>
</windowsAuthentication>

to this (changed order and enabled windows authentication):

<windowsAuthentication enabled="true">
    <providers>
        <add value="NTLM" />
        <add value="Negotiate" />        
    </providers>
</windowsAuthentication>

Maybe it helps someone else.

like image 124
Lars Avatar answered May 18 '26 11:05

Lars