Solved

Role authentication not working right

Posted on 2008-10-10
3
218 Views
Last Modified: 2013-11-07
in my web.congif file in a subfolder to the root, I have the attached Code Snippet.

Based on this, all users should be denied access except for those possessing the role of OfficeStaff.
This is not happening for some reason. Thanks for the assistance.
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.web>
    <authorization>
      <allow roles="OfficeStaff" />
      <deny users="*" />
    </authorization>
  </system.web>
</configuration>

Open in new window

0
Comment
Question by:wilcor14
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 18

Expert Comment

by:David Robitaille
ID: 22688099
try this
i added a <deny users="?"/>
it deny the unautentified users

 

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.web>
    <authorization>
      <deny users="?"/>
      <allow roles="OfficeStaff" />
      <deny users="*" />
    </authorization>
  </system.web>
</configuration>

Open in new window

0
 
LVL 18

Accepted Solution

by:
David Robitaille earned 500 total points
ID: 22688588
i just saw it was a subfolder...
I checked and the problem is not in that web.config it is exactly like mine, an mine work.
Did you try to do an iis reset to make sure the file is read by the web server?
0
 

Author Closing Comment

by:wilcor14
ID: 31505058
That was it. Thanks.
0

Featured Post

MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question