I have a new C#.net 2008 console/windows form application that I need to add security for. I would like to tie all logins together at one time using the active directory. I would like to have windows authenicatiuon setup to use to connect to the sql server 2008 r2 database, I would like to know what role each person has, I also would like to setup a methods to determine what application a user has access to and what their roles are in each application. (For example; a person can have access to app1 and be a manager in the next applicationn theperson would only have a 'general' user role.) Thus i am wondering if you can tell me the following;
1. I would like to know how each person can connect to the database,
2. I would like to see C#.net 2008 code that would accomplish the tasks i listed above or at least accomplish part of the tasks listed above.
Loading
Piyush AgrawalPosted Sep 12, 2011, 6:37 AM
static void DirectoryEntryConfigurationSettings(string domainADsPath){ // Bind to current domain DirectoryEntry entry = new DirectoryEntry(domainADsPath); DirectoryEntryConfiguration entryConfiguration = entry.Options; Console.WriteLine("Server: " + entryConfiguration.GetCurrentServerName()); Console.WriteLine("Page Size: " + entryConfiguration.PageSize.ToString()); Console.WriteLine("Password Encoding: " + entryConfiguration.PasswordEncoding.ToString()); Console.WriteLine("Password Port: " + entryConfiguration.PasswordPort.ToString()); Console.WriteLine("Referral: " + entryConfiguration.Referral.ToString()); Console.WriteLine("Security Masks: " + entryConfiguration.SecurityMasks.ToString()); Console.WriteLine("Is Mutually Authenticated: " + entryConfiguration.IsMutuallyAuthenticated().ToString()); Console.WriteLine(); Console.ReadLine(); }
Piyush
Lepide.com
jasminiePosted Sep 2, 2011, 12:50 PM
SORRY!
jasminiePosted Sep 2, 2011, 12:49 PM
Suthish NairPosted Aug 25, 2011, 11:25 AM