CVE-2026-49340: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in sentriz gonic
gonic is a music streaming server / free-software subsonic server API implementation. Prior to version 0.21.0, a logic error in `ServeCreateOrUpdatePlaylist` allows any authenticated Subsonic user (including non-admin) to write playlist M3U content to an attacker-controlled absolute filesystem path on the gonic host, and to create intermediate directories with `0o777` permissions. The bug is independent of CVE-2026-49338 and CVE-2026-49339. It is an unreachable guard clause combined with no path containment in `Store.Write`. Version 0.21.0 patches the issue.
AI Analysis
Technical Summary
The vulnerability CVE-2026-49340 affects sentriz gonic versions before 0.21.0. It is caused by improper limitation of a pathname to a restricted directory (CWE-22) due to a logic error in the ServeCreateOrUpdatePlaylist function. Authenticated users can exploit this to write playlist files to arbitrary absolute paths on the server filesystem and create directories with insecure permissions (0o777). This occurs because a guard clause intended to prevent such writes is unreachable, and the Store.Write method does not enforce path containment. This vulnerability is distinct from CVE-2026-49338 and CVE-2026-49339. The issue is fixed in version 0.21.0.
Potential Impact
Exploitation allows any authenticated Subsonic user to write arbitrary playlist M3U content to any absolute filesystem path on the gonic host, potentially overwriting or creating files outside intended directories. Additionally, attackers can create intermediate directories with full permissions (0o777), increasing the risk of unauthorized file access or modification. This can lead to integrity and availability impacts on the host system. Confidentiality impact is not indicated. The CVSS v3.1 score is 8.1 (High), reflecting network attack vector, low attack complexity, low privileges required, no user interaction, unchanged scope, no confidentiality impact, but high integrity and availability impacts.
Mitigation Recommendations
A fix is available in sentriz gonic version 0.21.0, which patches this path traversal vulnerability. Users should upgrade to version 0.21.0 or later to remediate this issue. No other mitigation or temporary workaround is indicated in the available data.
CVE-2026-49340: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in sentriz gonic
Description
gonic is a music streaming server / free-software subsonic server API implementation. Prior to version 0.21.0, a logic error in `ServeCreateOrUpdatePlaylist` allows any authenticated Subsonic user (including non-admin) to write playlist M3U content to an attacker-controlled absolute filesystem path on the gonic host, and to create intermediate directories with `0o777` permissions. The bug is independent of CVE-2026-49338 and CVE-2026-49339. It is an unreachable guard clause combined with no path containment in `Store.Write`. Version 0.21.0 patches the issue.
CVSS v3.1
Score 8.1high
Affected software
pkg:golang/github.com/sentriz/gonicRun on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability CVE-2026-49340 affects sentriz gonic versions before 0.21.0. It is caused by improper limitation of a pathname to a restricted directory (CWE-22) due to a logic error in the ServeCreateOrUpdatePlaylist function. Authenticated users can exploit this to write playlist files to arbitrary absolute paths on the server filesystem and create directories with insecure permissions (0o777). This occurs because a guard clause intended to prevent such writes is unreachable, and the Store.Write method does not enforce path containment. This vulnerability is distinct from CVE-2026-49338 and CVE-2026-49339. The issue is fixed in version 0.21.0.
Potential Impact
Exploitation allows any authenticated Subsonic user to write arbitrary playlist M3U content to any absolute filesystem path on the gonic host, potentially overwriting or creating files outside intended directories. Additionally, attackers can create intermediate directories with full permissions (0o777), increasing the risk of unauthorized file access or modification. This can lead to integrity and availability impacts on the host system. Confidentiality impact is not indicated. The CVSS v3.1 score is 8.1 (High), reflecting network attack vector, low attack complexity, low privileges required, no user interaction, unchanged scope, no confidentiality impact, but high integrity and availability impacts.
Mitigation Recommendations
A fix is available in sentriz gonic version 0.21.0, which patches this path traversal vulnerability. Users should upgrade to version 0.21.0 or later to remediate this issue. No other mitigation or temporary workaround is indicated in the available data.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-05-29T14:35:45.902Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a35966af198dc38c113831a
Added to database: 6/19/2026, 7:20:10 PM
Last enriched: 6/19/2026, 7:35:02 PM
Last updated: 6/20/2026, 12:06:54 AM
Views: 7
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.
External Links
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.