{"id":"CVE-2024-24785","aliases":["CVE-2024-24785","GO-2024-2610","BIT-GOLANG-2024-24785"],"related":["CGA-gx7j-g27r-6grj"],"kind":"vulnerability","state":"published","title":"Errors returned from JSON marshaling may break template escaping in html/template","summary":"If errors returned from MarshalJSON methods contain user controlled data, they may be used to break the contextual auto-escaping behavior of the html/template package, allowing for subsequent actions to inject unexpected content into templates.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"If errors returned from MarshalJSON methods contain user controlled data, they may be used to break the contextual auto-escaping behavior of the html/template package, allowing for subsequent actions to inject unexpected content into templates.","source":"cvelist"},{"lang":"es","text":"Si los errores devueltos por los métodos MarshalJSON contienen datos controlados por el usuario, se pueden usar para romper el comportamiento de escape automático contextual del paquete html/template, permitiendo acciones posteriores para inyectar contenido inesperado en las plantillas.","source":"nvd"}],"published":"2024-03-05T22:15:40.000Z","modified":"2026-06-17T07:14:51.357Z","severity":{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N","score":5.4,"rating":"MEDIUM"},"severities":[{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N","score":5.4,"rating":"MEDIUM"},{"scorer":"Bitnami Vulnerability Database","scheme":"rating","rating":"MEDIUM"}],"cwes":["CWE-150"],"affected":[{"ranges":[{"type":"semver","introduced":"0","fixed":"1.21.8","status":"affected"},{"type":"semver","introduced":"1.22.0-0","fixed":"1.22.1","status":"affected"}],"vendor":"Go standard library","product":"html/template","package":"html/template","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.21.8"},{"type":"semver","introduced":"1.22.0-0","status":"affected","fixed":"1.22.1"}],"ecosystem":"Go","package":"stdlib","purl":"pkg:golang/stdlib","source":"go"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.21.8"},{"type":"semver","introduced":"1.22.0-0","status":"affected","fixed":"1.22.1"}],"ecosystem":"Bitnami","package":"golang","purl":"pkg:bitnami/golang","source":"bitnami"}],"references":[{"url":"https://go.dev/issue/65697","tags":["report","web","x-transferred"],"sources":["cvelist","go","nvd","bitnami"]},{"url":"https://go.dev/cl/564196","tags":["fix","web","x-transferred"],"sources":["cvelist","go","nvd","bitnami"]},{"url":"https://groups.google.com/g/golang-announce/c/5pwGVUPoMbg","tags":["web","x-transferred"],"sources":["cvelist","go","nvd","bitnami"]},{"url":"https://pkg.go.dev/vuln/GO-2024-2610","tags":["web","x-transferred"],"sources":["cvelist","nvd","bitnami"]},{"url":"https://security.netapp.com/advisory/ntap-20240329-0008/","tags":["web","x-transferred"],"sources":["cvelist","nvd","bitnami"]},{"url":"http://www.openwall.com/lists/oss-security/2024/03/08/4","tags":["web","x-transferred"],"sources":["cvelist","nvd","bitnami"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-24785","tags":["web"],"sources":["bitnami"]}],"credits":["RyotaK (https://ryotak.net)"],"assigner":"Go","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2024-03-06T18:49:44.784Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2024-24785","url":"https://www.cve.org/CVERecord?id=CVE-2024-24785","licence":"CVE Terms of Use","modified":"2025-03-14T00:55:26.398Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2024-2610","url":"https://pkg.go.dev/vuln/GO-2024-2610","licence":"CC-BY-4.0","modified":"2026-02-04T03:09:18.870Z"},{"source":"nvd","name":"NVD","id":"CVE-2024-24785","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-24785","licence":"Public domain","modified":"2026-06-17T07:14:51.357Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-GOLANG-2024-24785","url":"https://osv.dev/vulnerability/BIT-GOLANG-2024-24785","licence":"Apache-2.0","modified":"2026-01-28T03:41:11.881Z"}],"updatedAt":"2026-11-25T22:58:37.286Z","epss":{"score":0.00789,"percentile":0.5741,"date":"2026-12-01T12:00:22.000Z"}}