CVE-2025-0913: CWE-59: Improper Link Resolution Before File Access ('Link Following') in Go standard library syscall
CVE-2025-0913 is a vulnerability in the Go standard library syscall package related to improper link resolution before file access. The os.OpenFile function behaved inconsistently between Unix and Windows when handling dangling symbolic links with the O_CREATE and O_EXCL flags. On Unix, it did not follow symlinks, but on Windows, it created a file at the symlink's nonexistent target location. The issue is now fixed so that OpenFile returns an error when both flags are set and the target path is a symlink.
AI Analysis
Technical Summary
This vulnerability involves inconsistent behavior in the Go standard library's syscall package's os.OpenFile function when opening files with the O_CREATE and O_EXCL flags set. Specifically, on Unix systems, OpenFile does not follow dangling symbolic links, preventing file creation at the symlink target. However, on Windows systems, OpenFile would follow a dangling symlink and create a file at the nonexistent target location, potentially leading to unintended file creation or manipulation. The fix ensures that OpenFile returns an error if both O_CREATE and O_EXCL are set and the target path is a symlink, aligning behavior across platforms and preventing this improper link resolution.
Potential Impact
The vulnerability allows for unintended file creation on Windows systems when opening a file path that is a dangling symlink with O_CREATE and O_EXCL flags. This could lead to improper file manipulation or security bypass scenarios where an attacker might exploit the symlink behavior to influence file creation. The CVSS score of 5.5 indicates a medium severity with a local attack vector, low complexity, requiring low privileges, no user interaction, unchanged scope, no confidentiality impact, but high integrity impact and no availability impact.
Mitigation Recommendations
No official patch links are provided in the data, and patch status is not explicitly confirmed. Therefore, patch status is not yet confirmed — check the Go project vendor advisory for current remediation guidance. Users should avoid relying on os.OpenFile with O_CREATE and O_EXCL flags on Windows for paths that may be symlinks until an official fix is confirmed.
CVE-2025-0913: CWE-59: Improper Link Resolution Before File Access ('Link Following') in Go standard library syscall
Description
CVE-2025-0913 is a vulnerability in the Go standard library syscall package related to improper link resolution before file access. The os.OpenFile function behaved inconsistently between Unix and Windows when handling dangling symbolic links with the O_CREATE and O_EXCL flags. On Unix, it did not follow symlinks, but on Windows, it created a file at the symlink's nonexistent target location. The issue is now fixed so that OpenFile returns an error when both flags are set and the target path is a symlink.
CVSS v3.1
Score 5.5medium
Affected software
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
This vulnerability involves inconsistent behavior in the Go standard library's syscall package's os.OpenFile function when opening files with the O_CREATE and O_EXCL flags set. Specifically, on Unix systems, OpenFile does not follow dangling symbolic links, preventing file creation at the symlink target. However, on Windows systems, OpenFile would follow a dangling symlink and create a file at the nonexistent target location, potentially leading to unintended file creation or manipulation. The fix ensures that OpenFile returns an error if both O_CREATE and O_EXCL are set and the target path is a symlink, aligning behavior across platforms and preventing this improper link resolution.
Potential Impact
The vulnerability allows for unintended file creation on Windows systems when opening a file path that is a dangling symlink with O_CREATE and O_EXCL flags. This could lead to improper file manipulation or security bypass scenarios where an attacker might exploit the symlink behavior to influence file creation. The CVSS score of 5.5 indicates a medium severity with a local attack vector, low complexity, requiring low privileges, no user interaction, unchanged scope, no confidentiality impact, but high integrity impact and no availability impact.
Mitigation Recommendations
No official patch links are provided in the data, and patch status is not explicitly confirmed. Therefore, patch status is not yet confirmed — check the Go project vendor advisory for current remediation guidance. Users should avoid relying on os.OpenFile with O_CREATE and O_EXCL flags on Windows for paths that may be symlinks until an official fix is confirmed.
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- Go
- Date Reserved
- 2025-01-30T21:52:33.447Z
- State
- PUBLISHED
Threat ID: 6849bbac23110031d410557b
Added to database: 06/11/2025, 17:23:56 UTC
Last enriched: 09/09/2026, 13:46:06 UTC
Last updated: 09/10/2026, 19:36:49 UTC
Views: 561
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.