Hacker News new | ask | show | jobs
by chii 2654 days ago
> The solution is simple: Don't let any process read the clipboard unless the user explicitly pastes.

but how does an OS know that a particular key combination is meant to mean "paste"?

Couldn't the app just pretend that the user wanted to paste because their cursor is in the password field?

Or, you end up with the OS owning all of an app's interaction. Leaving very little room for app innovation or improvement. It's a bit of a rock and a hard place.

1 comments

> how does an OS know that a particular key combination is meant to mean "paste"?

macOS and iOS can do that easily; every app has a standard menu provided by the system, as well as a mechanism for modifying default shortcuts.

The clipboard should be treated like a potentially sensitive file. There's no excuse not to include it in the explicit permissions we already require for other files, photos, camera, microphone, contacts, location, and so on.