IIS Express is automatically disabling anonymous authentication for my project, why?

后端 未结 3 1394
迷失自我
迷失自我 2020-12-24 11:28

When I switch my ASP.NET MVC project from Cassini web server to IIS Express, this is added to my applicationhost.config file:



        
3条回答
  •  南方客
    南方客 (楼主)
    2020-12-24 11:56

    Sometimes ago, I faced the same difficulty, but it was little different from what I see over here. In my laptop I have both VS 08 and VS 13, and SQL Server 2008 R2 and 11G XE. For websites connecting to R2 has never been a problem, but when I was trying to build a website using oracle membership with asp.net, I found that pages open but pages under folder with roles are not opening and giving me the access denied error. Though the folder had a proper web.config inside and the user created with the same role, still it was throwing up the same error. Finally I realized I need the authentication mechanism going and so I added the following code in the system.web of web.config:

    
    
    
    
    
    
    
    
    

    And it did work, now my authenticated users can loginto designated folders! I hope this might help someone who faced issues similar to me.

提交回复
热议问题