# CVE-2025-7207: mruby nregs codegen.c scope_new heap-based overflow

- Severity: Medium 4.8 (CVSS:4.0, scored by VulDB) `CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:P`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.27%, higher than 19% of CVEs (2026-12-01)
- Public exploit code or proof of concept: 3 links below, marked "exploit"
- Published: 2025-07-09T00:02:07.237Z
- Modified: 2026-06-17T10:04:31.090Z
- Weaknesses: CWE-119, CWE-122, CWE-787
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: VulDB

## Description

A vulnerability, which was classified as problematic, was found in mruby up to 3.4.0-rc2. Affected is the function scope_new of the file mrbgems/mruby-compiler/core/codegen.c of the component nregs Handler. The manipulation leads to heap-based buffer overflow. An attack has to be approached locally. The exploit has been disclosed to the public and may be used. The name of the patch is 1fdd96104180cc0fb5d3cb086b05ab6458911bb9. It is recommended to apply a patch to fix this issue.

(As written by CVE List.)

## Affected

- mruby: 3.4.0-rc1; 3.4.0-rc2
- mruby mruby: before 3.4.0; 3.4.0

## Every score

- VulDB: CVSS:4.0 4.8 Medium `CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:P`
- VulDB: CVSS:3.1 3.3 Low `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L/E:P/RL:O/RC:C`
- VulDB: CVSS:3.0 3.3 Low `CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L/E:P/RL:O/RC:C`
- VulDB: CVSS:2.0 1.7 Low `AV:L/AC:L/Au:S/C:N/I:N/A:P/E:POC/RL:OF/RC:C`
- NVD: CVSS:3.1 5.5 Medium `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`

## References

- <https://github.com/mruby/mruby/issues/6509> (exploit, issue-tracking)
- <https://github.com/mruby/mruby/issues/6509#event-17145516649> (exploit, issue-tracking)
- <https://github.com/user-attachments/files/19619499/mruby_crash.txt> (exploit)
- <https://vuldb.com/?id.315156> (technical-description, third-party-advisory, vdb-entry)
- <https://vuldb.com/?ctiid.315156> (permissions-required, signature, vdb-entry)
- <https://vuldb.com/?submit.607683> (third-party-advisory, vdb-entry)
- <https://github.com/mruby/mruby/commit/1fdd96104180cc0fb5d3cb086b05ab6458911bb9> (patch)

## Sources

- CVE List: [CVE-2025-7207](https://www.cve.org/CVERecord?id=CVE-2025-7207), CVE Terms of Use, modified 2025-07-09
- NVD: [CVE-2025-7207](https://nvd.nist.gov/vuln/detail/CVE-2025-7207), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2025-7207 · Whole record: https://cve.day/CVE-2025-7207.json · Rebuilt by cve.day 2026-11-25T22:59:00.991Z
