freenode
Databases & Infrastructure

QEMU guest agent fixes root symlink flaw in SSH key commands

CVE-2026-12080 let unprivileged local users seize ownership of arbitrary root files when the agent added authorized keys.

QEMU has patched a privilege-escalation bug in the guest agent that let an unprivileged local user obtain root access through the guest-ssh-add-authorized-keys command.

CVE-2026-12080 arises because the agent, running as root, tested and created the target user's .ssh directory and authorized_keys file while following symbolic links. A user who controlled their own home directory could pre-place a symlink so that the agent would chown an arbitrary root-owned file or directory to them; the user could then rewrite that object and escalate.

Kostiantyn Kostiuk's fix changes the agent's effective user and group IDs to those of the target account before performing the directory and file operations, so the work runs with the user's own privileges rather than root's. The daemon now fails closed if it cannot restore its original credentials afterward. The issue was reported by Valentino Paulon.