Skip to content
Heist/ feed
Back to feed
High

goshs is Missing Write Protection for Parametric Data Values

Type: advisorySources: OSV

goshs is a SimpleHTTPServer written in Go. From 1.0.7 to before 2.0.0-beta.4, the SFTP command rename sanitizes only the source path and not the destination, so it is possible to write outside of the root directory of the SFTP. This vulnerability is fixed in 2.0.0-beta.4.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-40188
Confirmed fixed CVEs
Not specified
Updated in this feed
4 Nov 2026, 13:44 UTC · Revision 1

Source evidence

goshs is Missing Write Protection for Parametric Data Values

core-osv · Original source

Published 10 Apr 2026, 19:43 UTC

goshs is a SimpleHTTPServer written in Go. From 1.0.7 to before 2.0.0-beta.4, the SFTP command rename sanitizes only the source path and not the destination, so it is possible to write outside of the root directory of the SFTP. This vulnerability is fixed in 2.0.0-beta.4.

osv:CVE-2026-40188
Complete source record
{
  "id": "ca9f358207c5ec983d990e18739d030e3259dacae4c346ab9f1f413e3cff5238",
  "url": "https://osv.dev/vulnerability/CVE-2026-40188",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "goshs is Missing Write Protection for Parametric Data Values",
    "summary": "goshs is a SimpleHTTPServer written in Go. From 1.0.7 to before 2.0.0-beta.4, the SFTP command rename sanitizes only the source path and not the destination, so it is possible to write outside of the root directory of the SFTP. This vulnerability is fixed in 2.0.0-beta.4.",
    "evidence": "osv:CVE-2026-40188",
    "products": [],
    "severity": "high",
    "structured": {
      "id": "CVE-2026-40188",
      "aliases": [
        "CVE-2026-40188",
        "GHSA-2943-crp8-38xx",
        "GO-2026-4953"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/goshs-labs/goshs",
              "type": "GIT",
              "events": [
                {
                  "introduced": "a24cf77e24a797737603e0f76d502317ff6b3e06"
                },
                {
                  "fixed": "0c316e71c6eb69d75218c4af6e9793cc07cdfaab"
                },
                {
                  "fixed": "141c188ce270ffbec087844a50e5e695b7da7744"
                },
                {
                  "fixed": "10f291dea17fb795f0008ed64c3ad7ab8c0470de"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:goshs:goshs:*:*:*:*:*:go:*:*",
                    "range": [
                      {
                        "introduced": "1.0.7"
                      },
                      {
                        "fixed": "2.0.0"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "range": [
                      {
                        "fixed": "141c188ce270ffbec087844a50e5e695b7da7744"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  },
                  {
                    "range": [
                      {
                        "fixed": "10f291dea17fb795f0008ed64c3ad7ab8c0470de"
                      }
                    ],
                    "source": "REFERENCES_TAG",
                    "original_tag": "v2.0.0-beta.4"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v1.1.4",
            "v2.0.0-beta.3",
            "v2.0.0-beta.2",
            "v2.0.0-beta.1",
            "1.1.3",
            "v1.1.2",
            "v1.1.1",
            "v1.1.0",
            "v1.0.9",
            "v1.0.8",
            "v1.0.7"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-40188.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:35.907837269Z",
      "provider": "osv",
      "references": [
        "https://github.com/patrickhener/goshs/releases/tag/v2.0.0-beta.4",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/40xxx/CVE-2026-40188.json",
        "https://github.com/patrickhener/goshs/security/advisories/GHSA-2943-crp8-38xx",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-40188",
        "https://github.com/patrickhener/goshs/commit/141c188ce270ffbec087844a50e5e695b7da7744"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-1314"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/40xxx/CVE-2026-40188.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-40188",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 503244,
  "published_at": "2026-04-10T19:43:45.197+00:00"
}