Red Hat
Ansible-collection-ansible-posix: ansible.posix authorized_key: local privilege escalation via symlink-following chown
A local privilege escalation vulnerability was found in the ansible.posix authorized_key module. The module's keyfile() function uses os.chown() instead of os.lchown() and opens files without O_NOFOLLOW when managing SSH authorized keys. An unprivileged local user can pre-stage symbolic links in their ~/.ssh directory to redirect file ownership changes to arbitrary system paths when an operator runs the authorized_key task as root, leading to local privilege escalation.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
Fixed in 0:0.2.10-1.el10_2
Fixed in 0:0.2.3-6.el10_0.2
Fixed in 0:0.1.8-2.el8_6.1
Fixed in 0:0.1.8-2.el8_6.1
Fixed in 0:0.1.8-5.el8_8.1
Fixed in 0:0.1.8-5.el8_8.1
Mitigation
Upgrade Red Hat Enterprise Linux 10 to 0:0.2.10-1.el10_2 or later.
Upgrade Red Hat Enterprise Linux 10.0 Extended Update Support to 0:0.2.3-6.el10_0.2 or later.
Upgrade Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Support to 0:0.1.8-2.el8_6.1 or later.
Upgrade Red Hat Enterprise Linux 8.6 Extended Update Support Long-Life Add-On to 0:0.1.8-2.el8_6.1 or later.
Upgrade Red Hat Enterprise Linux 8.8 Telecommunications Update Service to 0:0.1.8-5.el8_8.1 or later.
Upgrade Red Hat Enterprise Linux 8.8 Update Services for SAP Solutions to 0:0.1.8-5.el8_8.1 or later.
Workaround
The following practices would help for avoiding exposure and mitigate this flaw: 1) Do not run the ansible.posix authorized_key module with elevated privileges against untrusted user accounts. 2) Validate that target user home directories do not contain unexpected symbolic links before running playbooks.
References
- Vendor advisory access.redhat.com/errata/RHSA-2026:42946
- Vendor advisory access.redhat.com/errata/RHSA-2026:79112
- Vendor advisory access.redhat.com/errata/RHSA-2026:80508
1 more
- Vendor advisory access.redhat.com/errata/RHSA-2026:82339
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.1 informational
Informational 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| M8seven/cve-2026-11837-ansible-posix-authorized-key | 23 Jun 2026 +13 d | 1 | Informational · write-up |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.