Reputation: 149
I have deployed web application in IIS. Now I want to block a specific page from specific users. Is there any way to do this form IIS without using web.config file?
Upvotes: 0
Views: 473
Reputation: 3494
If you wanna block user for specific page, Then you could use authorization rule with location attribute.
<location path="index.aspx">
<system.webServer>
<security>
<authorization>
<add accessType="Deny" roles="jokies" />
</authorization>
</security>
</system.webServer>
</location>
Of course, you can use it for MVC route
<location path="Home/Privacy">
<system.webServer>
<security>
<authorization>
<add accessType="Deny" users="wicresoft\jokiesd" />
</authorization>
</security>
</system.webServer>
</location>
Upvotes: 1