{"id":"CVE-2022-39213","aliases":["CVE-2022-39213","GHSA-xhmf-mmv2-4hhx","GO-2022-1002"],"related":[],"kind":"vulnerability","state":"published","title":"Out-of-bounds Read in go-cvss","summary":"go-cvss is a Go module to manipulate Common Vulnerability Scoring System (CVSS). In affected versions when a full CVSS v2.0 vector string is parsed using `ParseVector`, an Out-of-Bounds Read is possible due to a lack of tests. The Go module will then panic. The problem is patched in tag `v0.4.0`, by the commit `d9d478ff0c13b8b09ace030db9262f3c2fe031f4`. Users are advised to upgrade. Users unable to upgrade may avoid this issue by parsing only CVSS v2.0 vector strings that do not have all attributes defined (e.g. `AV:N/AC:L/Au:N/C:P/I:P/A:C/E:U/RL:OF/RC:C/CDP:MH/TD:H/CR:M/IR:M/AR:M`). As stated in [SECURITY.md](https://github.com/pandatix/go-cvss/blob/master/SECURITY.md), the CPE v2.3 to refer to this Go module is `cpe:2.3:a:pandatix:go_cvss:*:*:*:*:*:*:*:*`. The entry has already been requested to the NVD CPE dictionary.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"go-cvss is a Go module to manipulate Common Vulnerability Scoring System (CVSS). In affected versions when a full CVSS v2.0 vector string is parsed using `ParseVector`, an Out-of-Bounds Read is possible due to a lack of tests. The Go module will then panic. The problem is patched in tag `v0.4.0`, by the commit `d9d478ff0c13b8b09ace030db9262f3c2fe031f4`. Users are advised to upgrade. Users unable to upgrade may avoid this issue by parsing only CVSS v2.0 vector strings that do not have all attributes defined (e.g. `AV:N/AC:L/Au:N/C:P/I:P/A:C/E:U/RL:OF/RC:C/CDP:MH/TD:H/CR:M/IR:M/AR:M`). As stated in [SECURITY.md](https://github.com/pandatix/go-cvss/blob/master/SECURITY.md), the CPE v2.3 to refer to this Go module is `cpe:2.3:a:pandatix:go_cvss:*:*:*:*:*:*:*:*`. The entry has already been requested to the NVD CPE dictionary.","source":"cvelist"},{"lang":"en","text":"### Impact\nWhen a full CVSS v2.0 vector string is parsed using `ParseVector`, an Out-of-Bounds Read is possible due to a lack of tests. The Go module will then panic.\n\n### Patches\nThe problem is patched in tag `v0.4.0`, by the commit `d9d478ff0c13b8b09ace030db9262f3c2fe031f4`.\n\n### Workarounds\nThe only way to avoid it is by parsing CVSS v2.0 vector strings that does not have all attributes defined (e.g. `AV:N/AC:L/Au:N/C:P/I:P/A:C/E:U/RL:OF/RC:C/CDP:MH/TD:H/CR:M/IR:M/AR:M`).\n\n### References\nN/A\n\n### CPE v2.3\nAs stated in [SECURITY.md](https://github.com/pandatix/go-cvss/blob/master/SECURITY.md), the CPE v2.3 to refer to this Go module is `cpe:2.3:a:pandatix:go_cvss:*:*:*:*:*:*:*:*`.\nThe entry has already been requested to the NVD CPE dictionnary.\n\n### Exploit example\n```go\npackage main\n\nimport (\n\t\"log\"\n\n\tgocvss20 \"github.com/pandatix/go-cvss/20\"\n)\n\nfunc main() {\n\t_, err := gocvss20.ParseVector(\"AV:N/AC:L/Au:N/C:P/I:P/A:C/E:U/RL:OF/RC:C/CDP:MH/TD:H/CR:M/IR:M/AR:M\")\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n}\n```\n\nWhen ran, the following trace is returned.\n```\npanic: runtime error: index out of range [3] with length 3\n\ngoroutine 1 [running]:\ngithub.com/pandatix/go-cvss/20.ParseVector({0x4aed6c?, 0x0?})\n        /home/lucas/go/pkg/mod/github.com/pandatix/go-cvss@v0.2.0/20/cvss20.go:54 +0x578\nmain.main()\n        /media/lucas/HDD-K/Documents/cve-2022-xxxxx/main.go:10 +0x25\nexit status 2\n```\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open an issue in [pandatix/go-cvss](https://github.com/pandatix/go-cvss/issues)\n* Email me at [lucastesson@protonmail.com](mailto:lucastesson@protonmail.com)","format":"markdown","source":"ghsa"},{"lang":"en","text":"ParseVector can panic when provided with invalid input.","format":"markdown","source":"go"},{"lang":"es","text":"go-cvss es un módulo Go para manipular el Sistema de Puntuación de Vulnerabilidad Común (CVSS). En las versiones afectadas, cuando es analizada una cadena de vectores CVSS versión v2.0 completa mediante \"ParseVector\", es posible que sea producida una lectura fuera de los límites debido a una falta de pruebas. El módulo Go entrará en pánico. El problema está parcheado en la etiqueta \"v0.4.0\", mediante el commit \"d9d478ff0c13b8b09ace030db9262f3c2fe031f4\". Es recomendado a usuarios actualizar. Los usuarios que no puedan actualizar pueden evitar este problema al analizar sólo las cadenas de vectores CVSS versión v2.0 que no tengan todos los atributos definidos (por ejemplo, \"AV:N/AC:L/Au:N/C:P/I:P/A:C/E:U/RL:OF/RC:C/CDP:MH/TD:H/CR:M/IR:M/AR:M\"). Como es indicado en [SECURITY.md](https://github.com/pandatix/go-cvss/blob/master/SECURITY.md), el CPE versión v2.3 para referirse a este módulo Go es \"cpe:2.3:a:pandatix:go_cvss:*:*:*:*:*\". La entrada ya ha sido solicitada al diccionario CPE de NVD","source":"nvd"}],"published":"2022-09-15T21:45:12.000Z","modified":"2026-06-17T04:57:55.683Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","score":7.5,"rating":"HIGH"}],"cwes":["CWE-125"],"affected":[{"ranges":[{"version":">= 0.2.0, < 0.4.0","status":"affected"}],"vendor":"pandatix","product":"go-cvss","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0.2.0","status":"affected","fixed":"0.4.0"}],"ecosystem":"Go","package":"github.com/pandatix/go-cvss","purl":"pkg:golang/github.com/pandatix/go-cvss","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.2.0","status":"affected","fixed":"0.4.0"}],"ecosystem":"Go","package":"github.com/pandatix/go-cvss","purl":"pkg:golang/github.com/pandatix/go-cvss","source":"go"},{"ranges":[{"status":"affected","introduced":"0.2.0","fixed":"0.4.0"}],"vendor":"pandatix","product":"go-cvss","cpe":"cpe:2.3:a:pandatix:go-cvss:*:*:*:*:*:go:*:*","source":"nvd"}],"references":[{"url":"https://github.com/pandatix/go-cvss/security/advisories/GHSA-xhmf-mmv2-4hhx","tags":["exploit","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/pandatix/go-cvss/commit/d9d478ff0c13b8b09ace030db9262f3c2fe031f4","tags":["fix","patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/pandatix/go-cvss/blob/master/SECURITY.md","tags":["third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-39213","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/pandatix/go-cvss","tags":["package"],"sources":["ghsa"]},{"url":"https://pkg.go.dev/vuln/GO-2022-1002","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"yes","technicalImpact":"partial","date":"2025-04-22T15:39:29.758Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-39213","url":"https://www.cve.org/CVERecord?id=CVE-2022-39213","licence":"CVE Terms of Use","modified":"2025-04-22T17:21:23.908Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-xhmf-mmv2-4hhx","url":"https://github.com/advisories/GHSA-xhmf-mmv2-4hhx","licence":"CC-BY-4.0","modified":"2023-11-08T04:10:15.059Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2022-1002","url":"https://pkg.go.dev/vuln/GO-2022-1002","licence":"CC-BY-4.0","modified":"2024-05-20T16:03:47.000Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-39213","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-39213","licence":"Public domain","modified":"2026-06-17T04:57:55.683Z"}],"updatedAt":"2026-11-25T22:58:14.965Z","epss":{"score":0.0184,"percentile":0.7961,"date":"2026-12-01T12:00:22.000Z"}}