{"schemaVersion":4,"id":"CVE-2023-23627","aliases":["UBUNTU-CVE-2023-23627","DEBIAN-CVE-2023-23627","GHSA-fw3g-2h3j-qmm7"],"status":"published","duplicateOf":null,"title":"Sanitize vulnerable to Cross-site Scripting via Improper neutralization of `noscript` element","description":"Sanitize is an allowlist-based HTML and CSS sanitizer. Versions 5.0.0 and later, prior to 6.0.1, are vulnerable to Cross-site Scripting. When Sanitize is configured with a custom allowlist that allows `noscript` elements, attackers are able to include arbitrary HTML, resulting in XSS (cross-site scripting) or other undesired behavior when that HTML is rendered in a browser. The default configurations do not allow `noscript` elements and are not vulnerable. This issue only affects users who are using a custom config that adds `noscript` to the element allowlist. This issue has been patched in version 6.0.1. Users who are unable to upgrade can prevent this issue by using one of Sanitize's default configs or by ensuring that their custom config does not include `noscript` in the element allowlist.","dates":{"published":"2023-01-27T23:44:17.617Z","modified":"2025-03-10T21:17:49.562Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":6.1,"severity":"medium","version":"3.1","versionLabel":"v3.1","source":"CVE.org","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","computed":false,"selection":"backend-summary"},"metrics":[{"version":"3.1","versionLabel":"v3.1","source":"CVE.org","score":6.1,"severity":"medium","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","exploitability":null,"impact":null,"computed":false},{"version":"3.1","versionLabel":"v3.1","source":"OSV · Ubuntu","score":6.1,"severity":"medium","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","exploitability":7.2,"impact":4.5,"computed":true},{"version":"3.1","versionLabel":"v3.1","source":"OSV · Debian","score":6.1,"severity":"medium","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","exploitability":7.2,"impact":4.5,"computed":true},{"version":"3.1","versionLabel":"v3.1","source":"OSV · Rubygems","score":6.1,"severity":"medium","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","exploitability":7.2,"impact":4.5,"computed":true},{"version":"3.1","versionLabel":"v3.1","source":"NVD","score":6.1,"severity":"medium","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","exploitability":null,"impact":null,"computed":false}]},"epss":{"probability":0.0056,"percentile":0.48018,"severity":"low","asOf":"2026-12-04T00:00:00.000Z","change":{"pp":0.03499999999999996,"baselineDate":"2026-11-04T00:00:00.000Z","baselineScore":0.00525},"history":[{"date":"2026-09-14T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-15T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-16T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-17T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-18T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-19T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-20T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-21T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-22T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-23T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-24T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-25T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-26T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-27T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-28T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-29T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-30T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-10-31T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-01T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-02T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-03T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-04T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-05T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-06T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-07T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-08T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-09T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-10T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-11T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-12T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-13T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-14T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-15T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-16T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-17T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-18T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-19T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-20T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-21T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-22T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-23T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-24T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-25T00:00:00.000Z","score":0.00571,"percentile":null},{"date":"2026-11-26T00:00:00.000Z","score":0.00571,"percentile":null},{"date":"2026-11-27T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-11-28T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-11-29T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-11-30T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-12-01T00:00:00.000Z","score":0.0056,"percentile":null},{"date":"2026-12-02T00:00:00.000Z","score":0.0056,"percentile":null},{"date":"2026-12-03T00:00:00.000Z","score":0.0056,"percentile":null},{"date":"2026-12-04T00:00:00.000Z","score":0.0056,"percentile":0.48018}],"last30":[{"date":"2026-11-04T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-05T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-06T00:00:00.000Z","score":0.00525,"percentile":null},{"date":"2026-11-07T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-08T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-09T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-10T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-11T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-12T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-13T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-14T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-15T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-16T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-17T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-18T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-19T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-20T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-21T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-22T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-23T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-24T00:00:00.000Z","score":0.00539,"percentile":null},{"date":"2026-11-25T00:00:00.000Z","score":0.00571,"percentile":null},{"date":"2026-11-26T00:00:00.000Z","score":0.00571,"percentile":null},{"date":"2026-11-27T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-11-28T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-11-29T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-11-30T00:00:00.000Z","score":0.00574,"percentile":null},{"date":"2026-12-01T00:00:00.000Z","score":0.0056,"percentile":null},{"date":"2026-12-02T00:00:00.000Z","score":0.0056,"percentile":null},{"date":"2026-12-03T00:00:00.000Z","score":0.0056,"percentile":null},{"date":"2026-12-04T00:00:00.000Z","score":0.0056,"percentile":0.48018}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[],"exploitCount":0,"weaknesses":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation","description":"The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.","type":"weakness","status":"Stable","abstraction":"Base","likelihoodOfExploit":"High","url":"https://cwe.mitre.org/data/definitions/79.html"}],"affected":[{"vendor":"debian","product":"ruby-sanitize","name":"ruby-sanitize","label":"ruby-sanitize","ecosystem":"Debian","cpePart":null,"purl":"pkg:deb/debian/ruby-sanitize","purlType":"deb","versions":[{"text":"< 6.0.0-1.1","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":null,"startInclusive":true,"end":"6.0.0-1.1","endInclusive":false}}],"versionsText":"< 6.0.0-1.1","eol":null,"hubHref":null},{"vendor":"ubuntu","product":"ruby-sanitize","name":"ruby-sanitize","label":"ruby-sanitize","ecosystem":"Ubuntu","cpePart":null,"purl":"pkg:deb/ubuntu/ruby-sanitize","purlType":"deb","versions":[{"text":"< 4.6.6-2.1~0.20.04.2","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":null,"startInclusive":true,"end":"4.6.6-2.1~0.20.04.2","endInclusive":false}},{"text":"< 6.0.0-1ubuntu0.1","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":null,"startInclusive":true,"end":"6.0.0-1ubuntu0.1","endInclusive":false}}],"versionsText":"< 4.6.6-2.1~0.20.04.2 | < 6.0.0-1ubuntu0.1","eol":null,"hubHref":null},{"vendor":"RubyGems","product":"sanitize","name":"sanitize","label":"sanitize","ecosystem":"RubyGems","cpePart":null,"purl":"pkg:gem/sanitize","purlType":"gem","versions":[{"text":"≥ 5.0.0, < 6.0.1","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"5.0.0","startInclusive":true,"end":"6.0.1","endInclusive":false}}],"versionsText":"≥ 5.0.0, < 6.0.1","eol":null,"hubHref":null},{"vendor":"rgrove","product":"sanitize","name":"sanitize","label":"sanitize","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≥ 5.0.0, < 6.0.1","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"5.0.0","startInclusive":true,"end":"6.0.1","endInclusive":false}}],"versionsText":"≥ 5.0.0, < 6.0.1","eol":null,"hubHref":"/vendor/rgrove/sanitize"},{"vendor":"sanitize_project","product":"sanitize","name":"sanitize","label":"sanitize","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≥ 5.0.0, < 6.0.1","noFixRecorded":false,"fixedIn":null,"bounds":{"kind":"range","start":"5.0.0","startInclusive":true,"end":"6.0.1","endInclusive":false}}],"versionsText":"≥ 5.0.0, < 6.0.1","eol":null,"hubHref":"/vendor/sanitize_project/sanitize"}],"affectedCount":5,"eol":{"hasEol":false,"count":0},"references":[{"url":"https://github.com/rgrove/sanitize/security/advisories/GHSA-fw3g-2h3j-qmm7","label":"github.com/rgrove/sanitize/security/advisories/GHSA-fw3g-2h3j-qmm7","hostname":"github.com","tags":["X Refsource CONFIRM","REPORT","WEB","Mitigation","Release Notes","Third Party Advisory"]},{"url":"https://ubuntu.com/security/CVE-2023-23627","label":"ubuntu.com/security/CVE-2023-23627","hostname":"ubuntu.com","tags":["REPORT"]},{"url":"https://github.com/rgrove/sanitize/commit/ec14265e530dc3fe31ce2ef773594d3a97778d22","label":"github.com/rgrove/sanitize/commit/ec14265e530dc3fe31ce2ef773594d3a97778d22","hostname":"github.com","tags":["REPORT","WEB"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2023-23627","label":"www.cve.org/CVERecord?id=CVE-2023-23627","hostname":"www.cve.org","tags":["REPORT"]},{"url":"https://ubuntu.com/security/notices/USN-6748-1","label":"ubuntu.com/security/notices/USN-6748-1","hostname":"ubuntu.com","tags":["Advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2023-23627","label":"security-tracker.debian.org/tracker/CVE-2023-23627","hostname":"security-tracker.debian.org","tags":["Advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-23627","label":"nvd.nist.gov/vuln/detail/CVE-2023-23627","hostname":"nvd.nist.gov","tags":["Advisory"]},{"url":"https://github.com/rgrove/sanitize","label":"github.com/rgrove/sanitize","hostname":"github.com","tags":["PACKAGE"]},{"url":"https://github.com/rubysec/ruby-advisory-db/blob/master/gems/sanitize/CVE-2023-23627.yml","label":"github.com/rubysec/ruby-advisory-db/blob/master/gems/sanitize/CVE-2023-23627.yml","hostname":"github.com","tags":["WEB"]}],"lineage":{"upstream":[],"downstream":["USN-6748-1"],"duplicates":[],"related":["USN-6748-1"]},"timeline":[{"kind":"published","date":"2023-01-27T23:44:17.617Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2025-03-10T21:17:49.562Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"priority":{"label":"routine","tag":null,"reason":"Not severe (CVSS 6.1, network access); no exploitation reported by the 5 checked sources","nextStep":"Fix in the normal cadence","rank":[0,0,0,0,1,61],"checkedSources":["cisa","enisa","circl","shadowserver","cisa-adp"],"evidence":[{"type":"epss","source":"FIRST","date":"2026-12-04T00:00:00.000Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"value":0.0056,"stale":false,"promoted":null},{"type":"cvss","source":"cve.org","date":"2025-03-10T21:17:49.562Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","version":"3.1","headline":true},{"type":"cvss","source":"osv_ubuntu","date":"2025-03-10T21:17:49.562Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","version":"3.1"},{"type":"cvss","source":"osv_debian","date":"2025-03-10T21:17:49.562Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","version":"3.1"},{"type":"cvss","source":"osv_rubygems","date":"2025-03-10T21:17:49.562Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","version":"3.1"},{"type":"cvss","source":"nvd","date":"2025-03-10T21:17:49.562Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","version":"3.1"},{"type":"adp","source":"cisa-adp","date":"2025-03-10T20:58:50.279Z","status":"valid","statusDate":null,"statusSource":null,"disputes":[],"exploitation":"none"}],"epss":{"value":0.0056,"date":"2026-12-04T00:00:00.000Z","stale":false,"promoted":null},"sources":[{"id":"cisa","lastSuccessfulSync":"2026-12-05T07:02:00.704Z","state":"fresh"},{"id":"enisa","lastSuccessfulSync":"2026-12-05T07:02:01.187Z","state":"fresh"},{"id":"circl","lastSuccessfulSync":"2026-12-05T07:02:01.389Z","state":"fresh"},{"id":"shadowserver","lastSuccessfulSync":null,"state":"unavailable"},{"id":"cisa-adp","lastSuccessfulSync":"2026-12-05T07:01:05.155Z","state":"fresh"},{"id":"epss","lastSuccessfulSync":"2026-12-05T07:01:59.185Z","state":"fresh"},{"id":"osv","lastSuccessfulSync":"2026-12-05T07:01:58.234Z","state":"fresh"}],"feedEvent":null},"meta":{"dataAsOf":"2026-12-05T07:24:12.207Z","stale":false,"partial":false}}