{"schemaVersion":4,"id":"CVE-2026-125117","aliases":["GHSA-8332-j7wj-wjw4","BIT-mongoose-2026-125117"],"status":"published","duplicateOf":null,"title":"Mongoose walks into inherited properties when hydrating, setting, and merging, allowing overwrites of built-in functions (denial of service) and shared schema state","description":"Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Prior to 6.13.12, 7.8.13, 8.24.7, and 9.11.4, Mongoose can descend into inherited properties while loading database documents in init(), setting dotted paths in $__set, and merging update documents in utils.mergeClone. Attacker-controlled keys such as toString or valueOf can therefore cause Mongoose to write into shared built-in functions instead of an own property. A crafted document, Mixed path, non-strict document or subdocument, findOneAndReplace() replacement, chained update, or Query.prototype.merge() source can overwrite Object.prototype.toString.call, causing later queries on unrelated models to fail until the process restarts. Separately, when an attacker controls the dotted path passed to doc.set(path, value) for a subdocument configured with strict: false, descent through $__set can reach $__schema and alter shared validators or schema options for later documents. Mongoose already blocks __proto__, constructor, and prototype, so this issue overwrites properties on reachable shared objects rather than adding new properties directly to Object.prototype. This issue is fixed in versions 6.13.12, 7.8.13, 8.24.7, and 9.11.4.","dates":{"published":"2026-11-09T22:26:29.758Z","modified":"2026-11-10T16:20:41.936Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":8.2,"severity":"high","version":"3.1","versionLabel":"v3.1","source":"CVE.org","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","computed":false,"selection":"backend-summary"},"metrics":[{"version":"3.1","versionLabel":"v3.1","source":"CVE.org","score":8.2,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","exploitability":null,"impact":null,"computed":false},{"version":"3.1","versionLabel":"v3.1","source":"NVD","score":8.2,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","exploitability":null,"impact":null,"computed":false},{"version":"3.1","versionLabel":"v3.1","source":"OSV · Npm","score":8.2,"severity":"high","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","exploitability":10,"impact":7,"computed":true}]},"epss":{"probability":0.00728,"percentile":0.55563,"severity":"low","asOf":"2026-12-04T00:00:00.000Z","change":{"pp":null,"baselineDate":null,"baselineScore":null},"history":[{"date":"2026-11-10T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-11T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-12T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-13T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-14T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-15T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-16T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-17T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-18T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-19T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-20T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-21T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-22T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-23T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-24T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-25T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-26T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-27T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-28T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-29T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-30T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-12-01T00:00:00.000Z","score":0.00728,"percentile":null},{"date":"2026-12-02T00:00:00.000Z","score":0.00728,"percentile":null},{"date":"2026-12-03T00:00:00.000Z","score":0.00728,"percentile":null},{"date":"2026-12-04T00:00:00.000Z","score":0.00728,"percentile":0.55563}],"last30":[{"date":"2026-11-10T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-11T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-12T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-13T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-14T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-15T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-16T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-17T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-18T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-19T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-20T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-21T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-22T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-23T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-24T00:00:00.000Z","score":0.00584,"percentile":null},{"date":"2026-11-25T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-26T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-27T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-28T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-29T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-11-30T00:00:00.000Z","score":0.00776,"percentile":null},{"date":"2026-12-01T00:00:00.000Z","score":0.00728,"percentile":null},{"date":"2026-12-02T00:00:00.000Z","score":0.00728,"percentile":null},{"date":"2026-12-03T00:00:00.000Z","score":0.00728,"percentile":null},{"date":"2026-12-04T00:00:00.000Z","score":0.00728,"percentile":0.55563}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[],"exploitCount":0,"weaknesses":[{"id":"CWE-1321","name":"Improperly Controlled Modification of Object Prototype Attributes","description":"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.","type":"weakness","status":"Incomplete","abstraction":"Variant","likelihoodOfExploit":null,"url":"https://cwe.mitre.org/data/definitions/1321.html"}],"affected":[{"vendor":"automattic","product":"mongoose","name":"mongoose","label":"mongoose","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"< 6.13.12","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":null,"startInclusive":true,"end":"6.13.12","endInclusive":false}},{"text":"≥ 7.0.0, < 7.8.13","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"7.0.0","startInclusive":true,"end":"7.8.13","endInclusive":false}},{"text":"≥ 8.0.0, < 8.24.7","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"8.0.0","startInclusive":true,"end":"8.24.7","endInclusive":false}},{"text":"≥ 9.0.0, < 9.11.4","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"9.0.0","startInclusive":true,"end":"9.11.4","endInclusive":false}}],"versionsText":"< 6.13.12 | ≥ 7.0.0, < 7.8.13 | ≥ 8.0.0, < 8.24.7 | ≥ 9.0.0, < 9.11.4","eol":null,"hubHref":"/vendor/automattic/mongoose"},{"vendor":"Npm","product":"mongoose","name":"mongoose","label":"mongoose","ecosystem":"Npm","cpePart":null,"purl":"pkg:npm/mongoose","purlType":"npm","versions":[{"text":"< 6.13.12","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":null,"startInclusive":true,"end":"6.13.12","endInclusive":false}},{"text":"≥ 7.0.0, < 7.8.13","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"7.0.0","startInclusive":true,"end":"7.8.13","endInclusive":false}},{"text":"≥ 8.0.0, < 8.24.7","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"8.0.0","startInclusive":true,"end":"8.24.7","endInclusive":false}},{"text":"≥ 9.0.0, < 9.11.4","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"9.0.0","startInclusive":true,"end":"9.11.4","endInclusive":false}}],"versionsText":"< 6.13.12 | ≥ 7.0.0, < 7.8.13 | ≥ 8.0.0, < 8.24.7 | ≥ 9.0.0, < 9.11.4","eol":null,"hubHref":null}],"affectedCount":2,"eol":{"hasEol":false,"count":0},"references":[{"url":"https://github.com/Automattic/mongoose/security/advisories/GHSA-8332-j7wj-wjw4","label":"github.com/Automattic/mongoose/security/advisories/GHSA-8332-j7wj-wjw4","hostname":"github.com","tags":["X Refsource CONFIRM","WEB"]},{"url":"https://github.com/Automattic/mongoose/commit/18b5513dd463731a2caf0d3395ef1d9eb0735f50","label":"github.com/Automattic/mongoose/commit/18b5513dd463731a2caf0d3395ef1d9eb0735f50","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/commit/2a195d19a4dd240f039a0a226614d5804e8187ee","label":"github.com/Automattic/mongoose/commit/2a195d19a4dd240f039a0a226614d5804e8187ee","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/commit/3cb702b8d079c3e267f0b10f41673a1590f703c8","label":"github.com/Automattic/mongoose/commit/3cb702b8d079c3e267f0b10f41673a1590f703c8","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/commit/85cf897105edfeb5f56be42a18a68704434cac82","label":"github.com/Automattic/mongoose/commit/85cf897105edfeb5f56be42a18a68704434cac82","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/commit/8cee51beead554df1f3d05645edb439c69eb2a9b","label":"github.com/Automattic/mongoose/commit/8cee51beead554df1f3d05645edb439c69eb2a9b","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/commit/8eb74cb4a550cbe0225963b07aebacbd999d4b74","label":"github.com/Automattic/mongoose/commit/8eb74cb4a550cbe0225963b07aebacbd999d4b74","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/6.13.12","label":"github.com/Automattic/mongoose/releases/tag/6.13.12","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/7.8.13","label":"github.com/Automattic/mongoose/releases/tag/7.8.13","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/8.24.7","label":"github.com/Automattic/mongoose/releases/tag/8.24.7","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/9.11.4","label":"github.com/Automattic/mongoose/releases/tag/9.11.4","hostname":"github.com","tags":["X Refsource MISC","WEB"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-125117","label":"nvd.nist.gov/vuln/detail/CVE-2026-125117","hostname":"nvd.nist.gov","tags":["Advisory"]},{"url":"https://github.com/Automattic/mongoose","label":"github.com/Automattic/mongoose","hostname":"github.com","tags":["PACKAGE"]}],"lineage":{"upstream":[],"downstream":[],"duplicates":[],"related":[]},"timeline":[{"kind":"published","date":"2026-11-09T22:26:29.758Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2026-11-10T16:20:41.936Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"priority":{"label":"prioritise","tag":"severe","reason":"Severe, CVSS 8.2 (CVE.org); no exploitation reported by the 5 checked sources; EPSS 1% (FIRST, 04-12-2026)","nextStep":"Check applicability: affected before 6.13.12, 7.8.13, 8.24.7, 9.11.4 (CNA); fix release not confirmed","rank":[0,0,0,0,1,82],"checkedSources":["cisa","enisa","circl","shadowserver","cisa-adp"],"evidence":[{"type":"epss","source":"FIRST","date":"2026-12-04T00:00:00.000Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"value":0.00728,"stale":false,"promoted":null},{"type":"cvss","source":"cve.org","date":"2026-11-10T16:20:41.936Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":8.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","version":"3.1","headline":true},{"type":"cvss","source":"nvd","date":"2026-11-10T16:20:41.936Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":8.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","version":"3.1"},{"type":"cvss","source":"osv_npm","date":"2026-11-10T16:20:41.936Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":8.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H","version":"3.1"},{"type":"adp","source":"cisa-adp","date":"2026-11-10T16:20:05.167Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"exploitation":"poc"}],"epss":{"value":0.00728,"date":"2026-12-04T00:00:00.000Z","stale":false,"promoted":null},"sources":[{"id":"cisa","lastSuccessfulSync":"2026-12-05T10:02:10.250Z","state":"fresh"},{"id":"enisa","lastSuccessfulSync":"2026-12-05T10:02:10.837Z","state":"fresh"},{"id":"circl","lastSuccessfulSync":"2026-12-05T10:02:11.033Z","state":"fresh"},{"id":"shadowserver","lastSuccessfulSync":null,"state":"unavailable"},{"id":"cisa-adp","lastSuccessfulSync":"2026-12-05T10:01:03.214Z","state":"fresh"},{"id":"epss","lastSuccessfulSync":"2026-12-05T10:02:08.667Z","state":"fresh"},{"id":"osv","lastSuccessfulSync":"2026-12-05T10:02:07.694Z","state":"fresh"}],"feedEvent":null},"meta":{"dataAsOf":"2026-12-05T10:11:07.150Z","stale":false,"partial":false}}