CVE-2026-48054: Insecure Code Generation Test Injection

Directly interpolating variables into generated code templates using surrounding quotes (e.g., `"${variable}"`) enables code injection if the input contains unescaped quote or backslash characters. Securely serialize dynamic values into the generated code using robust methods like `JSON.stringify()` or specific compiler-aware escaping functions, and remove t

Provally CuratedPublic repositoryHighMedium confidenceVerifiedApache-2.0JS
greprules fetch cve-2026-48054-insecure-code-generation-test-injection --engine opengrep

Description

Directly interpolating variables into generated code templates using surrounding quotes (e.g., `"${variable}"`) enables code injection if the input contains unescaped quote or backslash characters. Securely serialize dynamic values into the generated code using robust methods like `JSON.stringify()` or specific compiler-aware escaping functions, and remove t