k80sg
k80sg

Reputation: 2473

Allowing roles in web.config

I created an administrator role in ASP.Net configuration named "Administrators" and assigned one user to it, in my web.config I specify this:

  <location path="Admin/Default.aspx">
   <system.web>
     <authorization>
       <allow users="Administrators" />
       <deny users="*" />
     </authorization>
   </system.web>
   </location>

But it's not working, the user under administrator role is unable to access. Please advice.

Upvotes: 1

Views: 1979

Answers (1)

SLaks
SLaks

Reputation: 887275

<allow roles="Administrators" />

Roles aren't users.

Upvotes: 6

Related Questions