Information Security Stack Exchange is a question and answer site for information security professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know I have read somewhere that the reason the UAC prompt in Windows 7 was employed is that viruses that would supposedly execute privileged instructions won't be able to "click" the confirm button when prompted with the UAC GUI prompt.

So if I created an application with a GUI login with a login button, will a virus/script be able to brute force it?

share|improve this question

A script can simulate keystrokes/mouse clicks on Windows. I believe the UAC prompt is protected by the OS making automating clicking it a more difficult task. (I'm not a windows user; but its straightforward to simulate mouse clicks/movement in windows). Apparently the UAC screen is run as the System user (a user with more permissions than an administrator, but not quite the kernel) so unless you were able to write and execute a script as the System user you would not be able to bypass the UAC clicks.

But in general, having a GUI login with a button doesn't make your login screen any more difficult to break. Any reasonable attacker will examine how your program is checking the password, extract out the saved hash from memory and write some massively parallel GPU code to brute force it. (Unless its done over the network and then they'd stop using your GUI and do the requests directly). But even if somehow constrained to simulating keystrokes and mouse movements/clicks its still trivial to do.

share|improve this answer
2 has some info on what makes Secure Desktop (and the UAC prompt running on it) secure. – Bob Watson Feb 14 '13 at 6:02

I'm not sure how you think the UAC prompt is related to bruteforcing a GUI login.

The UAC prompt runs in something Microsoft calls a secure desktop. The only processes that are running in the secure desktop environment are trusted processes running as SYSTEM. This is secure as no malware running under user privilege level can execute in the secure desktop environment. It's essentially a clean environment where you can safely allow or reject new processes.

If you have an application already running with a GUI login page, I can most certainly write a piece of malware or script to bruteforce the user accounts. The UAC secure desktop environment has nothing to do with it.

share|improve this answer
well the prompt has a button provided for confirming the escalation of privileges, I was thinking if it was possible for a virus to brute force a GUI with a login button since as per what I read ... (refer to my post) so I thought clicking can't be emulated by viruses – Mywiki Witwiki Feb 14 '13 at 11:16
@MywikiWitwiki Clicking can most definitely be emulated programatically. The reason why the UAC prompt is secure is that it occurs in a totally separate desktop environment where only SYSTEM processes are allowed to run. This is a feature of the Windows operating system, nothing to do with GUI buttons whatsoever. – Terry Chia Feb 14 '13 at 11:23

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.