active directory - Check IsInRole against AD -


i tried work windowsprincipal getting confused. use code snippet:

windowsprincipal principal = new windowsprincipal(windowsidentity.getcurrent()); messagebox.show(thread.currentprincipal.isinrole("mydomain\\users").tostring()); 

it returns true it's ok. thought "isinrole" check works against active directory. when unplug network cable still returns true. how come? there easy way check whether logged user in specific domain against ad?

active directory credentials can cached on local system, including role membership (to support group policy enforcement). can turn off credential cache described in msdn kb cached domain logon information, i'm not sure clear cache. while cannot confirm (as i'm not on system cached credentials), believe stored hashes under registry key hkey_local_machine\security\cache\ in values labeled "nlx" x integer.


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -