CVE-2022-31038
MEDIUM 5.4CVSS 3.1Cross-site Scripting vulnerability in repository issue list in Gogs
Gogs is an open source self-hosted Git service. In versions of gogs prior to 0.12.9 DisplayName does not filter characters input from users, which leads to an XSS vulnerability when directly displayed in the issue list. This issue has been resolved in commit 155cae1d which sanitizes DisplayName prior to display to the user. All users of gogs are advised to upgrade. Users unable to upgrade should check their users' display names for malicious characters.
- Published
- 9 Jun 2022
- Last modified
- 17 Jun 2026
- Assigned by
- security-advisories@github.com
- NVD status
- Modified
- Weakness
- CWE-79CWE-80
- Also known as
- GHSA-xq4v-vrp9-vcf2GO-2022-0483
- Sources
- NVDJSONOSV GHSA-xq4v-vrp9-vcf2JSONOSV GO-2022-0483JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | security-advisories@github.com (Secondary) | CVSS 3.1 | MEDIUM 5.4 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N |
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | MEDIUM 5.4 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N |
| OSV | GitHub | CVSS 3.1 | MEDIUM 5.4 | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | LOW 3.5 | AV:N/AC:M/Au:S/C:N/I:P/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | gogs | gogscpe:2.3:a:gogs:gogs:*:*:*:*:*:*:*:* |
< 0.12.9 | 0.12.9 |
| OSV | Go | gogs.io/gogs | < 0.12.9 | 0.12.9 |
References
- https://github.com/gogs/gogs/commit/155cae1de8916fc3fde78f350763034b7422caee · Patch, Third Party Advisory, WEB
- https://github.com/gogs/gogs/pull/7009 · Issue Tracking, Third Party Advisory, WEB
- https://github.com/gogs/gogs/security/advisories/GHSA-xq4v-vrp9-vcf2 · Issue Tracking, Third Party Advisory, WEB, ADVISORY
- https://nvd.nist.gov/vuln/detail/CVE-2022-31038 · ADVISORY
- https://github.com/gogs/gogs · PACKAGE
- https://github.com/gogs/gogs/releases/tag/v0.12.9 · WEB
History
- 25 Nov 2026 20:34 UTC · NVD: first stored (published 9 Jun 2022)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 8 Jun 2022)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 21 Aug 2024)