Making My Homelab Post-Quantum Ready: Because Anthropic, OpenAI, CISA (and Apparently Santa) Said So

How I audited and upgraded my homelab to Post-Quantum Encryption (X25519MLKEM768 TLS, SOPS + Age mlkem768x25519, and OpenSSH 10.6) on St. Nicholas Day.

Santa Claus squinting at a Post-Quantum Age encrypted Christmas wish list in a homelab server room

Today is December 6, St. Nicholas Day (Mikołajki in Poland, Nikolaustag here in Germany). Normal parents spend Sunday afternoon putting chocolate coins and tangerines into their kids’ boots. I spent mine re-encrypting 66 Docker .enc.env files with 1,947-character post-quantum keys and reconfiguring five SSH servers so a future quantum computer from 2034 cannot read my Plex token or intercept a wish list to Santa ;)

Why did I do this on a Sunday? Earlier this week (December 2, 2026), Anthropic, OpenAI, Google, Cloudflare, Apple, Microsoft, Amazon, and Oracle published a joint statement backing urgent NSA and CISA guidance to move to Post-Quantum Encryption right now. When eight companies that normally fight over everything agree on a security warning, my homelab brain immediately says: put down the gingerbread cookie and check the Minisforum MS-01 in the hallway closet :D In today’s post, I will show you what I found in my lab and how I switched everything over in about two hours.

Why Everyone Suddenly Talks About Post-Quantum Encryption

For years, post-quantum encryption felt like something we would only worry about in the 2030s. Two things pushed it up the priority list this week:

  1. AI is speeding up cryptography research: On November 30, 2026, Anthropic published research where an internal Claude model helped find theoretical math shortcuts in parts of the math used by NIST’s post-quantum standards (ML-KEM and ML-DSA). Cryptographers confirmed this does not break real-world ML-KEM-768 or ML-DSA keys, because the attack still costs way more compute than existing methods. Still, seeing an AI model poke holes in modern cryptography math was enough for CISA and the NSA to tell everyone to stop waiting.
  2. Harvest Now, Decrypt Later (HNDL): Nobody has a quantum computer in their basement running Shor’s algorithm today, and maybe nobody will for years. Storage, on the other hand, is dirt cheap. Anyone recording encrypted VPN traffic, TLS handshakes, or leaked Git repositories with X25519-encrypted secrets in 2026 can save those files on disk and decrypt them once quantum hardware catches up.

Symmetric encryption is fine here. Shor’s algorithm breaks public-key encryption like RSA-2048, Diffie-Hellman, ECDSA, Ed25519, and X25519. Against symmetric encryption and hashes, Grover’s algorithm only cuts key strength in half, so AES-256-GCM, ChaCha20-Poly1305, and SHA-384 / BLAKE2b-256 still leave you with 128+ bits of security.

In my opinion, hybrid post-quantum encryption (X25519MLKEM768 in TLS 1.3, mlkem768x25519-sha256 or sntrup761x25519-sha512 in OpenSSH, and ssh-mldsa44-ed25519 for SSH keys) is the smartest way to set this up today. It combines standard X25519 / Ed25519 keys with new post-quantum ML-KEM / sntrup761 keys in one handshake. Even if someone finds a bug in the new post-quantum math or builds a quantum computer that breaks X25519, they have to break both at the same time just to read my Home Assistant MQTT password.


Step 1: Auditing My Homelab (Somehow Ahead of My Bank)

Before editing any configs, I tested live openssl s_client and ssh -vvv connections across all my machines: my CachyOS Linux Zen 5 workstation, the 92 TB Unraid 7 NAS, the Minisforum MS-01 Docker host, Home Assistant OS, and my external Pangolin proxy.

To be honest, I expected a mess. Instead, half of my homelab was already using NIST post-quantum encryption out of the box, while my regular online bank still negotiates plain old ECDHE like it is 2017 ;)

You can test any HTTPS endpoint yourself with one openssl command:

1
2
3
# Check if a TLS 1.3 server negotiates hybrid X25519MLKEM768
echo | openssl s_client -connect www.wojcieh.net:443 -servername www.wojcieh.net 2>/dev/null \
  | grep -iE "(Protocol|Cipher|Negotiated TLS1.3 group)"

My initial audit before changing anything looked like this:

Service / Host Status What Was Actually Running
Cloudflare Edge (wojcieh.net) Ready TLSv1.3 + X25519MLKEM768 + TLS_AES_256_GCM_SHA384
Pangolin Edge Proxy Ready TLSv1.3 + X25519MLKEM768
Local Traefik v3.8.0 (MS-01) Ready Go 1.27+ enables X25519MLKEM768 on :443 by default
SSH: Unraid 7 & Home Assistant Ready OpenSSH 10.6 / 10.3 -> mlkem768x25519-sha256
Backups (Kopia) Ready AES256-GCM-HMAC-SHA256 + BLAKE2B-256-128 (256-bit symmetric)
SSH: MS-01 & Linux VPSes Needs Fix Ubuntu 24.04 (OpenSSH 9.6p1) had classical curve25519-sha256 listed before sntrup761x25519
Git Secrets (SOPS + Age) Classical Only 66 .enc.env files encrypted with a classic X25519 key (age1...)
Pangolin Tunnel (Newt <-> Gerbil) Classical WG Standard WireGuard (Curve25519 without a post-quantum pre-shared key)

Two real problems stood out right away:

  1. All 66 encrypted .enc.env files in my Docker Git repo (pushed to Gitea, GitHub, and Codeberg) used a classic X25519 Age key. If a private repo ever leaked today, someone could save it and decrypt all my API keys years from now.
  2. My own /etc/ssh/sshd_config.d/99-homelab-hardened.conf on Ubuntu 24.04 had curve25519-sha256 in first place under KexAlgorithms, which told SSH clients to skip OpenSSH’s built-in post-quantum key exchange (sntrup761x25519-sha512@openssh.com). Oops.

Step 2: Migrating 66 SOPS + Age Secrets to ML-KEM-768 (And a 1,947-Character Public Key)

I keep zero plaintext passwords in Git by encrypting all .env files with Mozilla SOPS and age. Starting with age v1.3.0 and sops v3.10, both tools natively support hybrid post-quantum keys (mlkem768x25519) through the age-keygen -pq flag.

My CachyOS workstation already had age v1.3.2 and sops v3.13.3 from the standard repos. My Ubuntu 24.04 Docker host still had age 1.1.1 and sops 3.9.4, which fail with an unknown recipient error as soon as they see an age1pq1... key. After copying the new static binaries into /usr/local/bin on MS-01, creating a post-quantum keypair was one command:

1
2
3
4
5
6
# Back up your existing keys.txt first!
cp -a ~/.config/sops/age/keys.txt ~/.config/sops/age/keys.txt.bak.pre-pq

# Append a new hybrid ML-KEM-768 + X25519 key (keep the old key so old git commits still decrypt!)
age-keygen -pq >> ~/.config/sops/age/keys.txt
chmod 600 ~/.config/sops/age/keys.txt

Important: Back up your updated ~/.config/sops/age/keys.txt right now. Without the new AGE-SECRET-KEY-PQ-1... line inside it, you will lock yourself out of every re-encrypted .enc.env file.

When I printed the new age1pq1... public key to the terminal, I started laughing. A normal X25519 Age public key is 62 characters long. A post-quantum ML-KEM-768 + X25519 public key is 1,947 characters long. Pasting it into a terminal command looks like my cat walked across the keyboard, sat on CapsLock, and ordered three 10GbE network cards :D

Save yourself the pain and put that 1,947-character key into .sops.yaml in the root of your repo so you never have to paste --age by hand again:

1
2
3
4
5
# .sops.yaml
creation_rules:
  - path_regex: (^|/)[^/]+\.enc\.env$
    age: >-
      age1pq1...<your-1947-character-mlkem768x25519-public-key>...

Gotcha (updatekeys vs rotate): Do not just run sops updatekeys. That command keeps the same existing symmetric Data Encryption Key (DEK) and only re-wraps it for the new key. Run sops rotate -i instead so SOPS generates a brand-new 256-bit AES-256-GCM key for every file and removes the old X25519 recipient completely.

I used this bash loop to rotate all 66 .enc.env files and verify with sha256sum that the decrypted content stayed identical:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env bash
set -euo pipefail

NEW_PQ_RECIPIENT="age1pq1...<your-1947-character-mlkem768x25519-public-key>..."

while IFS= read -r -d '' enc_file; do
  before_sha="$(sops --decrypt "${enc_file}" | sha256sum | awk '{print $1}')"

  # Generate a fresh 256-bit DEK and encrypt it only for the new PQ key
  sops rotate -i --rm-age "${OLD_CLASSIC_AGE_KEY}" --add-age "${NEW_PQ_RECIPIENT}" "${enc_file}"

  after_sha="$(sops --decrypt "${enc_file}" | sha256sum | awk '{print $1}')"
  if [[ "${before_sha}" != "${after_sha}" ]]; then
    echo "CRITICAL: SHA-256 mismatch on ${enc_file}!" >&2
    exit 1
  fi
  echo "[OK] Rotated ${enc_file} -> mlkem768x25519"
done < <(find . -name '*.enc.env' -print0)

Checking the header of any .enc.env file afterward shows only -> mlkem768x25519. Before pushing to Gitea, GitHub, and Codeberg, I ran ggshield secret scan commit-range HEAD~1..HEAD (0 secrets found).


Step 3: Locking Down OpenSSH (Zero Classical Downgrade)

Once Git secrets were done, I moved on to SSH across all my hosts: Unraid 7 (OpenSSH 10.6), CachyOS (OpenSSH 10.6p2), Home Assistant (OpenSSH 10.3), MS-01 (OpenSSH 9.6p1), and two external Linux VPS boxes.

Depending on which Linux distro you run, OpenSSH gives you two hybrid post-quantum options:

  • OpenSSH 9.0 to 9.8 (Ubuntu 24.04 LTS): Supports sntrup761x25519-sha512@openssh.com (Streamlined NTRU Prime + X25519, built by Daniel J. Bernstein’s team).
  • OpenSSH 9.9+ and 10.x (CachyOS, Unraid 7, HAOS): Adds NIST’s mlkem768x25519-sha256, and starting in OpenSSH 10.6, adds hybrid post-quantum host and user signatures via ssh-mldsa44-ed25519 (ML-DSA-44 + Ed25519).

Instead of editing five different configs by hand, I wrote one script that checks ssh -Q kex and ssh -Q key on each server, turns off classical curve25519-sha256 and diffie-hellman-* fallbacks completely, generates an ssh-mldsa44-ed25519 host key if OpenSSH 10.6+ is installed, keeps only 256-bit AEAD ciphers, and tests the config with sshd -t before reloading:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/usr/bin/env bash
set -euo pipefail

CONF_DIR="/etc/ssh/sshd_config.d"
TARGET_CONF="${CONF_DIR}/99-homelab-hardened.conf"
BACKUP_CONF="${TARGET_CONF}.bak.$(date +%Y%m%d-%H%M%S)"
mkdir -p "${CONF_DIR}"
[[ -f "${TARGET_CONF}" ]] && cp -a "${TARGET_CONF}" "${BACKUP_CONF}"

# 1. Enable ONLY Post-Quantum hybrid KEX algorithms supported on this machine
AVAILABLE_KEX="$(ssh -Q kex)"
KEX_LIST=()
for alg in mlkem768x25519-sha512 mlkem768x25519-sha256 sntrup761x25519-sha512 sntrup761x25519-sha512@openssh.com; do
  if grep -qx "${alg}" <<< "${AVAILABLE_KEX}"; then
    KEX_LIST+=("${alg}")
  fi
done
KEX_STR="$(IFS=,; echo "${KEX_LIST[*]}")"

# 2. Generate hybrid ML-DSA-44 + Ed25519 host key on OpenSSH 10.6+
AVAILABLE_KEYS="$(ssh -Q key)"
HOST_KEY_LINES="HostKey /etc/ssh/ssh_host_ed25519_key"
HOST_KEY_ALGS="ssh-ed25519"
PUBKEY_ALGS="ssh-ed25519,sk-ssh-ed25519@openssh.com"

if grep -qx "ssh-mldsa44-ed25519" <<< "${AVAILABLE_KEYS}"; then
  if [[ ! -f /etc/ssh/ssh_host_mldsa44_ed25519_key ]]; then
    ssh-keygen -t mldsa44-ed25519 -f /etc/ssh/ssh_host_mldsa44_ed25519_key -N "" -q
    chmod 600 /etc/ssh/ssh_host_mldsa44_ed25519_key
    chmod 644 /etc/ssh/ssh_host_mldsa44_ed25519_key.pub
  fi
  HOST_KEY_LINES=$'HostKey /etc/ssh/ssh_host_mldsa44_ed25519_key\nHostKey /etc/ssh/ssh_host_ed25519_key'
  HOST_KEY_ALGS="ssh-mldsa44-ed25519,ssh-ed25519"
  PUBKEY_ALGS="ssh-mldsa44-ed25519,ssh-ed25519,sk-ssh-ed25519@openssh.com"
fi

cat > "${TARGET_CONF}" <<EOF
PermitRootLogin no
PasswordAuthentication no
KbdInteractiveAuthentication no
PubkeyAuthentication yes
AuthenticationMethods publickey

${HOST_KEY_LINES}
KexAlgorithms ${KEX_STR}
Ciphers chacha20-poly1305@openssh.com,aes256-gcm@openssh.com
MACs hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com
HostKeyAlgorithms ${HOST_KEY_ALGS}
PubkeyAcceptedAlgorithms ${PUBKEY_ALGS}
EOF

# 3. Validate syntax before reload so you do not lock yourself out!
if ! sshd -t; then
  echo "ERROR: sshd -t failed! Rolling back." >&2
  [[ -f "${BACKUP_CONF}" ]] && mv -f "${BACKUP_CONF}" "${TARGET_CONF}" || rm -f "${TARGET_CONF}"
  exit 1
fi

systemctl reload ssh 2>/dev/null || systemctl reload sshd

Two platform-specific gotchas saved me a lot of headache here:

  • Unraid 7: /etc/ssh/sshd_config runs from RAM and resets from /boot/config/ssh/ after every reboot. Copy both ssh_host_mldsa44_ed25519_key* and your updated sshd_config to /boot/config/ssh/. Also make sure you put your crypto settings above Unraid’s # limetech - permit only root SSH tunneling Match block at the bottom of the file, otherwise sshd -t fails because Ciphers and KexAlgorithms are not allowed inside a Match section.
  • Home Assistant OS: If you use the Advanced SSH & Web Terminal add-on, do not edit /etc/ssh/sshd_config inside the container, because every add-on update overwrites it. Just set compatibility_mode: false and leave the password field empty in the add-on UI. OpenSSH 10.3 inside the add-on already puts mlkem768x25519-sha256 and aes256-gcm@openssh.com first.

After reloading sshd, I tested forcing a classical curve25519-sha256 connection to make sure downgrades get blocked:

1
2
3
$ ssh -o KexAlgorithms=curve25519-sha256 docker-host exit
Unable to negotiate with 192.168.250.2 port 22: no matching key exchange method found.
Their offer: sntrup761x25519-sha512@openssh.com

If an old SSH client or bot scanner does not support post-quantum key exchange, sshd drops the connection right away.


Step 4: The Bitwarden RSA-2048 Gotcha When Backing Up Your Key

Where should you store a backup of your new AGE-SECRET-KEY-PQ-1... private key? While checking Bitwarden, I found an easy trap to fall into:

  1. HTTPS connection (vault.bitwarden.eu / .com): Uses Cloudflare TLSv1.3 + X25519MLKEM768.
  2. Your personal Bitwarden vault: Encrypts entries locally on your device with symmetric AES-256-CBC + HMAC-SHA256. Just remember to switch your KDF setting in Bitwarden from older PBKDF2 to Argon2id (64 MiB memory, 3 iterations, 4 parallelism). Since no RSA or ECC wraps your personal vault key, Shor’s algorithm has nothing to break.
  3. Shared Organizations & Collections (The Trap): As soon as you put an item into a Bitwarden Organization, a Shared Family/Team Collection, or turn on Emergency Access, Bitwarden protects that shared key with a classic RSA-2048 keypair!

If you save your new post-quantum Age private key inside a shared family collection, you just protected a 2026 post-quantum key with RSA-2048. Keep AGE-SECRET-KEY-PQ-1... strictly in your personal vault (with Argon2id turned on) or in an offline KeePassXC database (ChaCha20 / AES-256 + Argon2id) on an encrypted USB stick.


Summary

After two hours of Sunday afternoon work (and zero broken containers), here is the final state across my homelab:

Component Active Post-Quantum Setup Classical curve25519 Downgrade
Unraid 7 NAS (OpenSSH 10.6) mlkem768x25519-sha256 + ssh-mldsa44-ed25519 + chacha20-poly1305 Rejected
MS-01 Docker Host (OpenSSH 9.6p1) sntrup761x25519-sha512@openssh.com + ssh-ed25519 + chacha20-poly1305 Rejected
External Linux VPSes sntrup761x25519-sha512@openssh.com + ssh-ed25519 + chacha20-poly1305 Rejected
Home Assistant OS (OpenSSH 10.3) mlkem768x25519-sha256 + ssh-ed25519 + aes256-gcm Blocked by client config
CachyOS Workstation (~/.ssh/config) PQ-only KEX + ssh-mldsa44-ed25519 first + 256-bit AEAD Enforced
SOPS + Age (66/66 .enc.env files) age1pq1... (mlkem768x25519, NIST FIPS 203) + fresh AES-256-GCM keys Classical X25519 removed
TLS 1.3 (Cloudflare / Pangolin / Traefik) X25519MLKEM768 + AES-256-GCM / ChaCha20-Poly1305 TLS 1.3 only
Backups (Kopia) AES256-GCM-HMAC-SHA256 + BLAKE2B-256-128 256-bit symmetric

The only non-PQ piece left in the whole setup is the internal WireGuard tunnel (Curve25519) between my cloud Pangolin node and the Newt container at home. WireGuard has a PresharedKey option that can be rotated with a post-quantum helper like Rosenpass, so testing Rosenpass alongside Pangolin is on my winter weekend list.

Until then, if Santa’s elves show up tonight with a 4,000-qubit quantum computer on the sleigh, my 66 .enc.env files are safe :D Happy Mikołajki, and if you haven’t joined yet, our 20th Anniversary EUR 200 Giveaway & Open Source Grant is open until December 18!

Written from personal dictation & experience, edited with AI pair-programming tools.
Built with Hugo · Cookie & Privacy Policy
Theme Stack designed by Jimmy