16 Jan

Local Privilege Escalation Bug in Faronics Deep Freeze

While preparing update for Meltdown, I encountered a textbook error in Faronics Deep Freeze Enterprise v8.31. So, here goes..

Running With Unnecessary Privileges

frzstate2k.exe is application responsible for displaying Deep Freeze Workstation Configuration dialog. To do that, it sits in the system tray and communicates with DeepFreeze driver.

For reasons I really can't understand, this simple UI component is executed under SYSTEM account. To make matters worse, it doesn't even drop unnecessary privileges. All these are textbook errors and Microsoft has spent last 10+ years trying to educate programmers and eliminate these kinds of bugs.

Here's the great presentation from Black Hat 2006 about this subject (slides 7-15): Security Engineering in Windows Vista

Abusing Common Dialogs

Microsoft Windows provide APIs for creating nice standard dialogs like "Open File.." and "Save As.." These dialogs are heavily integrated with Windows shell and offer much more than just file selection - within the dialog box you can do almost anything you can do using Windows Explorer. Like executing other applications..

Due to that, these dialogs are often used to break out of Terminal Server environment or to elevate local user privileges. Here is a quite good tutorial covering the basics: Breaking out of applications.

These attacks are also very old. Here's nice presentation from year 2008: Hacking Internet Kiosk’s

Putting it all together

Here's how any user can get SYSTEM privileges in 5 easy steps:

  1. user is logged on using low-privilege account,eg. belongs to "users" group;
  2. 1-user-privs

  3. user gains access to workstations DeepFreeze administration interface (eg. using password generated by Meltdown);
  4. 2-deepfreeze-ui

  5. user presses "Activate Now" -> "Activate Offline" -> "Next" -> and presses either of the 2 buttons that open "Save As" or "Open" dialogs;
  6. 3-create-activation

  7. since FrzState2k.exe is running under SYSTEM account, these dialogs give access to anything SYSTEM account has access to.
  8. user navigates to C:\Windows\System32\ , right-clicks cmd.exe, and chooses Open.
  9. 4-select-cmd

  10. cmd.exe is executed under SYSTEM account.
  11. 5-game-over

  12. game over.

Mitigating factors?

This attack was verified against 30-day evaluation version of Deep Freeze Enterprise. It is possible that after the workstation is activated, the "Activate Now" button is disabled and there's not an easy way to access it. This would (accidentally) limit attacks only to workstations that haven't been activated yet.

Conclusion

It's hard to write anything here without using inappropriate language. Faronics positions itself as a security company, yet their products contain textbook errors like these. Make your own conclusions.

2 thoughts on “Local Privilege Escalation Bug in Faronics Deep Freeze

  1. I'm not entirely sure how one is supposed to access the Deep Freeze configuration without the Administrator password (and if you've got that, you're already SYSTEM).

    • Ah, never mind, I just found your previous post on how to get the password from Deep Freeze itself. Yikes, what a horrible design.

Leave a Reply

Your email address will not be published.