Skip to content
OpenAdvisories
Critical · 9.3 CVE-2026-40189 EUVD-2026-21591GHSA-wvhv-qcqf-f3cxGO-2026-5728

goshs has a file-based ACL authorization bypass in goshs state-changing routes

Published Apr 10, 2026 · Updated Apr 13, 2026 · Assigned by GitHub_M

Description

goshs is a SimpleHTTPServer written in Go. Prior to 2.0.0-beta.4, goshs enforces the documented per-folder .goshs ACL/basic-auth mechanism for directory listings and file reads, but it does not enforce the same authorization checks for state-changing routes. An unauthenticated attacker can upload files with PUT, upload files with multipart POST /upload, create directories with ?mkdir, and delete files with ?delete inside a .goshs-protected directory. By deleting the .goshs file itself, the attacker can remove the folder's auth policy and then access previously protected content without credentials. This results in a critical authorization bypass affecting confidentiality, integrity, and availability. This vulnerability is fixed in 2.0.0-beta.4.

Affected products

VendorProductAffectedFixed
patrickhener goshs < 2.0.0-beta.4 —

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 Tumbleweed goshs 2.0.0-1.1 openSUSE-SU-2026:10542-1
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-wvhv-qcqf-f3cx
Go github.com/patrickhener/goshs all versions — GO-2026-5728

Advisories 2

References