/

CVE-2026-54719

Severity:

HIGH RISK

(7.5)

Missing Auth for Bulk ZIP (CWE-862) in goshs Server

CVE-2026-54719

Deferred

Vulnerability type

Category:

Missing Authorization

CWE:

CWE-862, CWE-863

Impact:

Unauthorized File Disclosure

Severity:

HIGH RISK

(7.5)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

goshs contained an authentication bypass in its bulk ZIP download handler, allowing unauthenticated users to download files that should be protected by folder-level ACLs and block lists.

When the ?bulk&file= ZIP feature was used, the handler skipped effective ACL checks, exposing otherwise restricted content to anyone who could reach the HTTP endpoint.

goshs contained an authentication bypass in its bulk ZIP download handler, allowing unauthenticated users to download files that should be protected by folder-level ACLs and block lists.

When the ?bulk&file= ZIP feature was used, the handler skipped effective ACL checks, exposing otherwise restricted content to anyone who could reach the HTTP endpoint.

Affected context

This vulnerability affects goshs deployments that rely on .goshs folder ACLs and block lists to protect sensitive files or directories.

The issue is specifically tied to the bulk download functionality accessed via the ?bulk&file= query parameters, where file selection for ZIP archives bypassed the normal authorization mechanisms.

Environments that expose goshs over untrusted networks or share it with multiple users are at higher risk, especially if operators assume ACL-protected paths cannot be read without authentication.

This vulnerability affects goshs deployments that rely on .goshs folder ACLs and block lists to protect sensitive files or directories.

The issue is specifically tied to the bulk download functionality accessed via the ?bulk&file= query parameters, where file selection for ZIP archives bypassed the normal authorization mechanisms.

Environments that expose goshs over untrusted networks or share it with multiple users are at higher risk, especially if operators assume ACL-protected paths cannot be read without authentication.

Exploit preconditions

  • Attack surface: HTTP interface of a goshs instance reachable by the attacker.
  • Required access: Network-level access to the goshs server; no prior authentication required for the vulnerable handler.
  • Trigger point: Issuing a request to the bulk download endpoint (e.g., URLs using ?bulk&file=) that references files or directories protected by .goshs ACLs or block lists.
  • Why exploitation is possible: The bulk download handler did not invoke findEffectiveACL or applyCustomAuth, causing authorization decisions applied elsewhere to be skipped for ZIP-based downloads.
  • Attack surface: HTTP interface of a goshs instance reachable by the attacker.
  • Required access: Network-level access to the goshs server; no prior authentication required for the vulnerable handler.
  • Trigger point: Issuing a request to the bulk download endpoint (e.g., URLs using ?bulk&file=) that references files or directories protected by .goshs ACLs or block lists.
  • Why exploitation is possible: The bulk download handler did not invoke findEffectiveACL or applyCustomAuth, causing authorization decisions applied elsewhere to be skipped for ZIP-based downloads.

Why this happens

The underlying issue is a broken or missing authorization check on a specific code path responsible for bulk ZIP downloads.

While standard file-serving routes enforced access control via findEffectiveACL and applyCustomAuth, the bulk download handler in httpserver/updown.go omitted these checks, creating an inconsistent security model.

This maps to CWE-862 (Missing Authorization) and CWE-863 (Incorrect Authorization), where access control logic is either absent or not applied uniformly across all relevant endpoints, especially after an incomplete fix for an earlier related vulnerability.

The underlying issue is a broken or missing authorization check on a specific code path responsible for bulk ZIP downloads.

While standard file-serving routes enforced access control via findEffectiveACL and applyCustomAuth, the bulk download handler in httpserver/updown.go omitted these checks, creating an inconsistent security model.

This maps to CWE-862 (Missing Authorization) and CWE-863 (Incorrect Authorization), where access control logic is either absent or not applied uniformly across all relevant endpoints, especially after an incomplete fix for an earlier related vulnerability.

Potential impact

  • Unauthenticated users can download files that operators intended to restrict via .goshs ACLs.
  • Exposure of sensitive configuration files, logs, or red-team artifacts stored behind folder-level protections.
  • Leakage of internal operational data that may aid further attacks or reconnaissance.
  • Accidental disclosure of proprietary or personal data if goshs is used as an ad-hoc file server.
  • Unauthenticated users can download files that operators intended to restrict via .goshs ACLs.
  • Exposure of sensitive configuration files, logs, or red-team artifacts stored behind folder-level protections.
  • Leakage of internal operational data that may aid further attacks or reconnaissance.
  • Accidental disclosure of proprietary or personal data if goshs is used as an ad-hoc file server.

General mitigation guidance

Effective mitigation focuses on enforcing consistent authorization checks across all file-serving endpoints:

  • Ensure all download paths, including bulk or convenience features (like ZIP bundling), reuse the same centralized authorization functions that enforce ACLs and block lists.
  • Adopt a security-by-default approach where new handlers or features must explicitly opt into access control before serving any content.
  • Design ACL evaluation as a shared, mandatory layer in the request pipeline, rather than duplicating checks within individual handlers.
  • Limit exposure of goshs instances to trusted networks or reverse proxies that can provide additional authentication and path-level access control.
  • Apply least-privilege principles for what content is hosted, segregating highly sensitive files from general-purpose file sharing locations.

Effective mitigation focuses on enforcing consistent authorization checks across all file-serving endpoints:

  • Ensure all download paths, including bulk or convenience features (like ZIP bundling), reuse the same centralized authorization functions that enforce ACLs and block lists.
  • Adopt a security-by-default approach where new handlers or features must explicitly opt into access control before serving any content.
  • Design ACL evaluation as a shared, mandatory layer in the request pipeline, rather than duplicating checks within individual handlers.
  • Limit exposure of goshs instances to trusted networks or reverse proxies that can provide additional authentication and path-level access control.
  • Apply least-privilege principles for what content is hosted, segregating highly sensitive files from general-purpose file sharing locations.

How teams detect issues like this

Possible detection and assurance strategies include:

  • Static analysis and code review: Search for HTTP handlers that read from the filesystem but do not call the central ACL/auth functions (e.g., findEffectiveACL, applyCustomAuth), or equivalent access control utilities.
  • Route-level policy checks: Maintain a checklist during development that ensures every new HTTP route documenting file access is mapped to a corresponding authorization policy.
  • Automated tests: Add regression tests that attempt to access ACL-protected resources through all download mechanisms, including bulk ZIP endpoints, and verify that unauthorized requests are rejected.
  • Runtime monitoring: Inspect access logs for patterns where anonymous users download large archives or files from typically restricted directories, and flag unexpected bulk-download behavior.

Possible detection and assurance strategies include:

  • Static analysis and code review: Search for HTTP handlers that read from the filesystem but do not call the central ACL/auth functions (e.g., findEffectiveACL, applyCustomAuth), or equivalent access control utilities.
  • Route-level policy checks: Maintain a checklist during development that ensures every new HTTP route documenting file access is mapped to a corresponding authorization policy.
  • Automated tests: Add regression tests that attempt to access ACL-protected resources through all download mechanisms, including bulk ZIP endpoints, and verify that unauthorized requests are rejected.
  • Runtime monitoring: Inspect access logs for patterns where anonymous users download large archives or files from typically restricted directories, and flag unexpected bulk-download behavior.

Sources

SourceLink
github.comgithub.com/goshs-labs/goshs/commit/7cf911a26ace737e1a55b7dc073e307a25f7fd1d
github.comgithub.com/goshs-labs/goshs/releases/tag/v2.1.1
github.comgithub.com/goshs-labs/goshs/security/advisories/GHSA-rmxw-pq4x-3fvh

Frequently asked

questions

Yes. If the goshs HTTP interface is reachable over a network, an unauthenticated remote user can exploit the bulk download endpoint to retrieve protected files, subject to network reachability.

No. The vulnerable bulk ZIP handler did not enforce the .goshs ACL or custom auth logic, so network-level access to the server is generally sufficient to attempt exploitation.

The most robust fix is to centralize authorization logic and ensure that every file-serving endpoint, including bulk and utility routes, must pass through a shared ACL and authentication layer before any content is read or returned.

Prevent recurrence by enforcing a uniform access-control architecture: require new handlers to invoke common authorization middleware, add tests that exercise all download paths for protected resources, and incorporate static analysis or code review checklists that flag any file access without explicit ACL checks.

Yes. If the goshs HTTP interface is reachable over a network, an unauthenticated remote user can exploit the bulk download endpoint to retrieve protected files, subject to network reachability.

No. The vulnerable bulk ZIP handler did not enforce the .goshs ACL or custom auth logic, so network-level access to the server is generally sufficient to attempt exploitation.

The most robust fix is to centralize authorization logic and ensure that every file-serving endpoint, including bulk and utility routes, must pass through a shared ACL and authentication layer before any content is read or returned.

Prevent recurrence by enforcing a uniform access-control architecture: require new handlers to invoke common authorization middleware, add tests that exercise all download paths for protected resources, and incorporate static analysis or code review checklists that flag any file access without explicit ACL checks.

Find out what's already
exploitable in your codebase.