Description
Mockoon provides way to design and run mock APIs. Prior to 9.7.0, Mockoon's admin API in commons-server/src/libs/server/admin-api.ts is mounted on the same Express listener as user-defined mock routes, enabled by default in shipped runtimes, serves Access-Control-Allow-Origin: * with write methods allowed, and has no authentication. Any unauthenticated caller who can reach the mock server port can read MOCKOON_* environment variables, write arbitrary process environment variables through /mockoon-admin/env-vars, rewrite mock route bodies, statuses, and headers through PUT /mockoon-admin/environment, read transaction logs and SSE streams, and purge state. This issue is fixed in version 9.7.0.
Published: 2026-07-09
Score: 8.8 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Mockoon’s admin API user‑defined mock routes. The API allows privileged operations such as writing arbitrary process environment variables, modifying mock route bodies and headers, and accessing transaction logs. The lack of authentication (CWE‑306) and unrestricted write authorization (CWE‑732) give an attacker full control over the mock server environment. Based on the description, the likely attack vector involves a remote attacker who can connect to the mock server port, for example via a web browser exploiting the wildcard CORS header (Access‑Control‑Allow‑Origin: *). exfiltration.

Affected Systems

All installations of Mockoon prior to version 9.7.0 are affected. The vulnerability resides in the commons‑server/src/libs/server/admin‑api.ts, which is mounted on the same Express listener as user‑defined routes. Users running any shipped runtime before this patch on any platform should consider the product vulnerable until they upgrade to 9.7.0 or later.

Risk and Exploitability

The CVSS score of 8.8 classifies the issue as high severity, and the EPSS score is < 1 %. While the likelihood of exploitation in the wild is low, the absence of an authentication barrier and the ability to modify environment variables and request handlers mean that a remote attacker who can reach the server port can exploit the flaw with relatively low effort. The vulnerability is not listed in CISA’s KEV catalog, yet its destructive potential warrants immediate attention, especially in environments exposed to the public internet.

Generated by OpenCVE AI on July 28, 2026 at 08:45 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to Mockoon 9.7.0 or later.
  • Restrict network access to the mock server port by binding the server to localhost or applying firewall rules.
  • Disable the admin API by configuring Mockoon to run without the /mockoon‑admin routes or by commenting out the import in the server code.

Generated by OpenCVE AI on July 28, 2026 at 08:45 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Thu, 09 Jul 2026 20:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Thu, 09 Jul 2026 19:45:00 +0000

Type Values Removed Values Added
First Time appeared Mockoon
Mockoon mockoon
Vendors & Products Mockoon
Mockoon mockoon

Thu, 09 Jul 2026 18:45:00 +0000

Type Values Removed Values Added
Description Mockoon provides way to design and run mock APIs. Prior to 9.7.0, Mockoon's admin API in commons-server/src/libs/server/admin-api.ts is mounted on the same Express listener as user-defined mock routes, enabled by default in shipped runtimes, serves Access-Control-Allow-Origin: * with write methods allowed, and has no authentication. Any unauthenticated caller who can reach the mock server port can read MOCKOON_* environment variables, write arbitrary process environment variables through /mockoon-admin/env-vars, rewrite mock route bodies, statuses, and headers through PUT /mockoon-admin/environment, read transaction logs and SSE streams, and purge state. This issue is fixed in version 9.7.0.
Title Mockoon: Unauthenticated admin API + wildcard CORS allows mock-state hijack and secret theft
Weaknesses CWE-306
CWE-352
CWE-732
CWE-942
References
Metrics cvssV3_1

{'score': 8.8, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-07-09T19:24:49.203Z

Reserved: 2026-07-02T16:50:27.886Z

Link: CVE-2026-59148

cve-icon Vulnrichment

Updated: 2026-07-09T19:24:22.428Z

cve-icon NVD

No data.

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-07-28T09:00:06Z

Weaknesses
  • CWE-306

    Missing Authentication for Critical Function

  • CWE-352

    Cross-Site Request Forgery (CSRF)

  • CWE-732

    Incorrect Permission Assignment for Critical Resource

  • CWE-942

    Permissive Cross-domain Security Policy with Untrusted Domains