{"id":"CVE-2021-22540","state":"PUBLISHED","title":"XSS in Dart SDK","description":"Bad validation logic in the Dart SDK versions prior to 2.12.3 allow an attacker to use an XSS attack via DOM clobbering. The validation logic in dart:html for creating DOM nodes from text did not sanitize properly when it came across template tags.","publishedAt":"2021-04-22T14:15:17.000Z","updatedAt":"2024-08-03T18:44:14.025Z","severity":null,"assigner":"Google","products":["Google LLC Dart SDK"],"affected":[{"vendor":"Google LLC","product":"Dart SDK","versions":[{"version":"stable","status":"affected","lessThan":"2.12.3","versionType":"custom"}]}],"references":["https://github.com/dart-lang/sdk/security/advisories/GHSA-3rfv-4jvg-9522","https://github.com/dart-lang/sdk/commit/ce5a1c2392debce967415d4c09359ff2555e3588"],"weaknesses":["CWE-79"],"ingestedAt":"2026-10-29T19:48:02.192Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2021/22xxx/CVE-2021-22540.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.1","cveMetadata":{"cveId":"CVE-2021-22540","state":"PUBLISHED","datePublished":"2021-04-22T14:15:17.000Z","dateUpdated":"2024-08-03T18:44:14.025Z","assignerShortName":"Google","assignerOrgId":"14ed7db2-1595-443d-9d34-6215bf890778","dateReserved":"2021-01-05T00:00:00.000Z"},"containers":{"cna":{"title":"XSS in Dart SDK","descriptions":[{"lang":"en","value":"Bad validation logic in the Dart SDK versions prior to 2.12.3 allow an attacker to use an XSS attack via DOM clobbering. The validation logic in dart:html for creating DOM nodes from text did not sanitize properly when it came across template tags."}],"affected":[{"vendor":"Google LLC","product":"Dart SDK","versions":[{"version":"stable","status":"affected","lessThan":"2.12.3","versionType":"custom"}]}],"references":[{"url":"https://github.com/dart-lang/sdk/security/advisories/GHSA-3rfv-4jvg-9522","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/dart-lang/sdk/commit/ce5a1c2392debce967415d4c09359ff2555e3588","tags":["x_refsource_CONFIRM"]}],"problemTypes":[{"descriptions":[{"cweId":"CWE-79","description":"CWE-79: Improper Neutralization of Input During Web Page Generation","lang":"en","type":"CWE"}]}],"providerMetadata":{"shortName":"Google","dateUpdated":"2021-04-22T14:15:17.000Z","orgId":"14ed7db2-1595-443d-9d34-6215bf890778"},"credits":[{"lang":"en","value":"Vincenzo di Cicco"}],"source":{"discovery":"EXTERNAL"},"x_legacyV4Record":{"CVE_data_meta":{"ASSIGNER":"security@google.com","ID":"CVE-2021-22540","STATE":"PUBLIC","TITLE":"XSS in Dart SDK"},"affects":{"vendor":{"vendor_data":[{"product":{"product_data":[{"product_name":"Dart SDK","version":{"version_data":[{"version_affected":"<","version_name":"stable","version_value":"2.12.3"}]}}]},"vendor_name":"Google LLC"}]}},"credit":[{"lang":"eng","value":"Vincenzo di Cicco"}],"data_format":"MITRE","data_type":"CVE","data_version":"4.0","description":{"description_data":[{"lang":"eng","value":"Bad validation logic in the Dart SDK versions prior to 2.12.3 allow an attacker to use an XSS attack via DOM clobbering. The validation logic in dart:html for creating DOM nodes from text did not sanitize properly when it came across template tags."}]},"problemtype":{"problemtype_data":[{"description":[{"lang":"eng","value":"CWE-79: Improper Neutralization of Input During Web Page Generation"}]}]},"references":{"reference_data":[{"name":"https://github.com/dart-lang/sdk/security/advisories/GHSA-3rfv-4jvg-9522","refsource":"CONFIRM","url":"https://github.com/dart-lang/sdk/security/advisories/GHSA-3rfv-4jvg-9522"},{"name":"https://github.com/dart-lang/sdk/commit/ce5a1c2392debce967415d4c09359ff2555e3588","refsource":"CONFIRM","url":"https://github.com/dart-lang/sdk/commit/ce5a1c2392debce967415d4c09359ff2555e3588"}]},"source":{"discovery":"EXTERNAL"}}},"adp":[{"title":"CVE Program Container","references":[{"url":"https://github.com/dart-lang/sdk/security/advisories/GHSA-3rfv-4jvg-9522","tags":["x_refsource_CONFIRM","x_transferred"]},{"url":"https://github.com/dart-lang/sdk/commit/ce5a1c2392debce967415d4c09359ff2555e3588","tags":["x_refsource_CONFIRM","x_transferred"]}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2024-08-03T18:44:14.025Z"}}]}}}