CVE-2026-34221: @mikro orm/core MikroORM Has Prototype Pollution Vulnerability

HIGH
Advisory Identifier: GHSA-qpfv-44f3-qqx6
CWE-1321
Published
Advisory Summary

CVE-2026-34221 is a HIGH mikroorm has prototype pollution vulnerability (CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')) affecting @mikro orm/core libraries in the npm ecosystem. The issue involves mikroorm has prototype pollution in utils.merge. Remediation is available by upgrading affected packages to version 6.6.10, 7.0.6.

CVE-2026-34221 at a Glance

CVE Identifier CVE-2026-34221
GHSA Identifier GHSA-qpfv-44f3-qqx6
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')
Affected Product @mikro orm/core
Package Ecosystem npm
Published Date
Last Updated

How to Fix CVE-2026-34221

To remediate this vulnerability, upgrade all affected @mikro orm/core dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@mikro-orm/core fixed: 6.6.10
npm install @mikro-orm/core@6.6.10
@mikro-orm/core fixed: 7.0.6
npm install @mikro-orm/core@7.0.6
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @mikro-orm/core

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-34221, inspect your project dependencies using npm:

npm ls @mikro-orm/core

Analyze the terminal output to locate any version of @mikro orm/core in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 6.6.10), your application is affected.

Note: The npm ls @mikro-orm/core command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution'), where the product receives input from an upstream component that specifies attributes that are to be initialized or updated in an object, but it does not properly control modifications of attributes of the object prototype. In @mikro orm/core, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

A prototype pollution vulnerability exists in the `Utils.merge` helper used internally by MikroORM when merging object structures. The function did not prevent special keys such as `__proto__`, `constructor`, or `prototype`, allowing attacker-controlled input to modify the JavaScript object prototype when merged. Exploitation requires application code to pass untrusted user input into ORM operations that merge object structures, such as entity property assignment or query condition construction. Prototype pollution may lead to denial of service or unexpected application behavior. In certain scenarios, polluted properties may influence query construction and potentially result in SQL injection depending on application code.

CVE-2026-34221 Affected @mikro orm/core Versions

2 component(s)
Fixed Versions:
6.6.107.0.6
Product / Package Ecosystem Affected Versions Fixed Version
@mikro-orm/core
npm
< 6.6.10
6.6.10
@mikro-orm/core
npm
≥ 7.0.0-dev.0
< 7.0.6
7.0.6

References

Frequently Asked Questions

What is CVE-2026-34221?
CVE-2026-34221 is a security vulnerability in @mikro orm/core involving MikroORM has Prototype Pollution in Utils.merge under CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution').
Which @mikro orm/core versions are affected?
Affected versions include releases prior to 6.6.10, 7.0.6 across affected packages: @mikro-orm/core.
What version fixes CVE-2026-34221?
Upgrading to 6.6.10, 7.0.6 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @mikro-orm/core affected?
Yes, @mikro-orm/core is affected in releases prior to 6.6.10, 7.0.6. Upgrade your dependency to 6.6.10, 7.0.6 or later.
What CWE is associated with CVE-2026-34221?
CVE-2026-34221 is classified under CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution') (The product receives input from an upstream component that specifies attributes that are to be initialized or updated in an object, but it does not properly control modifications of attributes of the object prototype.).
How can I check npm dependencies for CVE-2026-34221?
Run the dependency tree command: 'npm ls @mikro-orm/core'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-qpfv-44f3-qqx6",
  "modified" : "2026-03-31T18:55:10Z",
  "published" : "2026-03-29T15:44:16Z",
  "aliases" : [ "CVE-2026-34221" ],
  "summary" : "MikroORM has Prototype Pollution in Utils.merge",
  "details" : "A prototype pollution vulnerability exists in the `Utils.merge` helper used internally by MikroORM when merging object structures.\n\nThe function did not prevent special keys such as `__proto__`, `constructor`, or `prototype`, allowing attacker-controlled input to modify the JavaScript object prototype when merged.\n\nExploitation requires application code to pass untrusted user input into ORM operations that merge object structures, such as entity property assignment or query condition construction.\n\nPrototype pollution may lead to denial of service or unexpected application behavior. In certain scenarios, polluted properties may influence query construction and potentially result in SQL injection depending on application code.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:N/SI:L/SA:L"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@mikro-orm/core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "6.6.10"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@mikro-orm/core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.0.0-dev.0"
      }, {
        "fixed" : "7.0.6"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/mikro-orm/mikro-orm/security/advisories/GHSA-qpfv-44f3-qqx6"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-34221"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/mikro-orm/mikro-orm"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-1321" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-29T15:44:16Z",
    "nvd_published_at" : "2026-03-31T16:16:32Z"
  }
}