{"id":"GHSA-vfvf-mqq8-rwqc","summary":"Sanitization bypass using HTML Entities in marked","details":"Affected versions of `marked` are susceptible to a cross-site scripting vulnerability in link components when `sanitize:true` is configured. \n\n## Proof of Concept\n\nThis flaw exists because link URIs containing HTML entities get processed in an abnormal manner. Any HTML Entities get parsed on a best-effort basis and included in the resulting link, while if that parsing fails that character is omitted.\n\nFor example:\n\nA link URI such as\n```\njavascript&#x58document;alert&#40;1&#41;\n```\nRenders a valid link that when clicked will execute `alert(1)`.\n\n\n## Recommendation\n\nUpdate to version 0.3.6 or later.","aliases":["CVE-2016-10531"],"modified":"2023-11-01T04:46:34.395363Z","published":"2019-02-18T23:58:20Z","database_specific":{"nvd_published_at":null,"cwe_ids":["CWE-79"],"severity":"MODERATE","github_reviewed":true,"github_reviewed_at":"2020-06-16T21:57:38Z"},"references":[{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2016-10531"},{"type":"WEB","url":"https://github.com/chjj/marked/pull/592"},{"type":"WEB","url":"https://github.com/chjj/marked/pull/592/commits/2cff85979be8e7a026a9aca35542c470cf5da523"},{"type":"ADVISORY","url":"https://github.com/advisories/GHSA-vfvf-mqq8-rwqc"},{"type":"WEB","url":"https://www.npmjs.com/advisories/101"}],"affected":[{"package":{"name":"marked","ecosystem":"npm","purl":"pkg:npm/marked"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"0.3.6"}]}],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2019/02/GHSA-vfvf-mqq8-rwqc/GHSA-vfvf-mqq8-rwqc.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V3","score":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N"}]}