Refitter allows code execution through unescaped OpenAPI header parameter names
Affected
| Package | Affected versions | Fixed in |
|---|---|---|
| nuget:Refitter | < 2.1.2 | 2.1.2 |
Refitter emits the spec's header parameter name (parameters[].name with in: header) verbatim into a Refit [Header(" ")] attribute string without escaping ". A crafted value survives Refitter's default OpenAPI validation, breaks out of the attribute and the enclosing interface + namespace, injects a top-level file class with a [ModuleInitializer] method, and reopens so the file stays valid. .NET runs [ModuleInitializer] methods at assembly load, so the attacker's code executes at application sta…
Read on GitHub Advisory Database
On 11/20/2026, 09:06 AM, GitHub Advisory Database published "Refitter allows code execution through unescaped OpenAPI header parameter names" (type: Advisory). Severity is "Critical" (critical). Related technologies: .NET / C#. CVE: CVE-2026-63346.