shirudo Lab: signed BPF, TPM-measured Playground
Hands-on lab for shirudo, a BPF-based security platform: sign and load upatches, watch tampering get refused, verify the target with its TPM.

- eth0
- /
- ubuntu-26-04
shirudo lab
shirudo is a BPF-based security platform: targets run only the BPF their operator signed, every change is measured into the TPM, and functionality ships as signed upatches.
This machine is the operator. The target is a test VM (bpf-next kernel, BPF LSM, software TPM) that runs inside it under QEMU.
iximiuz playgrounds have no
/dev/kvm, so the target runs under QEMU TCG (software emulation). Expect the firstshirudo-lab targetto take a while.
0. Prepare (once per playground)
shirudo-lab setup # packages + clang/LLVM 23
shirudo-lab build # test kernel, shirudo, shirudo-build
shirudo-lab target # boot the protected target ("VM ready")
shirudo-lab shell # operator shell: shirudo on PATH, $KEYS set
Run target commands with shirudo-lab ssh (interactive) or
shirudo-lab run '<cmd>'.
1. The protected target
shirudo-lab run '/usr/local/bin/shirudo status' # copy of the binary: Permission denied
shirudo-lab run 'shirudo status' # trusted runtime binary: Status: ok
shirudo-lab run 'cat /run/shirudo/bpffs/tamper' # root without runtime authority: denied
shirudo-lab run "shirudo status | sed -n '/^Tamper attempts/,/^$/p'" # ObjGet counted
2. Life of a upatch (in shirudo-lab shell)
shirudo build testing/fixtures/basic.bpf.c --keys-dir "$KEYS" --vmlinux vendor/linux/vmlinux.h -o basic.upatch
PAYLOAD=$(shirudo upatch info --json basic.upatch | jq -r .payload_sha256)
shirudo build --unload basic --payload-sha256 "$PAYLOAD" --keys-dir "$KEYS" -o basic.unload.upatch
shirudo-lab run 'shirudo upatch load basic.upatch' # signature checked, load measured
shirudo-lab run 'shirudo upatch list'
shirudo-lab run 'shirudo upatch unload basic.unload.upatch'
3. Attacker's view
shirudo genkey --keys-dir build/lab/attacker-keys
shirudo build testing/fixtures/basic.bpf.c --keys-dir build/lab/attacker-keys --vmlinux vendor/linux/vmlinux.h --name evil -o build/lab/evil.upatch
shirudo-lab run 'shirudo upatch load /workspace/shirudo/build/lab/evil.upatch' # refused: key not in .bpf keyring
cp basic.upatch build/lab/tampered.upatch
python3 -c "import sys;p=sys.argv[1];b=bytearray(open(p,'rb').read());b[-16]^=255;open(p,'wb').write(b)" build/lab/tampered.upatch
shirudo-lab run 'shirudo upatch load /workspace/shirudo/build/lab/tampered.upatch' # refused: signature broken
4. Verify with the TPM
NONCE=$(openssl rand -hex 32)
shirudo-lab run "shirudo attest --nonce=$NONCE --output=/mnt/shirudo-out/ev.json"
EV=build/test-vm/vms/quickstart/result/ev.json
OWN=build/test-vm/host-bundle-bpf-next-verity/fixtures/own.der
shirudo attest verify --evidence="$EV" --nonce="$NONCE" --ak-name="$(jq -r .ak.name "$EV")" \
--cert="$KEYS/cert.der" --cert="$OWN" --allow-runtime-events # verdict: ok
More: Quickstart · Quick guides
A real VM, not a container
Get root on a VM with its own kernel, so Docker, Kubernetes, and systemd just work.
Read the docs →
SSH from browser or CLI
Use the built-in web terminal, or connect with labctl ssh, plain ssh, scp, or rsync.
Read the docs →
Drive it with AI
Let Claude, Codex, or any MCP client start this playground and run commands in it.
Read the docs →
Expose HTTP(S) ports
Give any web app running inside the VM a public URL - for yourself or to share with others.
Read the docs →
Share terminals
Invite others into your terminal session, or open it yourself from another device.
Read the docs →
Customize with init scripts
Add shell scripts that run at boot to install packages, clone repos, or seed test data.
Read the docs →
Private networking
VMs reach the internet via NAT with no public IP; several VMs share bridge networks.
Read the docs →
Ephemeral or persistent
By default, VMs are destroyed when the session ends; enable persistence to keep the disks for next time.
Read the docs →
Built-in container registry
A private registry.iximiuz.com for every playground to share images across services and VMs.
Read the docs →