AIRPOCKET GITHUB
G1GUIDE · TAILSCALE

MagicDNS, HTTPS certificates, and which tailnet you are in

Airpocket's phone app reaches your Mac over your own Tailscale network, at the Mac's name in that network, over HTTPS. That takes two tailnet settings, MagicDNS and HTTPS certificates, and only the tailnet's admin can turn them on. If you signed in to Tailscale with a work email, that admin is probably someone else.

01
WHAT IT NEEDS

Tailscale on both ends, one tailnet

Airpocket has no server of its own. The phone talks to each Mac directly, and Tailscale is what makes that work from anywhere: it puts your devices on a private network of their own, a tailnet, and encrypts what passes between them with WireGuard.

You need Tailscale on the Mac and on the iPhone, signed in to the same tailnet. On the Mac, airpocket setup publishes the app inside that tailnet with tailscale serve, at an address of this shape:

https://studio-mac.tail1a2b3c.ts.net

Both settings are about that address.

02
WHY BOTH

What MagicDNS and HTTPS certificates are for

  • MagicDNS gives every device in the tailnet a name under the tailnet's own ts.net domain. That name is the Mac's address for the phone, and the address the pairing QR code carries.
  • HTTPS certificates let Tailscale obtain a real certificate for that name, so the address can start with https://. Airpocket is a web app you add to the Home Screen, and a browser gives a page the parts that make it an app, such as the offline shell and the camera that scans the pairing code, only over a secure connection.

Tailscale ends the encrypted connection on the Mac itself and hands each request to Airpocket on 127.0.0.1, the only address Airpocket listens on.

airpocket setup checks both settings before it changes anything. If one is off, it stops and says which.

03
THE TRAP

Signed in with a work email? Then the tailnet isn't yours

WRITTEN DOWN BECAUSE IT COST AN EVENING

This one cost one of Airpocket's co-founders an evening. It is written down here so that it doesn't cost you one.

Tailscale sorts people into tailnets by the email domain they sign in with. Sign in with a work address and you join your company's tailnet, not one of your own. There you are a member, not the admin:

  • an admin may have to approve each device you add;
  • the admin console refuses you;
  • MagicDNS and HTTPS certificates are tailnet-wide settings, so both are someone else's switch.

Nothing on your Mac or your phone can change that. Setup stops with that explanation in plain words rather than half-installing.

Two ways out

  1. Use a personal account. Sign in to Tailscale with a personal account, the same one on the Mac and on the phone. That gives you a tailnet of your own, where you are the admin and each setting is one switch.
  2. Ask the admin. A shared tailnet works as well. Its admin turns both settings on once, for everyone in it.

Sharing a tailnet doesn't share sessions. Every Mac asks the phone for a pairing code of its own and hands out its own token, so another member of the tailnet can reach the address but not your sessions.

04
SWITCHES

Turning them on

  1. Open the DNS page of the Tailscale admin console, signed in as the tailnet's admin.
  2. Turn on MagicDNS, if it isn't on already.
  3. Turn on HTTPS Certificates, on the same page.
  4. Run setup again on the Mac.
$ airpocket setup

The first time the phone opens the address, the Mac can take fifteen seconds or more to answer while the certificate is issued. That wait is expected, and it doesn't come back with every visit.

Afterwards, airpocket doctor checks the addresses along with everything else, and gives a fix for anything it finds.

05
EXPOSURE

What becomes public, and what never does

The Mac's name becomes public. Every certificate a public authority issues is recorded in public certificate-transparency logs, and a Tailscale certificate names the machine: something like studio-mac.tail1a2b3c.ts.net. Anyone reading those logs can learn that the name exists.

What it serves does not. Airpocket publishes with tailscale serve, which makes a port reachable from devices in your tailnet and from nowhere else. Knowing the name gets a device outside the tailnet nothing.

Airpocket never uses tailscale funnel, the command that would put a port on the public internet, and nothing in its instructions asks you to. Setup also leaves ports alone that another program already publishes: it takes 443 and 8443 when they are free, and otherwise the next free ones of 4443, 5443 and on.

Inside the tailnet, reaching the address isn't enough either. Only a phone paired with a one-time code from that Mac can use it, and airpocket revoke cuts a phone off at once. Tailscale's own access rules can narrow which devices reach the Mac at all. The threat model goes through the rest.