An SSH private key is a credential people reach for sharing tools for less often than a password, mostly because it looks like a file rather than a secret. It still grants exactly the same thing a password does — access to a server — and it travels the same careless way most credentials do: pasted into a Slack message, attached to an email, dropped in a shared doc “just for now.”
The file itself is the problem, not just where it’s sent. Whatever channel carries it keeps a copy, indefinitely, in message history or an attachment store that nobody circles back to clear out. Six months later the key is still readable there, whether or not it still grants access to anything.
Why this handoff deserves more care than it usually gets
- A private key is a long-lived identity, not a one-time code. Unless it’s rotated, it keeps working until someone remembers to revoke it — which, for a key handed over once during setup, can be a very long time.
- It’s rarely scoped. Many shared SSH keys grant the same access the original holder has, rather than access limited to one server or one task, so a leaked copy can matter well beyond the reason it was sent.
- People don’t think to delete the copy. A password in a chat thread sometimes gets flagged; a key file sitting in an email attachment usually doesn’t, because it doesn’t look like the kind of thing that needs cleaning up.
The approach: a fresh key pair, sent once, then removed
- Generate a new key pair for the recipient, if you can, rather than sharing one that’s already in use elsewhere.
ssh-keygenon their end, or on yours if you’re handing over a ready-made identity, takes a minute and means nobody but them ever holds this exact private key. - Paste the private key into EasyToPaste. Your browser encrypts it with AES-256-GCM using the Web Crypto API before anything leaves the device — the decryption key lives in the link itself, after the
#, which browsers never send to any server. The service stores only the ciphertext and cannot read the key. - Pick the shortest expiry that still works. If the recipient is online now, use the shortest option available rather than the 30-day maximum.
- Send the link through your normal channel, and confirm separately — a short message on another channel or a quick call — so a surprise link can be told apart from a phishing attempt. The same verification habit is covered in our guide on sending a secret to someone who isn’t deeply technical.
- The recipient opens the link once, saves the key file locally with the right permissions (
chmod 600), and the stored copy is gone. Nothing is left in a message history to find later. - Add only the matching public key to authorized_keys, and remove it again once the access is no longer needed. If the private key granted broader access than this one task required, rotate it once the handoff is done.
Scope the access before you send anything
- Issue a key per person, per purpose, rather than reusing one key across contractors or environments — it’s the only way to revoke one person’s access without breaking everyone else’s.
- Restrict what the key can do on the server side where your setup allows it — a
command=restriction or a limited shell for a one-off task, rather than full access by default. - Set a reminder to revoke it. A one-time link only protects the handoff; nothing protects an authorized_keys entry nobody remembers to remove.
None of that is EasyToPaste’s job — it’s server administration — but it decides how much a single leaked key file can actually cost.
What EasyToPaste can and can’t see
The service can see that a secret exists, its type and size, and when it was created — enough to run the product and enforce limits. It cannot see the content or the decryption key, which never leaves your browser in readable form. It keeps no read receipt: the record is deleted once the secret is read or it expires, so you can tell it’s gone, but not which of the two happened. The Security page has the full technical detail.
Common situations
Onboarding a new contractor to a server. Generate a key pair for them specifically, send the private half as a one-time link, and add only their public key to authorized_keys.
A teammate needs access during an outage. Speed matters here — send the link, confirm by voice or a quick message, and revoke or rotate the access once the incident is resolved.
Decommissioning shared access. If a key has been passed around to several people over time, that’s the sign to stop: issue everyone their own key, revoke the shared one, and use a one-time link only for each individual handoff going forward.
The short version
- Don’t paste an SSH private key into a chat message or email attachment — it stays there indefinitely.
- Generate a fresh key pair for the recipient where you can, instead of sharing one already in use.
- Send the key as an encrypted, self-destructing link with the shortest expiry that still works.
- Confirm you sent it on a second channel before the recipient opens it.
- Remove the shared key from authorized_keys, or rotate it, once the handoff is done.
Create a one-time link for the next key handoff and see what the recipient sees by opening it in a second browser window.