I have an app that contains configuration settings that should be changed only by a user that is part of the MyAdvancedUsers Active Directory group. This application is a C# .NET 4.0 desktop application (not a web application)
When the app is running with regular user permissions, is it possible to allow access to the configuration settings form by a member of the MyAdvancedUsers by having the advanced user enter his/her windows username and password combination?
It’s fairly simple to do this. Create a
PrincipalContextand callValidateCredentials()on it, thusly:Try this site for a good way to capture the credentials from the user.
@Kitsune: you do not need to elevate privledges just to validate a user’s credentials.