CVE-2026-40188: CWE-1314: Missing Write Protection for Parametric Data Values in patrickhener goshs
goshs is a SimpleHTTPServer written in Go. From 1.0.7 to before 2.0.0-beta.4, the SFTP command rename sanitizes only the source path and not the destination, so it is possible to write outside of the root directory of the SFTP. This vulnerability is fixed in 2.0.0-beta.4.
AI Analysis
Technical Summary
The vulnerability CVE-2026-40188 in patrickhener's goshs (versions >=1.0.7 and <2.0.0-beta.4) is due to insufficient sanitization of the destination path in the SFTP rename command. While the source path is sanitized, the destination path is not, enabling an attacker with privileges to rename files to locations outside the SFTP root directory. This can result in unauthorized file writes and potential integrity violations. The flaw is categorized under CWE-1314 (Missing Write Protection for Parametric Data Values). The issue is resolved in version 2.0.0-beta.4.
Potential Impact
An attacker with privileges to use the SFTP rename command can write files outside the designated root directory, potentially overwriting or creating files in unauthorized locations. This compromises file integrity but does not directly impact confidentiality or availability according to the CVSS vector. The vulnerability requires privileges and has a low attack complexity, making it a significant risk in environments where users have SFTP access.
Mitigation Recommendations
Upgrade goshs to version 2.0.0-beta.4 or later, where the vulnerability is fixed. Since no official patch link or advisory is provided, users should verify the version in use and apply the update accordingly. Patch status is not explicitly confirmed beyond the version fix indication; therefore, check the vendor repository or official sources for the latest remediation guidance.
CVE-2026-40188: CWE-1314: Missing Write Protection for Parametric Data Values in patrickhener goshs
Description
goshs is a SimpleHTTPServer written in Go. From 1.0.7 to before 2.0.0-beta.4, the SFTP command rename sanitizes only the source path and not the destination, so it is possible to write outside of the root directory of the SFTP. This vulnerability is fixed in 2.0.0-beta.4.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability CVE-2026-40188 in patrickhener's goshs (versions >=1.0.7 and <2.0.0-beta.4) is due to insufficient sanitization of the destination path in the SFTP rename command. While the source path is sanitized, the destination path is not, enabling an attacker with privileges to rename files to locations outside the SFTP root directory. This can result in unauthorized file writes and potential integrity violations. The flaw is categorized under CWE-1314 (Missing Write Protection for Parametric Data Values). The issue is resolved in version 2.0.0-beta.4.
Potential Impact
An attacker with privileges to use the SFTP rename command can write files outside the designated root directory, potentially overwriting or creating files in unauthorized locations. This compromises file integrity but does not directly impact confidentiality or availability according to the CVSS vector. The vulnerability requires privileges and has a low attack complexity, making it a significant risk in environments where users have SFTP access.
Mitigation Recommendations
Upgrade goshs to version 2.0.0-beta.4 or later, where the vulnerability is fixed. Since no official patch link or advisory is provided, users should verify the version in use and apply the update accordingly. Patch status is not explicitly confirmed beyond the version fix indication; therefore, check the vendor repository or official sources for the latest remediation guidance.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-04-09T20:59:17.620Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 69d9581c1cc7ad14dae48c7b
Added to database: 4/10/2026, 8:05:48 PM
Last enriched: 4/18/2026, 2:36:42 PM
Last updated: 5/25/2026, 7:01:52 PM
Views: 92
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.