GoshsApplication

CVE-2026-40884

CRITICAL · 9.8 CVSS v3.1 Published 2026-04-21
Fix available
A fix is available. Upgrade to 2.0.0 or later.
See remediation →
100/100
Remediation priority · Urgent
Public exploit Remotely reachable No privileges Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
goshs is a SimpleHTTPServer written in Go. Prior to 2.0.0-beta.6, goshs contains an SFTP authentication bypass when the documented empty-username basic-auth syntax is used. If the server is started with -b ':pass' together with -sftp, goshs accepts that configuration but does not install any SFTP password handler. As a result, an unauthenticated network attacker can connect to the SFTP service and access files without a password. This vulnerability is fixed in 2.0.0-beta.6.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

goshs SimpleHTTPServer prior to 2.0.0-beta.6 has an SFTP authentication bypass where using the empty-username basic-auth syntax (-b ':pass') with the -sftp flag fails to install the SFTP password handler, allowing unauthenticated network attackers to access and manipulate files via SFTP without any credentials.

MitigationUpgrade to goshs version 2.0.0-beta.6 or later. If immediate patching is not feasible, avoid using the -b ':pass' syntax with -sftp or disable SFTP service until the upgrade can be applied.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
GoshsApplication
Affected:< 2.0.0= 2.0.0

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Identify goshs installation and version
    Run 'goshs --version' or 'goshs -v' to determine the installed version. If running as a container or service, check the container image tag or deployment manifest for the version.
    Affected if Version is less than 2.0.0 or exactly 2.0.0 (vulnerable versions before 2.0.0-beta.6)
  2. Confirm SFTP service is enabled
    Inspect the goshs process command line or startup configuration for the '-sftp' flag. Check running processes with 'ps aux | grep goshs' or review systemd/service configuration files.
    Affected if The -sftp flag is present in the running configuration or command line
  3. Detect empty-username basic-auth syntax
    Review the goshs startup command or configuration for the basic-auth parameter pattern '-b' with an empty username before the colon, such as '-b :password' or '-b ":password"'. This syntax uses a leading colon with no username preceding it.
    Affected if The -b parameter is used with empty username syntax (':pass' pattern) in combination with -sftp flag
  4. Verify SFTP authentication behavior
    If possible, attempt an SFTP connection to the goshs server using an empty username with any password. A successful connection without credentials indicates the vulnerability is present.
    Affected if SFTP connection succeeds without valid credentials when using empty username with the vulnerable version and configuration

The environment is affected if goshs version is less than 2.0.0 or exactly 2.0.0 AND the -sftp flag is enabled AND the -b ':pass' empty-username syntax is used, allowing unauthenticated SFTP access.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 2.0.0 or later
Fixed in 2.0.0
Interim mitigation

Upgrade to goshs version 2.0.0-beta.6 or later. If immediate patching is not feasible, avoid using the -b ':pass' syntax with -sftp or disable SFTP service until the upgrade can be applied.

Recommended fix High confidence

2.0.0-beta.6

  1. 1. Download goshs version 2.0.0-beta.6 or later from the official GitHub repository (github.com)
  2. 2. Replace the existing goshs binary with the new version
  3. 3. Restart the goshs service if it was running
  4. 4. Verify the SFTP authentication is now properly enforced by attempting a connection without credentials (should fail)
Caveat 2.0.0-beta.6 is a beta release; review release notes for any configuration or feature changes

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Goshs Scoped from the published advisory
  • Consultation1.0 h
  • Implementation1.0 h
  • Testing2.0 h
  • Review / QA1.0 h
5.0 hours of engineering $860
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $1,376.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2026-40884 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2026-40884 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data