c# - iis basic auth doesn't work with my asp.net app -


my need simple, have asp.net mvc 5 web app , want show app customer. want put website on iis , protect basic auth access.

the problem : empty folder works when deploy app got : the page isn't redirecting properly

with link : http://xx.xxx.xxx.xxx:xxxx/account/login?returnurl=%2faccount%2flogin%3freturnurl%3d%252faccount%252flogin%253freturnurl%253d%25....

here web.config :

<?xml version="1.0" encoding="utf-8"?> <configuration>   <appsettings>     <add key="webpages:version" value="3.0.0.0" />     <add key="webpages:enabled" value="false" />     <add key="clientvalidationenabled" value="true" />     <add key="unobtrusivejavascriptenabled" value="true" />   </appsettings>   <system.web>     <authentication mode="none" />     <compilation debug="true" targetframework="4.5" />     <httpruntime targetframework="4.5" />   </system.web>   <system.webserver>     <modules>       <remove name="formsauthentication" />     </modules>   </system.webserver> </configuration> 

my config auth in iis : - anonymous auth disabled - basic auth enabled

but works without app think

thanks !

ok sure problem was'nt code was...

in file startup.cs comment default code :

public partial class startup {     public void configuration(iappbuilder app)     {         //configureauth(app);     } } 

and works.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -