Public vulnerability disclosure

CVE-2026-126644

Ansible.posix: authorized_key module follows a parent-directory symlink allowing writes outside the intended directory

publishedCWE-59

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.

Technical severity3.9 lowCVSS 3.1 · CNA: redhat
Published2026-11-12Source updated 2026-11-12
Collected2026-11-121 attributed source

Fixes and workarounds

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.

Source: CNA: redhat

Affected products and versions

Affected products, source version ranges and reporting authorities
ProductVersionsAuthority
Red Hat Enterprise Linux 10
Red Hat
rhc-worker-playbook
https://access.redhat.com/downloads/content/package-browser/
Range not reported
Other versions: affected
CNA: redhat
Red Hat Enterprise Linux 9
Red Hat
rhc-worker-playbook
https://access.redhat.com/downloads/content/package-browser/
Range not reported
Other versions: affected
CNA: redhat

Version ranges are source assertions. Check the vendor advisory and your installed configuration before determining exposure.

CVSS assessments

CVSS scores, vectors and reporting authorities
Version / scoreVectorAuthority
3.1 / 3.9
low
CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:N/I:L/A:LCNA: redhat

Exploit evidence

No exploit evidence in collected sources. This is not proof of no exploitation.

References

For agents and automation

Read public disclosures for free as Markdown or JSON. Compatible browsers also expose native WebMCP tools to search disclosures, read this page, and discover API access.

Use the ontology-linked Cyber API with x402 pay per request, or a Y2 Pro or Elite API key with the intel:cyber scope.

Endpoints and access details

https://api.y2.dev/api/v2/cyber/cves
https://api.y2.dev/api/v2/cyber/cves/{cveId}

A workspace owner or admin can create a Pro or Elite API key. Send Authorization: Bearer <Y2_API_KEY> from your trusted agent runtime.

For x402, omit Authorization and read the HTTP 402 payment challenge before signing a retry. Public browser tools do not make payments.

Agent access JSON · OpenAPI · CVE API guide