CVE Index中文
L3 · ShartedRefitter · code generation · RCErefitter-schema-injection

Refitter schema fields can inject executable C# into generated clients

GHSA-h924-jfhp-9vjr reports code injection through schema names, discriminators, defaults and enums. A malicious OpenAPI document produces compiling code whose module initializer executes when its assembly loads. No fixed release is listed.

Disclosed
Nov 17, 2026
Public disclosure date
Severity
Sharted
1 CVE tracked here
Splash zone
Developers/CI consuming attacker-influenced OpenAPI; tested 2.3.1 and 2.4.0-preview.126
dotnet
In the wild
Not seen
Public reproduction; no confirmed in-the-wild attacks in the reviewed sources.

What happened

The advisory reproduces execution on two releases; it does not demonstrate every intermediate version. L3 reflects a public code-generation exploit.

The independently read 2.4.0 template still interpolates Discriminator inside the JsonPolymorphic attribute without an escaping operation at that insertion. This corroborates the advisory’s source-level concern for that release, rather than claiming a new runtime reproduction. The code also loads NJsonSchema and NSwag template assemblies. Treat generated source as a trust boundary; a successful compile does not establish safety.

Isolation is a general precaution, not a confirmed complete workaround.

What’s in the bowl

GHSA-h924-jfhp-9vjr

Schema-to-C# injection

Default validation misses schema-derived literal/value sinks; assembly loading triggers execution without calling the client.

Fixed versions

ProductSafe fromNote
RefitterNo fixNo patch listed; endpoints tested, intermediate releases not tested

Crime-scene timeline

  1. Nov 17, 2026

    Maintainer publishes the advisory

Who said what

We list each claim and who made it. Primary sources (the vendor, the researcher, the registry) are marked. Where reports disagree, we grade by the worst credible case.