Click here to Skip to main content
15,885,161 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
On Windows, I tried to check current logged in user password is checked using Win API LogonUser. I also got the user and domain (using WTSQuerySessionInformationW), after that I passed these username, domain and blank password to function LogonUser. It works as I expected. But my program is a service, and it requires calling check password every 15min. So if in Group Policy Managament, I set the policy Account Lockout ThreshHold to x times. If I call LogonUser function x times, my account is locked. The same thing happens on both workstation and domain environment.

Does anyone have any idea on this issue?

Similar Posts that don't answer question:

How to Detect Empty Password Users[^]

Thanks a lot
Posted
Updated 7-Nov-13 22:23pm
v3
Comments
nv3 8-Nov-13 3:41am    
I doubt that there is method of finding an empty password account easily. That would in fact be a security problem, because it would allow attackers equally well to scan for such accounts.

If you want to make sure all your users have a non-blank (and secure) password, do it by setting the group policy accordingly.
ducminh0410 8-Nov-13 4:15am    
Thanks a lot for your answer. Herein, I don't try to figure out user password has been set up or not as Server Admin. All I want is find a method/function/solution to detect whether password has been set or not as a feature of my application.
You said that there is method of finding an empty password account easily. Do you know any kind of method like this which can help me?
nv3 8-Nov-13 4:33am    
I think you got me wrong. I said: I doubt that there is such a method. And the reason for that doubt is: This would allow an application easily to scan for empty-password accounts, and that would be a security leak.

1 solution

You can query attributes from AD/LADP. I user changes password, an attribute is set. See: http://msdn.microsoft.com/en-us/library/windows/desktop/ms679430(v=vs.85).aspx[^].

As I didn't really got your final goal, this might not be the solution, but than explain your goal properly, since you might address it the wrong way. But I can't imagine any situation where you really have to probe password of any kind.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900