File powerboxes

What is a file powerbox?

A file powerbox is a kind of file chooser dialog box, and it works the same from the user's perspective. The difference is that as well as telling the application which file to access, it dynamically grants the application the right to access the file.

This helps provide security: It means that the application does not have to be given access to all of the user's files by default. This is an example of applying the principle of least privilege/authority: the aim is to give the program the authority it needs to do its job, but no more.

An example

Suppose you run Gnumeric to view a spreadsheet you downloaded from the Internet. Gnumeric might not be a malicious program, but suppose it has a buffer overrun bug -- quite possible considering that it is written in C -- and the spreadsheet exploits that bug.

If Gnumeric runs with all your authority, the dodgy spreadsheet can read any of your files (such as "~/sensitive-file.txt", or your private keys from "~/.ssh") and send them back to its creator.

But if Gnumeric runs with minimum authority, the malicious spreadsheet can't do anything except write to the file it was opened from, and open a powerbox to request a file. The application cannot specify a default pathname for the powerbox to open, so for the spreadsheet to get access to a sensitive file, the user would have to specifically choose that file. The malicious spreadsheet would find it very hard to get access to ".ssh": why would the user choose ".ssh" if Gnumeric opened a powerbox out of the blue without a good reason?

How do powerboxes work?

In order for the powerbox file chooser to provide security, it cannot be implemented by the application and its libraries. It must be implemented as a separate, trusted component, and it must run in its own protection domain.

The idea is that the file chooser has a trusted path to the user, so only the user can enter a filename into it. This allows the system to distinguish between requests made by the user and requests made by the application.

Plash's implementation

See GtkFilePowerboxHook

Arguments to powerbox API

History

The powerbox concept appears to have first been proposed by Ka-Ping Yee and Miriam Walker in Interaction Design for End User Security (December 2000).

Other trusted-path user interfaces

Other powerbox implementations

Other systems have implemented powerboxes:

The One Laptop Per Child project has recently proposed a powerbox system for its "Bitfrost" security system (see the P_DOCUMENT requirement), currently only a specification.

FilePowerbox (last edited 2007-07-06 16:56:22 by MarkSeaborn)