CH-J Toolsserver management over SSH
Menu
All guides and articles →

Ed25519 vs. RSA: choosing and installing SSH keys

Choose a compatible key, protect its private half and test the new login before removing the old access method.

Choose for policy and compatibility

Ed25519 is a useful choice when supported by your server and security policy. Use RSA 3072 or 4096 where compatibility or policy requires it. An RSA key is not synonymous with the old SHA-1 ssh-rsa signature: modern RSA can use SHA-2. Do not globally re-enable legacy signatures.

Post-quantum hybrid: ssh-mldsa44-ed25519

ssh-mldsa44-ed25519 combines the post-quantum signature ML-DSA-44 with Ed25519: a forged login would require breaking both algorithms. CH-J Key Generator in Beta 0.1.2 creates this key type, and CH-J Tools adds it to a server only when the server runs OpenSSH 10.6 or newer. Older releases reject it; some, such as 10.2p1 in Ubuntu 26.04, know only an experimental …@openssh.com variant that CH-J Tools does not use. Keep an Ed25519 or RSA key as a fallback for servers and clients without support. The guide linked below shows how to install OpenSSH 10.6 next to the distribution package.

Generate locally and protect the private key

Choose one command and a new filename; do not overwrite an existing key. Set a passphrase when prompted. Only the .pub file belongs on the server. Keep the private key on the client. CH-J Key Generator is already available in Beta 0.1.0.

ssh-keygen -t ed25519 -f ~/.ssh/id_ed25519_chj
ssh-keygen -t rsa -b 3072 -f ~/.ssh/id_rsa_chj
ssh-keygen -lf ~/.ssh/id_ed25519_chj.pub -E sha256

Install the public key, then test

Put the complete public key on one line in the target account’s ~/.ssh/authorized_keys. On Linux, check account ownership and typically mode 700 for .ssh and 600 for authorized_keys. Keep your current session open and test a second login with the selected key before changing old access. User keys and server host keys serve different purposes.

ls -ld ~/.ssh ~/.ssh/authorized_keys
ssh -o IdentitiesOnly=yes -i ~/.ssh/id_ed25519_chj user@server.example

Detailed documentation

OpenSSH: ssh-keygen →

OpenSSH: sshd_config →

OpenSSH 10.6 for post-quantum SSH keys →

Biometric unlock and security →