Skip to content
OpenAdvisories
Medium · 6.5 CVE-2026-42091 EUVD-2026-27067GHSA-rhf7-wvw3-vjvmGO-2026-5625

goshs has Cross-Origin Arbitrary File Write via Missing CSRF on PUT and Wildcard CORS

Published May 4, 2026 · Updated May 5, 2026 · Assigned by GitHub_M

Description

goshs is a SimpleHTTPServer written in Go. Prior to version 2.0.2, the PUT upload handler (httpserver/updown.go) lacks the CSRF token validation that was added to the POST upload handler during the CVE-2026-40883 fix. Combined with the unconditional Access-Control-Allow-Origin: * on the OPTIONS preflight handler (httpserver/server.go), any website can write arbitrary files to a goshs instance through the victim's browser — bypassing network isolation (e.g. localhost, internal network). This issue has been patched in version 2.0.2.

Affected products

VendorProductAffectedFixed
patrickhener goshs < 2.0.2 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
openSUSE Leap 16.0 govulncheck-vulndb 0.0.20260723T184607-160000.1.1 openSUSE-SU-2026:21483-1

Affected packages

EcosystemPackageAffectedFixedRecord
Go github.com/patrickhener/goshs <= 1.1.4 — GHSA-rhf7-wvw3-vjvm
Go github.com/patrickhener/goshs all versions — GO-2026-5625
Go github.com/patrickhener/goshs/v2 < 2.0.2 2.0.2 GHSA-rhf7-wvw3-vjvm
Go goshs.de/goshs all versions — GO-2026-5625
Go goshs.de/goshs/v2 < 2.0.2 2.0.2 GO-2026-5625

Advisories 1

References