{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-5160","id":"CVE-2026-5160","title":"goldmark vulnerable to Cross-site Scripting (XSS)","description":"Versions of the package github.com/yuin/goldmark/renderer/html before 1.7.17 are vulnerable to Cross-site Scripting (XSS) due to improper ordering of URL validation and normalization. The renderer validates link destinations using a prefix-based check (IsDangerousURL) before resolving HTML entities. This allows an attacker to bypass protocol filtering by encoding dangerous schemes using HTML5 name","descriptionLong":"Versions of the package github.com/yuin/goldmark/renderer/html before 1.7.17 are vulnerable to Cross-site Scripting (XSS) due to improper ordering of URL validation and normalization. The renderer validates link destinations using a prefix-based check (IsDangerousURL) before resolving HTML entities. This allows an attacker to bypass protocol filtering by encoding dangerous schemes using HTML5 named character references. For example, a payload such as javascript&colon;alert(1) is not recognized as dangerous during validation, leading to arbitrary script execution in the context of applications that render the URL.","published":"2026-04-15T05:00:01.655Z","updated":"2026-10-28T02:31:03.361425749Z","reserved":"2026-03-30T14:14:48.647Z","status":"Analyzed","rejected":false,"assigner":"snyk","metric":{"version":"4.0","score":5.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:L/VA:N/SC:L/SI:L/SA:N","rating":"medium","source":"snyk"},"metrics":[{"version":"4.0","score":5.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:L/VA:N/SC:L/SI:L/SA:N","rating":"medium","source":"snyk"},{"version":"4.0","score":5.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:L/VA:N/SC:L/SI:L/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","rating":"medium","source":"snyk.io"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:L/VA:N/SC:L/SI:L/SA:N","rating":"unrated","source":"OSV"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:L/VA:N/SC:L/SI:L/SA:N","rating":"medium","source":"GitHub"},{"version":"3.1","score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","rating":"medium","source":"snyk"},{"version":"3.1","score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","rating":"medium","source":"snyk.io"},{"version":"3.1","score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","rating":"medium","source":"GitHub"}],"rating":"medium","products":["github.com/yuin/goldmark/renderer/html"],"affectedProducts":[{"vendor":"n/a","product":"github.com/yuin/goldmark/renderer/html","defaultStatus":null,"versions":[{"version":"0","lessThan":"1.7.17","status":"affected","versionType":"semver"}],"platforms":[]}],"packages":[{"ecosystem":"Go","name":"github.com/yuin/goldmark/renderer/html","purl":"pkg:golang/github.com/yuin/goldmark/renderer/html","ranges":["<1.7.17"],"fixed":["1.7.17"],"advisory":"GHSA-c97m-vxhj-p7j6"},{"ecosystem":"Go","name":"github.com/yuin/goldmark","purl":"pkg:golang/github.com/yuin/goldmark","ranges":["<1.7.17"],"fixed":["1.7.17"],"advisory":"GO-2026-5320"}],"cwes":["CWE-79"],"aliases":["GHSA-c97m-vxhj-p7j6","GO-2026-5320"],"references":[{"url":"https://security.snyk.io/vuln/SNYK-GOLANG-GITHUBCOMYUINGOLDMARKRENDERERHTML-15838406","tags":["Mitigation","Third Party Advisory","web"]},{"url":"https://github.com/yuin/goldmark/commit/cb46bbc4eca29d55aa9721e04ad207c23ccc44f9","tags":["Patch","fix","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/5xxx/CVE-2026-5160.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-5160","tags":["advisory"]},{"url":"https://github.com/yuin/goldmark","tags":["package"]},{"url":"https://github.com/advisories/GHSA-c97m-vxhj-p7j6","tags":["advisory"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial"},"epss":0.00292,"epssPercentile":0.22144,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-5160","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-5160","ok":true,"note":"Analyzed"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-5160","ok":true,"note":"2 packages"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-c97m-vxhj-p7j6","ok":true,"note":"GHSA-c97m-vxhj-p7j6"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-5160","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}