Re: restricting access based on Org Unit (OU)



If you want to use the role provider with Windows authentication, you can
use the WindowsTokenRoleProvider. It does the same thing as
IPrincipal.IsInRole in this instance.

Joe K.
--
Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--
"SpaceMarine" <spacemarine@xxxxxxxxxxxxxx> wrote in message
news:5f9dcc1e-f2df-4ee5-94ed-b5d39497ee78@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On May 19, 3:37 pm, "Joe Kaplan"
<joseph.e.kap...@xxxxxxxxxxxxxxxxxxxxxxxx> wrote:
There are many methods. If you are using Windows authentication in your
application, then you can just use the IsInRole method on the
WindowsPrincipal class. ASP.NET will insert a WindowsPrincipal
representing
the current Windows user into the HttpContext.User property and you can
access that from anywhere in a web app. You can also put this directly
into
the authorization section of the web.config and just add the role name to
the appropriate config parameter there (no coding needed).

Tho one question...How does this relate w/ using a Roles provider? I'm
not sure, but I think an ASP.NET could still use a custom Roles
provider, and use the the AD Group technique you've mentioned?


sm


.



Relevant Pages

  • Re: Error setting DirecotrySearchers new ExtendedDN
    ... Thanks Joe, but now I'm worried and confused. ... 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, ... The .NET Framework does not support all versions of every platform. ... Co-author of "The .NET Developer's Guide to Directory Services Programming" ...
    (microsoft.public.platformsdk.security)
  • Re: Windows Integrated Authentication not working
    ... you don't need the role provider for windows auth - how do you access the site? ... using the fully qualified domain name, ... I am attempting to set up my intranet application with Windows ... use Role manager when select Windows Integrated Authentication? ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: Drawing on DC
    ... can you finally say me about a good guide to Windows ... for drawing in OnMouseMove is that the mouse is captured and the window ... The strokes are going into the container where it counts. ...
    (microsoft.public.vc.mfc)
  • Re: Welcome to windows/Switch user locked
    ... "Joe" wrote in message ... First I am working with windows XP. ... I'll call them Act 1 and Act 2. ... allowed me to access the two accounts. ...
    (microsoft.public.windowsxp.accessibility)
  • RE: Windows Explorer
    ... Hi, Joe. ... When running on the parallel OS, the 'big' folder (which ... original Windows installation, I found that that also now ... >temporarily uninstall the PaintShop Pro software to check ...
    (microsoft.public.windowsxp.perform_maintain)