CVE-2026-126644Ansible.posix: authorized_key module follows a parent-directory symlink allowing writes…
A link-following flaw was found in the authorized_key module of the ansible.posix collection, residual to the fix for CVE-2026-11837. That fix guards only the final path component (os.chown with follow_symlinks=False and O_NOFOLLOW in _safe_open_write()). When an unprivileged local user replaces their ~/.ssh directory with a symlink to a directory they do not own, and an operator subsequently runs the authorized_key task as root (a common provisioning pattern), the module resolves its path operations through the symlink: atomic_move() writes the temporary file in the symlink target and renames it to <target>/authorized_keys, creating or overwriting a file in the attacker-chosen directory, and os.chmod(sshdir, 0o700) follows the symlink and changes the target directory's permissions. The written file is chowned to the unprivileged user, so this is not a privilege escalation, but it allows an attacker to create or overwrite files (for example in /etc/apt/apt.conf.d/, which APT reads regardless of file ownership) to cause integrity and availability impacts.
What to do
Debian, Red Hat, Ubuntu have not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 26.10 | ansible | Fix pending | UBUNTU-CVE-2026-126644 | |
| Ubuntu 26.10 | ansible-core | Fix pending | UBUNTU-CVE-2026-126644 | |
| Ubuntu 26.04 | ansible | Under investigation | UBUNTU-CVE-2026-126644 | |
| Ubuntu 26.04 | ansible-core | Under investigation | UBUNTU-CVE-2026-126644 | |
| Ubuntu 24.04 | ansible | Under investigation | UBUNTU-CVE-2026-126644 | |
| Ubuntu 24.04 | ansible-core | Under investigation | UBUNTU-CVE-2026-126644 | |
| Ubuntu 22.04 | ansible | Fix pending | UBUNTU-CVE-2026-126644 | |
| Ubuntu 22.04 | ansible-core | Under investigation | UBUNTU-CVE-2026-126644 | |
| Ubuntu 20.04 | ansible | Fix pending | UBUNTU-CVE-2026-126644 | |
| Ubuntu 18.04 | ansible | Fix pending | UBUNTU-CVE-2026-126644 | |
| Ubuntu 16.04 | ansible | Fix pending | UBUNTU-CVE-2026-126644 | |
| Ubuntu 14.04 | ansible | Fix pending | UBUNTU-CVE-2026-126644 | |
| Debian 14 | ansible | Fix pending | DEBIAN-CVE-2026-126644 | |
| Debian 13 | ansible | Fix pending | DEBIAN-CVE-2026-126644 | |
| Debian 12 | ansible | Fix pending | DEBIAN-CVE-2026-126644 | |
| Red Hat Enterprise Linux 10 | rhc-worker-playbook | Fix pending Fix deferred | ||
| Red Hat Enterprise Linux 9 | rhc-worker-playbook | Fix pending Fix deferred |
What the vendor says
As published in the CVE record by redhat, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- Red Hat Enterprise Linux 10
- Red Hat Enterprise Linux 9
Workaround: Do not run ansible.posix.authorized_key as root against home or .ssh directories that unprivileged users can modify. Verify that target directories are not attacker-controllable symlinks before running the task.
References
- https://access.redhat.com/security/cve/CVE-2026-126644
- https://bugzilla.redhat.com/show_bug.cgi?id=2571732
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.