win form security

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like to authenticate to windows via a login creen in my application.
when i do a search I get stuff but on asp. This is not for asp.net I just
what a login screen for win form applications that will check the username
and password entered in a login screen against windows local or on a server.
 
freddy,

Basically, you are going to have to call the LogonUser or LogonUserEx
function in the API through the P/Invoke layer. It will validate the user
and the password. You can also impersonate the user logged in (which you
should, for certain permissions) by using the WindowsIdentity class (check
the documnetation for the Impersonate method on the WindowsIdentity class to
see how).

Hope this helps.
 
Back
Top