Reputation: 73185
Given a user's name and password, is there a way to check if the name is a valid user account on the system and if the supplied password matches the password for that user's account?
Edit: The need for this arises from the way authentication is structured in this application. The app uses the local accounts on the system to allow the users to remotely access files and stuff. My app needs a way of authenticating those users to provide them with access to its services.
Upvotes: 4
Views: 5084
Reputation: 159618
You should be able to use the LogonUser() API for this purpose... If the call fails, then either the username or password are bogus.
Upvotes: 8