DocsMeasured boot
Measured boot
A Blackbox VM with measured boot never boots from its own disk. The firmware, the kernel, the initramfs that asks for your passphrase and the command line that carries your SSH key are all part of the AMD SEV-SNP launch measurement, and every one of them is rebuilt byte for byte from public sources. This page explains how to check.
1. The hole this closes
SEV-SNP encrypts a VM's memory with a key the host never holds, and the CPU signs a launch measurement: a hash of everything loaded into the VM before it started. On an ordinary confidential VM that "everything" is the firmware and nothing else. The bootloader, the kernel and the initramfs live on the guest's own unencrypted /boot partition, which the host can rewrite whenever it likes. The initramfs is the program that asks for your LUKS passphrase. A host that swaps it for one that also emails the passphrase home has defeated the disk encryption without touching encrypted memory. Confidential VPS hosting is usually set up this way, and ours was until this release.
Measured boot removes the guest's disk from the boot path entirely. QEMU hands the firmware a kernel, an initramfs and a command line over fw_cfg with kernel-hashes=on; their SHA-256 hashes are written into a page that is part of the launch measurement, and the firmware is the AmdSevX64 build of OVMF, the one build that refuses to run a blob whose hash is not in that page and that cannot boot from disk at all. The host fills the page at launch, so the firmware check alone proves nothing to you. The proof is that the page is measured and the CPU signs the measurement. If one byte of the initramfs changes, the launch measurement changes and the CPU-signed report shows it; the host cannot produce the published number from anything but the published bytes. If nothing changes, the measurement is a number you can compute at home.
2. What is measured
- Firmware:
OVMF.amdsev.fd, built from edk2OvmfPkg/AmdSev/AmdSevX64.dscat a pinned tag with a pinned Debian toolchain. - Kernel:
vmlinuz, extracted unmodified from Debian's signedlinux-imagepackage. The package hash is in the release manifest; fetch the same package from snapshot.debian.org and compare. - Initramfs:
initrd.img, built withmkinitramfsfrom packages pinned to one snapshot.debian.org timestamp plus the scripts in the source tree. Two builds give identical bytes. - Command line: the exact string shown on your server's panel. It carries
cryptopts=(where the LUKS root is),ip=, andbb.*parameters: your SSH public key, your addresses, your hostname and the instance id. Because it is measured, nobody can add a key to it without changing the number you check. That is also why a measured server takes exactly one SSH key: order it with the one you will log in with. - vCPU state: one initial register file per vCPU, so the count matters; the panel states it.
- Guest policy:
0x30000: SMT allowed, debugging off, no migration agent. The verifier rejects anything else.
Your root filesystem is deliberately not measured; it is encrypted with a passphrase we never see. No seed ISO is attached to a measured VM at all; the initramfs writes the cloud-init seed from the measured command line.
3. How the initramfs proves itself
The initramfs is public and identical for every customer, so it cannot carry an SSH host key. On the first boot it generates an ed25519 key and keeps it for the life of the machine, stored on the disk's unused second partition and sealed with an SEV-SNP derived key: a key the AMD security processor derives from this chip, the launch measurement and the guest policy, and hands only to the guest itself. Nothing outside the VM can open it, and neither can a VM with a different release, command line or chip; in those cases a new key is made in its place. On every boot the initramfs requests an SNP attestation report from the CPU with REPORT_DATA set to the SHA-256 of that key, and serves the report in the SSH banner and through the attest command. OpenSSH shows you that same SHA-256 as the host key fingerprint. If the report's signature chains to AMD's root, its measurement equals the one you computed, and its REPORT_DATA equals the fingerprint your client just displayed, then the machine holding that key is a genuine SNP guest running exactly this image, and nothing in between can read what you type into it.
The booted system serves the same host key, so your SSH client sees one key for the machine, at the unlock prompt and after it, across reboots. It changes only with a new release, an address change or a move to another machine, and your client then warns you once. (Release 2026.09 and earlier made a new key on every boot.)
Every SSH login into the initramfs lands in a forced command with four verbs: attest (the report and its context as JSON), report (the raw report), unlock and encrypt. A plain ssh root@YOUR.VM.IP picks the right one: encrypt on the first boot, unlock after that. Password logins are disabled at build time; the only key allowed in is the one on the measured command line.
4. Verify before the passphrase
On your own computer, never on the server: any machine with Python 3, OpenSSH and internet access will do (the verifier fetches your VM's VCEK certificate from AMD's key server). The server is locked in its initramfs until this passes and you send the passphrase over SSH.
pip install sev-snp-measure cryptography curl -sSO https://servury.com/downloads/blackbox/blackbox-verify REL=2026.11.3 mkdir $REL && cd $REL for f in OVMF.amdsev.fd vmlinuz initrd.img RELEASE.json SHA256SUMS; do curl -sSO https://servury.com/downloads/blackbox/$REL/$f; done sha256sum -c SHA256SUMS && cd .. python3 blackbox-verify --host YOUR.VM.IP --release ./$REL --vcpus 2
The verifier fetches the attestation over SSH with a throwaway known-hosts file, keyscans the host key itself, parses the report, checks the policy, checks that REPORT_DATA is the SHA-256 of the key on the wire, recomputes the launch measurement from the release directory and the command line the VM reports, and verifies the ECDSA P-384 signature against the VCEK certificate chained to AMD's ASK and ARK. It prints PASS and a known_hosts line you can pin (from release 2026.11 on it stays valid across reboots), or FAIL with the reason. On FAIL, do not type a passphrase: the VM is not what it claims to be. Please report it to us.
Nothing here relies on the panel. The panel shows the expected measurement and the command line for convenience, but the verifier computes both from what you downloaded and what the VM reported. The only input you take from us is the vCPU count: --vcpus is your plan's number, 2 on Core as in the example above and 1 on Nano. A wrong value can only make the check fail.
If you script this yourself: the firmware's kernel loader appends initrd=initrd to what the guest sees in /proc/cmdline. The hash in the measurement covers the command line as QEMU passed it, without that suffix, and the verifier strips it.
By hand, without the tool: sev-snp-measure --mode snp --vcpus N --vcpu-type EPYC-v4 --guest-features 0x1 --ovmf OVMF.amdsev.fd --kernel vmlinuz --initrd initrd.img --append '<command line>' must print the measurement field of the report, and snpguest verify or any other SNP report verifier checks the signature.
5. First boot: encrypt
A measured VM boots straight into the initramfs and waits. Nothing from its disk has run. Verify as above, then:
ssh root@YOUR.VM.IP
The script asks for a passphrase once (and its confirmation), checks the filesystem, shrinks it to make room for the LUKS2 header, encrypts the root partition in place (aes-xts-plain64, 512-bit key, argon2id), grows the partition and the LUKS volume to the whole disk, expands the filesystem, writes crypttab and fstab inside the encrypted root, and then continues the boot into your system with the volume it just opened. Your SSH session stays open: the boot log streams from the kernel's first line, and you land at a root shell on the booted system without reconnecting. The script reports success only if LUKS is actually on disk, restores the filesystem size if anything fails before encryption, and resumes an encryption that a dropped connection interrupted. Keep the passphrase safe: nobody can recover it, including us.
Every later boot stops in the initramfs with the same host key: verify, then ssh root@YOUR.VM.IP, enter the passphrase, and the same connection follows the boot into a root shell. That session stays carried by the initramfs SSH server until you log out, so port and agent forwarding need a fresh connection, which reaches your system's own sshd. If your sshd configuration would not let that key log in as root from your address (root logins off, AllowUsers, a forced command and the like), the session ends when the boot finishes and you connect again as usual, where sshd applies your rules. Once running, the machine is a normal Debian or Ubuntu with your SSH key from the measured command line, its network configured by cloud-init from the seed the initramfs wrote, and a copy of the boot-time report at /run/blackbox/attest.json.
Type the passphrase only over SSH after a PASS. The serial console and the VNC console pass through the host as on any VM. Use them to watch the boot, and do not type secrets into them.
6. Rebuild everything yourself
The source tree for every release is published next to the artifacts (blackbox-images-RELEASE.tar.gz). On any Debian 13 machine with root and mmdebstrap:
tar xzf blackbox-images-$REL.tar.gz && cd blackbox-images sh build/mkchroot.sh # pinned snapshot.debian.org chroot git clone --depth 1 --branch edk2-stable202505 https://github.com/tianocore/edk2 /var/tmp/bb/src/edk2 git -C /var/tmp/bb/src/edk2 submodule update --init --depth 1 --recursive cp build/build-firmware.sh build/build-initramfs.sh /var/tmp/bb/chroot/usr/local/bin/ build/in-chroot.sh sh -c 'apt-get update -qq && cd /out && mkdir -p pkgs && cd pkgs && apt-get download linux-image-KVER' build/in-chroot.sh build-firmware.sh /out/firmware build/in-chroot.sh build-initramfs.sh /out/initramfs sha256sum /out/firmware/OVMF.amdsev.fd /out/initramfs/vmlinuz /out/initramfs/initrd.img
The three hashes must equal the ones in RELEASE.json. The manifest records the snapshot timestamp, the edk2 tag, the kernel package and its hash, and the SOURCE_DATE_EPOCH, which is everything that determines them. A different byte is either a bug in our recipe or evidence against us; report it in both cases.
7. Bring your own image
Rebuilding our release checks that our artifacts match our sources. You can also boot your own instead. On a measured Blackbox you can replace the release kernel, initramfs and command line with files you built, and the machine measures those instead: the expected measurement becomes a function of the public firmware, your bytes and your command line, and nothing of ours runs inside the guest at all.
Two shapes are accepted. A UKI, one PE file with the kernel, the initramfs and the command line inside it, built with ukify or objcopy against the systemd stub; it boots as-is, and the command line you enter in the panel may be left empty so the one in its .cmdline section applies. Or a bzImage with a separate initramfs and the command line typed in the panel. A UKI cannot take a separate initramfs: QEMU refuses one for a kernel without the boot-protocol header.
# a UKI from your own kernel, initramfs and command line
ukify build --linux vmlinuz --initrd initrd.img \
--cmdline 'console=ttyS0,115200 ip=YOUR.IP::GATEWAY:255.255.255.0:host:ens18:off' \
--output blackbox.efi
sha256sum blackbox.efiPut the file on any http(s) server and give the panel its URL and SHA-256 (Manage tab, Boot image). The node downloads it into the machine's own storage, refuses it if the hash differs from what you declared, and re-hashes it at every start before QEMU sees the path. A restart boots your image; Back to the Servury release undoes it. A reinstall always comes back on the release, because it replaces the disk. To script it, the Blackbox API has the same step: ?action=boot-image, then a restart with ?action=power.
Your image has to bring everything the release initramfs used to do: configure the network (the panel lists the addresses; the kernel's ip= syntax on the suggested line is enough for IPv4), fetch and expose an attestation report (/dev/sev-guest, for instance with snpguest report), and decide what to do with the disk, which is untouched: unlock your LUKS volume, write an image of your own over /dev/sda, or ignore it and run from RAM. Verification is the same arithmetic as for our release, with your files:
sev-snp-measure --mode snp --vcpus N --vcpu-type EPYC-v4 --guest-features 0x1 \ --ovmf OVMF.amdsev.fd --kernel blackbox.efi --append ''
The Overview card prints this command filled in for your machine, and our own expected value to compare against. Limits: kernel file up to 1 GiB and at least 128 KiB (QEMU may split up to that much off the front of a non-bzImage file as "setup"; the firmware puts it back), command line up to 4096 bytes, http(s) only. Confidential guests only: the firmware stays the AmdSevX64 build of the release you are on, so its hash is the one number on the card that is still ours, and it is reproducible from section 6.
8. Bring your own disk
The install template and the console you could use for a manual install are both ours, and both could in principle be tampered with. You do not have to use either. Build the disk at home, pre-installed and pre-encrypted, and have the node write it over the machine's disk: Manage tab, Disk image, a URL and a SHA-256. Raw or qcow2 (qcow2 may be internally compressed; archives are not unpacked), up to the plan's disk size, self-contained: a qcow2 that points at a backing file or an external data file is refused, since those are paths on our host.
# a pre-encrypted image, built anywhere: partition, LUKS, install, then ship the whole disk
qemu-img convert -O qcow2 -c blackbox.raw blackbox.qcow2
sha256sum blackbox.qcow2What the node does: downloads the file into the machine's own storage, checks the hash, stops the machine, snapshots and discards the disk (so nothing of the previous contents survives in blocks the image does not cover), writes the image with qemu-img convert, and starts the machine again. If anything fails, the snapshot is rolled back and the disk is exactly as it was. A reinstall replaces the disk with a template again.
With measured boot, pair it with section 7: your UKI carries the initramfs that unlocks your LUKS volume, and the disk it unlocks is the one you wrote. Then the only code that ran on this machine which you did not build is the firmware, whose hash you can reproduce, and the CPU signs a measurement of the rest. Without measured boot the firmware boots the disk's own EFI loader, so an image with its own unlock path (dropbear in the initramfs, for instance) works on its own; the seed CD with your SSH key and addresses stays attached, and a cloud-init image will use it while anything else can ignore it.
9. Releases
2026.11.3 current
Built 2026-11-25. Kernel 6.12.115+deb13.1-amd64 (linux-image-6.12.115+deb13.1-amd64_6.12.115-2_amd64.deb). Firmware edk2-stable202505. Debian snapshot 20261103T000000Z.
- On an encrypted Debian server, apt upgrades no longer stop at the boot loader package (grub-cloud-amd64). The boot stage removes the cloud image's /etc/grub.d/enable_cloud file from the encrypted disk; to keep it, create /etc/grub.d/blackbox-grub.keep.
| OVMF.amdsev.fd | 8731846cdbcbb6aa5c624238b839544b1553f4c5af874450f043321b3ef8958b |
| vmlinuz | 96758c40859c94163e5cf81399a107d679e984e251cb4e13aba4e7d92f5d14f2 |
| initrd.img | 7f795ca29e4b4db5c28df7c50e4a43b295440a6a59855b27d2793f20e69dac8c |
| RELEASE.json | SHA256SUMS · source tree |
2026.11.2
Built 2026-11-09. Kernel 6.12.115+deb13.1-amd64 (linux-image-6.12.115+deb13.1-amd64_6.12.115-2_amd64.deb). Firmware edk2-stable202505. Debian snapshot 20261103T000000Z.
- The unlock prompt answers on IPv6 as well as IPv4.
| OVMF.amdsev.fd | 8731846cdbcbb6aa5c624238b839544b1553f4c5af874450f043321b3ef8958b |
| vmlinuz | 96758c40859c94163e5cf81399a107d679e984e251cb4e13aba4e7d92f5d14f2 |
| initrd.img | f045406ea60e1b24cd4790dccf1bf96b7528b2fd9266b4449277ce9220395092 |
| RELEASE.json | SHA256SUMS · source tree |
2026.11.1
Built 2026-11-03. Kernel 6.12.115+deb13.1-amd64 (linux-image-6.12.115+deb13.1-amd64_6.12.115-2_amd64.deb). Firmware edk2-stable202505. Debian snapshot 20261103T000000Z.
- Kernel 6.12.115: fixes CVE-2026-98432, a remotely reachable use-after-free in IPv4 option handling (CVSS 9.8). Security update.
| OVMF.amdsev.fd | 8731846cdbcbb6aa5c624238b839544b1553f4c5af874450f043321b3ef8958b |
| vmlinuz | 96758c40859c94163e5cf81399a107d679e984e251cb4e13aba4e7d92f5d14f2 |
| initrd.img | 8c2aff57573c4af11289553fa185c8f13613acca688a52c2e579d4ea9c2beaf7 |
| RELEASE.json | SHA256SUMS · source tree |
2026.11
Built 2026-11-02. Kernel 6.12.107+deb13-amd64 (linux-image-6.12.107+deb13-amd64_6.12.107-1_amd64.deb). Firmware edk2-stable202505. Debian snapshot 20260904T000000Z.
- One SSH session from the unlock prompt to a shell on the booted system.
- The SSH host key stays the same across reboots, sealed to this chip and release.
| OVMF.amdsev.fd | 8731846cdbcbb6aa5c624238b839544b1553f4c5af874450f043321b3ef8958b |
| vmlinuz | 2b2358b37674d2505350528875bb17afae2a36522a9e8a9417eaca65a7da0e08 |
| initrd.img | 4e4f01ab05d70e02cbf2fd5b1ee14daf77f5c6c5ed6d110d4f56be9083c42fb6 |
| RELEASE.json | SHA256SUMS · source tree |
2026.09
Built 2026-09-05. Kernel 6.12.107+deb13-amd64 (linux-image-6.12.107+deb13-amd64_6.12.107-1_amd64.deb). Firmware edk2-stable202505. Debian snapshot 20260904T000000Z.
- First release: SEV-SNP measured direct boot with the passphrase prompt in an attested initramfs.
| OVMF.amdsev.fd | 8731846cdbcbb6aa5c624238b839544b1553f4c5af874450f043321b3ef8958b |
| vmlinuz | 2b2358b37674d2505350528875bb17afae2a36522a9e8a9417eaca65a7da0e08 |
| initrd.img | 46689fa645887affb5df1fbc7eb9c7253ea7444cc426e07fe17ab2b7804192e5 |
| RELEASE.json | SHA256SUMS · source tree |
The verifier itself: blackbox-verify (Python, MIT). Send questions, findings and mismatches to support. Our PGP key is at pgp.txt.