Skip to content

Instantly share code, notes, and snippets.

View Meshiest's full-sized avatar
🍰

Isaac Meshiest

🍰
View GitHub Profile
@TimJDFletcher
TimJDFletcher / GNUPG_agent_forwarding.md
Last active November 6, 2026 10:30 — forked from surhudm/GNUPG_agent_forwarding.md
GnuPG agent forwarding

Forward the GnuPG agent from macOS to Linux

Your private keys stay on the Mac, or on your YubiKey, and gpg on the Linux host uses them over SSH.

Last tested in October 2026 from macOS with GnuPG 2.5.24 and OpenSSH 10.5 to Debian 13 with GnuPG 2.4.7 and OpenSSH 10.0. You need GnuPG 2.1.17 or newer on both ends and OpenSSH 6.7 or newer.

On the Mac

Install GnuPG and a graphical pinentry. Passphrase and PIN prompts appear on the Mac, so a terminal pinentry won't work for a request that comes from the remote host.