Skip to content
Back to blog
curtainmacosswiftopen-source

Curtain: Closing macOS Screen Sharing's One Privacy Gap in an Afternoon

2 min read

macOS Screen Sharing is excellent, but it leaves one real privacy gap. The fix is simple, yet it usually hides behind pricey paid tools, so I built an open-source version in an afternoon.

macOS has Screen Sharing built in, and it works beautifully. You can reach your Mac from anywhere and drive it as if you were sitting in front of it. But it leaves one gap that matters. When you remote in, anyone standing at the physical desk sees everything on your screen, and they can move the mouse or type into your apps while you work. For a machine in a shared office, a lab, or a home with other people around, that is a genuine privacy and safety problem.

The fix is simple in concept. Cover the local displays and ignore physical input, while your remote control keeps working normally. The catch is what makes it tricky: your laptop and the desk share one login session, so a naive overlay would block you too. The trick is to filter input by where it comes from. Block the physical hardware events from the desk, and let the injected remote events pass through untouched. No virtual display, no second account, no kernel extension.

This capability does exist, but it tends to live behind paid remote-desktop tools, and the privacy piece in particular often sits in the pricier tiers. Paying a lot of money for one small, well-understood feature felt wrong, especially when the hard part, the actual screen sharing, is already free and built into the operating system.

So I built Curtain in an afternoon. The first working version came together in about ninety minutes on June 1. It is a small Swift menu-bar agent. It detects a remote session using a transport-independent capture flag plus the network signals that Screen Sharing leaves, covers the displays, filters desk input by event source, and ships with a Carbon hotkey for emergency unlock so you can never lock yourself out, even if you have not granted Accessibility yet. A few days of polish followed, but the core was a single afternoon.

It is open source and free. If macOS already does the hard ninety percent of remote access, the missing privacy layer should not cost a small fortune. The best little projects are the ones that scratch a specific itch, and this is one of those. A simple idea that a lot of people quietly need, given away so nobody has to pay rent on it.