Skip to main content

CVE-2024-12087: Path Traversal: '.../...//'

Medium
VulnerabilityCVE-2024-12087cvecve-2024-12087
Published: Tue Jan 14 2025 (01/14/2025, 17:57:33 UTC)
Source: CVE

Description

A path traversal vulnerability exists in rsync. It stems from behavior enabled by the `--inc-recursive` option, a default-enabled option for many client options and can be enabled by the server even if not explicitly enabled by the client. When using the `--inc-recursive` option, a lack of proper symlink verification coupled with deduplication checks occurring on a per-file-list basis could allow a server to write files outside of the client's intended destination directory. A malicious server could write malicious files to arbitrary locations named after valid directories/paths on the client.

AI-Powered Analysis

AILast updated: 07/03/2025, 18:11:22 UTC

Technical Analysis

CVE-2024-12087 is a path traversal vulnerability found in the rsync utility, specifically related to the use of the `--inc-recursive` option. Rsync is a widely used tool for file synchronization and transfer, often employed for backups and mirroring. The vulnerability arises because the `--inc-recursive` option, which is enabled by default for many client options and can be activated by the server even if the client does not explicitly enable it, does not properly verify symbolic links. Additionally, deduplication checks are performed on a per-file-list basis rather than globally. This combination allows a malicious rsync server to exploit the client by writing files outside the intended destination directory on the client machine. Essentially, the server can craft file paths that traverse directories (using sequences like `.../...//`) to place files arbitrarily on the client system, potentially overwriting or injecting malicious files in critical locations. The vulnerability does not require authentication (PR:N) but does require user interaction (UI:R), such as initiating an rsync session with a malicious server. The CVSS 3.1 score is 6.5 (medium severity), reflecting that while confidentiality is not impacted, integrity can be severely compromised, and availability is unaffected. No known exploits are currently reported in the wild, but the potential for malicious file injection could lead to significant integrity breaches, including code execution if the injected files are executed or loaded by the client system. This vulnerability is particularly concerning because rsync is commonly used in automated backup and synchronization workflows, and the default enabling of the vulnerable option increases the attack surface.

Potential Impact

For European organizations, the impact of CVE-2024-12087 can be significant, especially for those relying on rsync for backup, file synchronization, or deployment processes. A successful exploitation could allow attackers controlling a malicious rsync server to write arbitrary files outside the expected directories on client machines. This can lead to unauthorized modification or insertion of malicious files, potentially enabling further compromise such as privilege escalation, persistence, or lateral movement within the network. Critical infrastructure, government agencies, financial institutions, and enterprises with automated backup systems using rsync are at risk. The integrity of data and systems could be undermined, leading to operational disruptions or data corruption. Since the vulnerability does not affect confidentiality directly, data leakage is less of a concern; however, the integrity impact is severe enough to warrant urgent attention. The requirement for user interaction (initiating rsync with a malicious server) means that targeted phishing or social engineering could be used to trick users into connecting to compromised or attacker-controlled servers. This risk is amplified in environments where rsync is used with external or third-party servers.

Mitigation Recommendations

To mitigate CVE-2024-12087, European organizations should take the following specific actions: 1) Immediately review and update rsync clients to the latest patched versions once available from trusted vendors or upstream sources. 2) Audit and restrict rsync usage policies to avoid connections to untrusted or unknown servers, especially those that might enable the `--inc-recursive` option implicitly. 3) Disable or explicitly avoid using the `--inc-recursive` option in client configurations unless absolutely necessary and verified safe. 4) Implement strict network controls and firewall rules to limit rsync traffic to known, trusted servers only. 5) Monitor rsync logs for unusual file write patterns or unexpected directory traversals indicative of exploitation attempts. 6) Employ file integrity monitoring on client systems to detect unauthorized file modifications or additions outside expected directories. 7) Educate users and administrators about the risks of connecting to untrusted rsync servers and the importance of verifying server authenticity. 8) Consider alternative secure file transfer methods that do not have this vulnerability or that provide stronger server authentication and path validation. These targeted mitigations go beyond generic advice by focusing on configuration, network controls, monitoring, and user awareness specific to the nature of this vulnerability.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
redhat
Date Reserved
2024-12-03T08:58:04.170Z
Cisa Enriched
true
Cvss Version
3.1
State
PUBLISHED

Threat ID: 682d9816c4522896dcbd6699

Added to database: 5/21/2025, 9:08:38 AM

Last enriched: 7/3/2025, 6:11:22 PM

Last updated: 8/16/2025, 10:23:10 PM

Views: 11

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats