/

CVE-2026-59720

Severity:

HIGH RISK

(7.5)

Access Control Data Exposure (CWE-284) in Hoppscotch

CVE-2026-59720

Deferred

Vulnerability type

Category:

Access Control Misconfiguration

CWE:

CWE-200, CWE-284

Impact:

Unauthorized Data Exposure

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

Hoppscotch mock server creation previously failed to persist the isPublic access flag, while the underlying schema defaulted this field to true.

As a result, mock servers tied to private collections could become publicly accessible without authentication, risking exposure of sensitive API data whenever private mocks were created or managed.

Affected context

This vulnerability appears in Hoppscotch deployments where mock servers are used to expose or test API behavior via collections.

It affects workflows in which:

  • Collections are marked private or assumed to be restricted
  • Mock servers are created or linked from those private collections
  • Access control relies on the isPublic flag being correctly persisted and enforced

Under these conditions, mismatched defaults and missing field persistence can inadvertently make private mock endpoints accessible to any unauthenticated user.

Exploit preconditions

  • Attack surface: HTTP endpoints provided by Hoppscotch mock servers
  • Required access: Network access to the mock server URLs; no authentication is required when isPublic is effectively treated as true
  • Trigger point: Accessing mock server endpoints that are expected to be private but were created without correctly persisting the isPublic flag
  • Why exploitation is possible: The service layer does not store the isPublic input while the database schema defaults to public, leading to a mismatch between user intent (private collections) and actual enforcement (public mock servers)

Why this happens

The core issue is an access control misconfiguration stemming from inconsistent handling of authorization metadata between the application logic and the data model.

Specifically, the mock-server service neglects to persist the isPublic field provided by the user, while the Prisma schema defaults isPublic to true. This design causes newly created mock servers to be public even when they belong to private collections.

This maps to CWE-284: Improper Access Control and CWE-200: Exposure of Sensitive Information to an Unauthorized Actor, as authorization state is assumed rather than explicitly stored and enforced, resulting in unintended data exposure.

Potential impact

  • Private mock APIs may be reachable by any unauthenticated user
  • Sensitive request/response samples and API schemas could be exposed
  • Leakage of internal service names, endpoints, or debugging data can aid further attacks
  • Violation of data protection or confidentiality policies due to unintended public access

General mitigation guidance

A robust mitigation strategy centers on making access control explicit, consistent, and secure-by-default.

Common defensive patterns include:

  • Ensuring that all access control flags (such as isPublic) are persisted and validated at every layer: UI, service, and database model
  • Avoiding permissive defaults; treat new resources as private unless clearly marked otherwise
  • Implementing centralized authorization checks that derive access from a single, authoritative source of truth
  • Designing APIs so that collection privacy and mock-server visibility cannot diverge without explicit administrative action
  • Incorporating defense-in-depth controls such as token-based access or IP restrictions for mock endpoints that may contain sensitive data

How teams detect issues like this

Organizations can detect similar access control issues by:

  • Reviewing API and service code for fields that influence authorization but are not consistently persisted or checked
  • Using static analysis or schema validation to flag mismatches between model defaults and business logic expectations
  • Implementing automated tests that verify private collections never yield publicly reachable mock endpoints
  • Adding policy-based checks in CI/CD pipelines to ensure that security-related flags have conservative defaults and clear enforcement points
  • Periodically scanning mock server URLs and access logs to identify endpoints that are publicly accessible but associated with private or sensitive content

Sources

SourceLink
github.comgithub.com/hoppscotch/hoppscotch/commit/e4332110d455a3012d5c77a9186bc4aa096e34f2
github.comgithub.com/hoppscotch/hoppscotch/pull/6410
github.comgithub.com/hoppscotch/hoppscotch/releases/tag/2026.6.0
github.comgithub.com/hoppscotch/hoppscotch/security/advisories/GHSA-c68f-wr5p-j6jf

Frequently asked

questions

Yes. Any user with network access to the Hoppscotch deployment can reach affected mock server URLs without authentication if they are effectively treated as public.

No explicit account is required to exploit the issue. The primary requirement is knowing or discovering the mock server endpoints that were intended to be private but are publicly accessible.

Make access control explicit and conservative: always persist authorization-relevant fields such as isPublic, avoid permissive defaults, and enforce privacy constraints consistently across collections and derived resources like mock servers.

Align database schemas, service logic, and UI behavior around a single authorization model, mandate private-by-default resource creation, and add automated tests and policy checks that validate access control behavior whenever new entities or flags are introduced.

Find out what's already
exploitable in your codebase.