I am running an ASP.NET MVC 5 application on a Windows 2019 server with IIS 10. Now I want to set the IIS to pop up a window asking for a specific user with password before loading the web application in the browser. It is important that the prompt appears before the application accepts the client's requests. So actually before the application is started on the web server.
I can remember that something like this used to be possible with a .htaccess file. Is it possible to implement this in IIS 10 with the Web.config file somehow? In my Web.config I have already entered a http to https rule. So it would not be a security leak, because the connection is encrypted. Is it possible to configure IIS to ask for a specific password and username before starting the web application?
Thanks.
As can also be seen in the comments under the question, there is no IIS build-in solution for this requirement. The integration of third-party software for this requirement has not been considered.