CVE-2021-46703 — Code injection in RazorEngine — CVE Details
CRITICAL
Code injection in RazorEngine
Published March 7, 2022Updated March 26, 2025Source: osv
Summary
In the IsolatedRazorEngine component of Antaris RazorEngine through 4.5.1-alpha001, an attacker can execute arbitrary .NET code in a sandboxed environment (if users can externally control template contents). NOTE: This vulnerability only affects products that are no longer supported by the maintainer.
Advisory Timeline
- First published March 7, 2022 (1680 days ago).
- Last revised March 26, 2025 — 1116 days after initial publication.
Affected Packages (1)
Affects 1 ecosystem: nuget (1).
| Package | Ecosystem | Affected | Fixed In |
|---|---|---|---|
| RazorEngine | nuget | 2.1.0, 3.0.0, 3.0.3, 3.0.4 (+80 more) | Range-based data available |
Vulnerability Classification
Common Weakness Enumeration (CWE) identifiers for this vulnerability type.
- CWE-1336
CVSS Score Breakdown
What the CVSS (Common Vulnerability Scoring System) 9.8 score means for each attack dimension.
Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
References
Frequently Asked Questions
- What is CVE-2021-46703?
- Code injection in RazorEngine This vulnerability has been assigned a severity rating of CRITICAL (CVSS score: 9.8/10).
- How do I check if my project is affected by CVE-2021-46703?
- CVE-2021-46703 affects RazorEngine. Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2021-46703 and 200,000+ other known vulnerabilities.
Severity & Exploitability
CVSS Score
9.8
Exploitation is straightforward and causes maximum impact. Patch immediately.
Also Known As
GHSA-ph3v-2hq5-5qfq
Related CVEs
- CVE-2026-75513CRITICAL
Marten's LINQ provider has SQL injection via unescaped string literals
- CVE-2026-105794CRITICAL
MsQuic: Improper Certificate Validation in Microsoft.Native.Quic.MsQuic.OpenSSL
Check if you're affected
Scan your dependencies to see if this vulnerability affects your projects.
Scan Your Dependencies