{"id":"CVE-2018-5773","aliases":["EUVD-2018-0089","GHSA-p6h9-gw49-rqm4","PYSEC-2018-13","openSUSE-SU-2024:11237-1","openSUSE-SU-2024:14146-1","openSUSE-SU-2026:12016-1"],"status":"published","title":"markdown2 is vulnerable to cross-site scripting","description":"An issue was discovered in markdown2 (aka python-markdown2) through 2.3.5. The safe_mode feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final '\u003e' character from an IMG tag.","severity":{"version":"3.0","score":6.1,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","level":"medium","assessor":"primary","from":"nvd"},"epss":{"day":"2026-11-09","score":0.00819,"percentile":0.57466,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-79"],"published":"2018-01-18T21:00:00Z","modified":"2026-10-20T10:50:28Z","fixes":[{"ecosystem":"PyPI","package":"markdown2","fixed_in":["2.3.6"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"PyPI","package":"markdown2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.3.6"}]}]},{"source":"osv","ecosystem":"PyPI","package":"markdown2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.3.6"}]}],"versions":["1.0.1.10","1.0.1.11","1.0.1.12","1.0.1.13","1.0.1.14","1.0.1.15","1.0.1.16","1.0.1.17","1.0.1.18","1.0.1.19","1.0.1.6","1.0.1.7","1.0.1.8","1.0.1.9","1.1.0","1.1.1","1.2.0","1.3.0","1.3.1","1.4.0","1.4.1","1.4.2","2.0.0","2.0.1","2.1.0","2.2.0","2.2.1","2.2.2","2.2.3","2.3.0","2.3.1","2.3.2","2.3.3","2.3.4","2.3.5"]},{"source":"osv","ecosystem":"PyPI","package":"markdown2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.3.6"}]}],"versions":["1.0.1.10","1.0.1.11","1.0.1.12","1.0.1.13","1.0.1.14","1.0.1.15","1.0.1.16","1.0.1.17","1.0.1.18","1.0.1.19","1.0.1.6","1.0.1.7","1.0.1.8","1.0.1.9","1.1.0","1.1.1","1.2.0","1.3.0","1.3.1","1.4.0","1.4.1","1.4.2","2.0.0","2.0.1","2.1.0","2.2.0","2.2.1","2.2.2","2.2.3","2.3.0","2.3.1","2.3.2","2.3.3","2.3.4","2.3.5"]},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"python-markdown2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.4.0-2.4"}]}],"bundled":2},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"python-markdown2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.4.13-1.2"}]}],"bundled":2},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"python-markdown2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.5-1.3"}]}],"bundled":2}],"products":[{"vendor":"python-markdown2_project","product":"python-markdown2"}],"references":[{"url":"https://github.com/trentm/python-markdown2/issues/285","tags":["x_refsource_MISC","x_transferred","Third Party Advisory","advisory","web","report"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2018-5773","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-p6h9-gw49-rqm4","tags":["advisory"]},{"url":"https://github.com/google/osv/issues/430","tags":["web"]},{"url":"https://github.com/trentm/python-markdown2/pull/303","tags":["web"]},{"url":"https://github.com/trentm/python-markdown2/blob/master/CHANGES.md#python-markdown2-236","tags":["web"]},{"url":"https://github.com/trentm/python-markdown2/commit/1b1dcdd727c0ef03453b9f5ef5ae3679f1d72323","tags":["web"]},{"url":"https://github.com/pypa/advisory-database/tree/main/vulns/markdown2/PYSEC-2018-13.yaml","tags":["web"]},{"url":"https://github.com/trentm/python-markdown2","tags":["package"]},{"url":"","tags":["advisory"]},{"url":"https://www.suse.com/security/cve/CVE-2018-5773","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2021-26813","tags":["web"]}],"sources":{"cve":[{"id":"CVE-2018-5773","description":"An issue was discovered in markdown2 (aka python-markdown2) through 2.3.5. The safe_mode feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final '\u003e' character from an IMG tag.","status":"published","published":"2018-01-18T21:00:00Z","modified":"2024-09-16T17:47:46.652Z","updated_at":"2026-11-02T14:35:00.948726Z"}],"euvd":[{"id":"EUVD-2018-0089","description":"An issue was discovered in markdown2 (aka python-markdown2) through 2.3.5. The safe_mode feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final '\u003e' character from an IMG tag.","status":"published","published":"2018-01-18T21:00:00Z","modified":"2024-09-16T17:47:46Z","updated_at":"2026-11-03T00:55:38.742114Z"}],"ghsa":[{"id":"GHSA-p6h9-gw49-rqm4","title":"markdown2 is vulnerable to cross-site scripting","description":"An issue was discovered in `markdown2` (aka python-markdown2) through 2.3.5. The `safe_mode` feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final `\u003e` character from an IMG tag.","status":"published","published":"2018-07-12T20:29:21Z","modified":"2024-09-30T17:00:48Z","cvss":[{"version":"4.0","score":5.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","level":"medium"},{"version":"3.0","score":6.1,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:38:06.988799Z"}],"nvd":[{"id":"CVE-2018-5773","description":"An issue was discovered in markdown2 (aka python-markdown2) through 2.3.5. The safe_mode feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final '\u003e' character from an IMG tag.","status":"published","published":"2018-01-18T21:29:00.267Z","modified":"2026-06-17T02:00:45.443Z","cvss":[{"version":"3.0","score":6.1,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","level":"medium","assessor":"primary"},{"version":"2.0","score":4.3,"vector":"AV:N/AC:M/Au:N/C:N/I:P/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:04:22.309028Z"}],"osv":[{"id":"CVE-2018-5773","description":"An issue was discovered in markdown2 (aka python-markdown2) through 2.3.5. The safe_mode feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final '\u003e' character from an IMG tag.","status":"published","published":"2018-01-18T21:29:00.267Z","modified":"2026-10-20T10:50:28.963473553Z","cvss":[{"version":"3.0","score":6.1,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","level":"medium"}],"updated_at":"2026-11-02T15:44:09.442568Z"},{"id":"GHSA-p6h9-gw49-rqm4","title":"markdown2 is vulnerable to cross-site scripting","description":"An issue was discovered in `markdown2` (aka python-markdown2) through 2.3.5. The `safe_mode` feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final `\u003e` character from an IMG tag.","status":"published","published":"2018-07-12T20:29:21Z","modified":"2024-09-30T17:23:16.99172Z","cvss":[{"version":"3.0","score":6.1,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","level":"medium"},{"version":"4.0","score":5.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:46:52.891208Z"},{"id":"openSUSE-SU-2024:11237-1","title":"python36-markdown2-2.4.0-2.4 on GA media","description":"These are all security issues fixed in the python36-markdown2-2.4.0-2.4 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2024-06-15T00:00:00Z","modified":"2026-02-04T03:55:06.870993Z","updated_at":"2026-11-02T16:58:34.894275Z"},{"id":"openSUSE-SU-2024:14146-1","title":"python310-markdown2-2.4.13-1.2 on GA media","description":"These are all security issues fixed in the python310-markdown2-2.4.13-1.2 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2024-07-12T00:00:00Z","modified":"2026-02-04T02:31:20.860257Z","updated_at":"2026-11-02T16:58:36.662953Z"},{"id":"openSUSE-SU-2026:12016-1","title":"python313-markdown2-2.5.5-1.3 on GA media","description":"These are all security issues fixed in the python313-markdown2-2.5.5-1.3 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2026-10-04T00:00:00Z","modified":"2026-10-05T10:15:56.076614494Z","updated_at":"2026-11-02T16:58:40.245664Z"},{"id":"PYSEC-2018-13","description":"An issue was discovered in markdown2 (aka python-markdown2) through 2.3.5. The safe_mode feature, which is supposed to sanitize user input against XSS, is flawed and does not escape the input properly. With a crafted payload, XSS can be triggered, as demonstrated by omitting the final '\u003e' character from an IMG tag.","status":"published","published":"2018-01-18T21:29:00Z","modified":"2023-11-08T04:00:20.84057Z","updated_at":"2026-11-02T15:52:51.645172Z"}]}}
