{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-59861","id":"CVE-2026-59861","title":"Kiota: Code Generation Literal Injection in Kiota Ruby Generator","description":"Kiota is an OpenAPI based HTTP Client code generator. Prior to 1.29.1 and 1.32.0, Kiota's Ruby generator embedded OpenAPI default fields, property names, and other schema-derived strings through CodeMethodWriter.cs and SanitizeForQuotedLiteral() in Writers/StringExtensions.cs into Ruby double-quoted literals without escaping #, allowing attacker-controlled #{expr}, #$var, or #@var interpolation ma","descriptionLong":"Kiota is an OpenAPI based HTTP Client code generator. Prior to 1.29.1 and 1.32.0, Kiota's Ruby generator embedded OpenAPI default fields, property names, and other schema-derived strings through CodeMethodWriter.cs and SanitizeForQuotedLiteral() in Writers/StringExtensions.cs into Ruby double-quoted literals without escaping #, allowing attacker-controlled #{expr}, #$var, or #@var interpolation markers to inject arbitrary Ruby code into generated model classes. This issue is fixed in version 1.29.1 and 1.32.0.","published":"2026-07-16T14:36:32.010Z","updated":"2026-11-07T02:48:32.881631178Z","reserved":"2026-07-07T15:41:53.606Z","status":"Deferred","rejected":false,"assigner":"GitHub_M","metric":{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"GitHub_M"},"metrics":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"GitHub_M"},{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"github.com"},{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"OSV"},{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","rating":"high","source":"GitHub"}],"rating":"high","products":["microsoft kiota"],"affectedProducts":[{"vendor":"microsoft","product":"kiota","defaultStatus":null,"versions":[{"version":">= 1.30.0, < 1.31.1","status":"affected"},{"version":"< 1.29.1","status":"affected"}],"platforms":[]}],"packages":[{"ecosystem":"NuGet","name":"Microsoft.OpenAPI.Kiota","purl":"pkg:nuget/Microsoft.OpenAPI.Kiota","ranges":[">=1.30.0 <1.32.0"],"fixed":["1.32.0"],"advisory":"GHSA-xg2h-5xr2-29jw"},{"ecosystem":"NuGet","name":"Microsoft.OpenAPI.Kiota.Builder","purl":"pkg:nuget/Microsoft.OpenAPI.Kiota.Builder","ranges":[">=1.30.0 <1.32.0"],"fixed":["1.32.0"],"advisory":"GHSA-xg2h-5xr2-29jw"},{"ecosystem":"NuGet","name":"Microsoft.OpenApi.Kiota","purl":"pkg:nuget/Microsoft.OpenApi.Kiota","ranges":["<1.29.1"],"fixed":["1.29.1"],"advisory":"GHSA-xg2h-5xr2-29jw"},{"ecosystem":"NuGet","name":"Microsoft.OpenApi.Kiota.Builder","purl":"pkg:nuget/Microsoft.OpenApi.Kiota.Builder","ranges":["<1.29.1"],"fixed":["1.29.1"],"advisory":"GHSA-xg2h-5xr2-29jw"}],"cwes":["CWE-94"],"aliases":["GHSA-xg2h-5xr2-29jw"],"references":[{"url":"https://github.com/microsoft/kiota/security/advisories/GHSA-xg2h-5xr2-29jw","tags":["x_refsource_CONFIRM","advisory","web"]},{"url":"https://github.com/microsoft/kiota/pull/7746","tags":["x_refsource_MISC","fix","web"]},{"url":"https://github.com/microsoft/kiota/commit/fee1b648bb4394ba7ba72de9c0ce4f2a0bad0cb6","tags":["x_refsource_MISC","fix","web"]},{"url":"https://github.com/microsoft/kiota/releases/tag/v1.32.0","tags":["x_refsource_MISC","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/59xxx/CVE-2026-59861.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-59861","tags":["advisory"]},{"url":"https://github.com/microsoft/kiota","tags":["package"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"yes","technicalImpact":"total"},"epss":0.02048,"epssPercentile":0.81634,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-59861","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-59861","ok":true,"note":"Deferred"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-59861","ok":true,"note":"4 packages"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-xg2h-5xr2-29jw","ok":true,"note":"GHSA-xg2h-5xr2-29jw"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-59861","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}