Vulnerability · Published May 6, 2025 · Assigned by GitHub_M
CVE-2025-46816goshs route not protected, allows command execution
Critical 9.4
In plain English
A critical-severity improper access control in goshs from patrickhener. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.8% (higher than 55% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.
Official description
goshs is a SimpleHTTPServer written in Go. Starting in version 0.3.4 and prior to version 1.0.5, running goshs without arguments makes it possible for anyone to execute commands on the server. The function `dispatchReadPump` does not checks the option cli `-c`, thus allowing anyone to execute arbitrary command through the use of websockets. Version 1.0.5 fixes the issue.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Go | github.com/patrickhener/goshs | 1.0.5 | GHSA-rwj2-w85g-5cmm |
| Go | github.com/patrickhener/goshs | 1.0.5 | GO-2025-3672 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| patrickhener | goshs | >= 0.3.4, < 1.0.5 |
Weakness: CWE-284, CWE-77 · Vector: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:L