Security foundations Security boundaries 2 min read

What stops a web app from opening the rest of your files?

You open an online photo editor and select portrait.jpg in the browser’s file picker. A tax document sits in the same folder. Why can’t the editor open that too?

  1. The browser enforces the boundary

    The editor can ask for another file, but the browser controls the picker and the permission. That makes the browser the enforcer: it mediates what the web page can access on your device.

    In short Find the component that can enforce the permission.

What happens after you grant access

Once the editor can read the photo, it can work with the photo’s contents. The file grant controls access to your device. It doesn’t decide what the editor does with the contents after reading them.

Keep this

Find who enforces the permission.

Follow the request to the component that can grant or refuse access.

Sources

Last reviewed 17 November 2026.

Next byte · Security foundations Least privilege: give only what’s needed