CAPEC-27: Leveraging Race Conditions via Symbolic Links

ID CAPEC-27
Typical Severity High
Likelihood Of Attack Medium
Status Draft

This attack leverages the use of symbolic links (Symlinks) in order to write to sensitive files. An attacker can create a Symlink link to a target file not otherwise accessible to them. When the privileged program tries to create a temporary file with the same name as the Symlink link, it will actually write to the target file pointed to by the attackers' Symlink link. If the attacker can insert malicious content in the temporary file they will be writing to the sensitive file by using the Symlink. The race occurs because the system checks if the temporary file exists, then creates the file. The attacker would typically create the Symlink during the interval between the check and the creation of the temporary file.

https://capec.mitre.org/data/definitions/27.html

Weaknesses

# ID Name Type
CWE-61 UNIX Symbolic Link (Symlink) Following weakness
CWE-367 Time-of-check Time-of-use (TOCTOU) Race Condition weakness
CWE-662 Improper Synchronization weakness
CWE-667 Improper Locking weakness
CWE-689 Permission Race Condition During Resource Copy weakness
Loading...