LogonUser (Sort of)
-
I have a desktop application that must authenticate each user. I am not allowed to have my own password file, nor to store passwords in a database. The application needs to work on XP and Win2K, and will be written in VC6++. LogonUser looks perfect, because it lets me authenticate the passwords the same way that Windows does when users log in every day. It works fine on XP. It fails on Win2K, of course, because SE_TCB_NAME is not granted to user accounts. Any suggestions for something similar? I do NOT need the token that is normally generated by LogonUser, as I'm not starting a service or impersonating a user. I only need the BOOL that tells me the password is valid or not.
-
I have a desktop application that must authenticate each user. I am not allowed to have my own password file, nor to store passwords in a database. The application needs to work on XP and Win2K, and will be written in VC6++. LogonUser looks perfect, because it lets me authenticate the passwords the same way that Windows does when users log in every day. It works fine on XP. It fails on Win2K, of course, because SE_TCB_NAME is not granted to user accounts. Any suggestions for something similar? I do NOT need the token that is normally generated by LogonUser, as I'm not starting a service or impersonating a user. I only need the BOOL that tells me the password is valid or not.
-
mmmm... I wouldn`t like to log on on an application using my windows password... I never know what are you going to do with it. I think you need to look for another approach. If you need login in an application you will need an encripted passwords file.
-
Company IT policy doesn't allow me to keep my own password file, even if it is encrypted. We thought of using the Windows password because it is an authenticaion system already available in the company.
if the user is logged in and is using your program then they are already authenticated. If you are doing this over a network then you could use named pipes and check the user at the other end.. james
http://www.catch22.net -
I have a desktop application that must authenticate each user. I am not allowed to have my own password file, nor to store passwords in a database. The application needs to work on XP and Win2K, and will be written in VC6++. LogonUser looks perfect, because it lets me authenticate the passwords the same way that Windows does when users log in every day. It works fine on XP. It fails on Win2K, of course, because SE_TCB_NAME is not granted to user accounts. Any suggestions for something similar? I do NOT need the token that is normally generated by LogonUser, as I'm not starting a service or impersonating a user. I only need the BOOL that tells me the password is valid or not.
There is a way to do this. Here is a CP article in Purgatory: http://www.codeproject.com/Purgatory/UserAuthentication.asp[^] The CP article points to a Microsoft KB article: http://support.microsoft.com/kb/180548/EN-US/[^]
-
if the user is logged in and is using your program then they are already authenticated. If you are doing this over a network then you could use named pipes and check the user at the other end.. james
http://www.catch22.netI also argued the position that logging into Windows should suffice. After all, Office works this way. We use Outlook here, and you need not provide a seperate password for that. The local powers here were unconvinced, so I have been looking for a way to do it. Thanks.