Advisory Database
  • Advisories
  • Dependency Scanning
  1. maven
  2. ›
  3. io.karatelabs/karate-core
  4. ›
  5. GHSA-2c85-rfcc-g74j

GHSA-2c85-rfcc-g74j: Karate Mock Server RCE via embedded expression evaluation of request-derived data

June 18, 2026

Karate Mock Server can execute embedded expressions found in attacker-controlled HTTP request data when a Mock Server feature assigns request-derived values such as request, requestHeaders, or requestParams to variables.

In affected scenarios, an unauthenticated remote attacker can place a Karate embedded expression such as #(Java.type(...)) in the HTTP body, headers, or query parameters. The Mock Server then recursively processes that untrusted data as embedded expressions and evaluates it server-side, which can lead to arbitrary command execution under the privileges of the Karate Mock Server process.

This issue does not require the attacker to control the feature file. The vulnerable precondition is that the Mock Server feature uses request-derived data in a way that passes through Karate expression evaluation, for example:

* def body = request
* def hdrs = requestHeaders
* def params = requestParams

References

  • github.com/advisories/GHSA-2c85-rfcc-g74j
  • github.com/karatelabs/karate/security/advisories/GHSA-2c85-rfcc-g74j

Code Behaviors & Features

Detect and mitigate GHSA-2c85-rfcc-g74j with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions starting from 2.0.1 before 2.1.0

Fixed versions

  • 2.1.0

Solution

Upgrade to version 2.1.0 or above.

Impact 9.8 CRITICAL

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

Learn more about CVSS

Weakness

  • CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')

Source file

maven/io.karatelabs/karate-core/GHSA-2c85-rfcc-g74j.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Tue, 23 Jun 2026 12:23:42 +0000.