GHSA-2cjr-5v3h-v2w4
### Summary A prototype pollution vulnerability in the mailbox store module allows attackers to modify the behavior of all JavaScript objects by injecting malicious properties into `Object.prototype`. The vulnerability exists in the `_applyUpdate()` and `_updateRecord()` functions which use `Object.assign()` to merge user-controlled data without filtering dangerous keys like `__proto__`, `constructor`, or `prototype`. ### Details The vulnerability exists in `src/proxy/mailbox/store.js` at lines 123 and 145: ```javascript // src/proxy/mailbox/store.js:115-128 _applyUpdate(row) { if (row._op === 'update') { const existing = this._index[row.id]; // VULNERABLE: Direct Object.assign without key filtering if (existing) Object.assign(existing, row.fields); else this._index[row.id] = row.fields; } // ... } // src/proxy/mailbox/store.js:138-150 _updateRecord(id, fields) { const existing = this._index[id]; // VULNERABLE: Direct Object.assign without key filtering if (existing) Object.assign(existing, fields); // ... } ``` The vulnerability can be triggered when an attacker has the ability to write to the `messages.jsonl` file (used for mailbox persistence). By crafting a malicious JSONL entry with `__proto__` as a field key, the attacker can pollute the prototype of all objects. The data flows from: 1. `messages.jsonl` file → 2. `readLines()` function (line 47) → 3. `_rebuildIndex()` (line 113) → `_applyUpdate()` (line 121) → 4. `Object.assign()` pollutes prototype ### PoC **Prerequisites:** - Node.js installed - Access to write to the mailbox messages file **Steps to reproduce:** 1. Create a test file demonstrating the vulnerability: ```javascript // test-prototype-pollution.js const fs = require('fs'); const path = require('path'); // Simulate the vulnerable Store class logic class VulnerableStore { constructor(filePath) { this.filePath = filePath; this._index = {}; } load() { if (!fs.existsSync(this.filePath))
Properties
- ghsa_id
- GHSA-2cjr-5v3h-v2w4
- severity
- medium
- summary
- Evolver has Prototype Pollution via `Object.assign()` in its mailbox store operations
- cvss_score
- 5.2
- cve_id
- GHSA-2cjr-5v3h-v2w4
- cvss_vector
- CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:L/I:L/A:H
- is_ghsa_only
- true
- ghsa_published
- 2026-04-22T22:05:28Z
- source_url
- https://github.com/advisories/GHSA-2cjr-5v3h-v2w4
- ghsa_updated
- 2026-04-22T22:05:31Z
Related Entities (4)
VULNERABLE_TO (1)
AFFECTS (1)
HAS_WEAKNESS (1)
REPORTED_BY (1)
Explore deeper with Ninja Signal's threat intelligence graph