{ "CVE_data_meta": { "ASSIGNER": "security-advisories@github.com", "ID": "CVE-2022-41919", "STATE": "PUBLIC", "TITLE": "Fastify vulnerable to Cross-Site Request Forgery (CSRF) attack via incorrect content type" }, "affects": { "vendor": { "vendor_data": [ { "product": { "product_data": [ { "product_name": "fastify", "version": { "version_data": [ { "version_value": ">= 4.0.0, < 4.10.2" }, { "version_value": ">= 3.0.0, < 3.29.4" } ] } } ] }, "vendor_name": "fastify" } ] } }, "data_format": "MITRE", "data_type": "CVE", "data_version": "4.0", "description": { "description_data": [ { "lang": "eng", "value": "Fastify is a web framework with minimal overhead and plugin architecture. The attacker can use the incorrect `Content-Type` to bypass the `Pre-Flight` checking of `fetch`. `fetch()` requests with Content-Type\u2019s essence as \"application/x-www-form-urlencoded\", \"multipart/form-data\", or \"text/plain\", could potentially be used to invoke routes that only accepts `application/json` content type, thus bypassing any CORS protection, and therefore they could lead to a Cross-Site Request Forgery attack. This issue has been patched in version 4.10.2 and 3.29.4. As a workaround, implement Cross-Site Request Forgery protection using `@fastify/csrf'." } ] }, "impact": { "cvss": { "attackComplexity": "HIGH", "attackVector": "NETWORK", "availabilityImpact": "NONE", "baseScore": 4.2, "baseSeverity": "MEDIUM", "confidentialityImpact": "LOW", "integrityImpact": "LOW", "privilegesRequired": "NONE", "scope": "UNCHANGED", "userInteraction": "REQUIRED", "vectorString": "CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:N", "version": "3.1" } }, "problemtype": { "problemtype_data": [ { "description": [ { "lang": "eng", "value": "CWE-352: Cross-Site Request Forgery (CSRF)" } ] } ] }, "references": { "reference_data": [ { "name": "https://github.com/fastify/fastify/security/advisories/GHSA-3fjj-p79j-c9hh", "refsource": "CONFIRM", "url": "https://github.com/fastify/fastify/security/advisories/GHSA-3fjj-p79j-c9hh" }, { "name": "https://github.com/fastify/fastify/commit/62dde76f1f7aca76e38625fe8d983761f26e6fc9", "refsource": "MISC", "url": "https://github.com/fastify/fastify/commit/62dde76f1f7aca76e38625fe8d983761f26e6fc9" }, { "name": "https://www.npmjs.com/package/@fastify/csrf", "refsource": "MISC", "url": "https://www.npmjs.com/package/@fastify/csrf" } ] }, "source": { "advisory": "GHSA-3fjj-p79j-c9hh", "discovery": "UNKNOWN" } }