CVE-2019-25211 json
Gin mishandles a wildcard at the end of an origin string
published 2024-06-28 2 y ago modified 2026-06-17 4 mo ago also GHSA-869c-j7wc-8jqv , GO-2024-2955 , EUVD-2024-1974
- cvss
- 9.1
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.4%
- EPSS 0.4% chance of exploitation in 30 days, percentile 37%
- public exploits
- 0
- none known
Summary
parseWildcardRules in Gin-Gonic CORS middleware before 1.6.0 mishandles a wildcard at the end of an origin string, e.g., https://example.community/* is allowed when the intention is that only https://example.com/* should be allowed, and http://localhost.example.com/* is allowed when the intention is that only http://localhost/* should be allowed.
Patch / fix
- go github.com/gin-gonic/gin 1.6.0
- go github.com/gin-contrib/cors 1.6.0
- gin-contrib cors 1.6.0
- golang-github-gin-contrib-cors Debian 12 1.4.0-1+deb12u1
- golang-github-gin-contrib-cors Debian 13 1.4.0-1+deb13u1
debian advisories DEBIAN-CVE-2019-25211
- golang-github-gin-contrib-cors Ubuntu 22.04 LTS 1.3.1-1+deb11u1build0.22.04.1
- golang-github-gin-contrib-cors Ubuntu Pro 20.04 LTS 1.3.0-2ubuntu0.1~esm1
- golang-github-gin-contrib-cors Ubuntu Pro 24.04 LTS 1.4.0-1ubuntu0.1~esm1
ubuntu advisories UBUNTU-CVE-2019-25211
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- github.com/gin-contrib/cors@27b723a commit
- github.com/gin-contrib/cors#57 pull request
- github.com/gin-contrib/cors#106 pull request
- github.com/gin-contrib/cors/releases/tag/v1.6.0 release
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2019-25211 updated cvss 6.5
github.com/gin-contrib/cors: Gin mishandles a wildcard in the origin string in github.com/gin-contrib/cors
-
Red Hat Migration Toolkit for Virtualization migration-toolkit-virtualization/mtv-api-rhel9, migration-toolkit-virtualization/mtv-rhel8-operator, migration-toolkit-virtualization/mtv-virt-v2v-rhel9, migration-toolkit-virtualization/mtv-controller-rhel9, migration-toolkit-virtualization/mtv-validation-rhel9, migration-toolkit-virtualization/mtv-rhv-populator-rhel8, +4 moreaffected: workaround, no fix available “Fix deferred”
-
Red Hat Migration Toolkit 1.8 rhmtc/openshift-migration-controller-rhel8 v1.8.4-22fixed: vendor fix RHSA-2024:7164
-
Red Hat Migration Toolkit 1.8 rhmtc/openshift-migration-ui-rhel8 v1.8.4-10, rhmtc/openshift-migration-openvpn-rhel8 v1.8.4-10, rhmtc/openshift-migration-registry-rhel8 v1.8.4-11, rhmtc/openshift-migration-rhel8-operator v1.8.4-16, rhmtc/openshift-migration-operator-bundle v1.8.4-33, rhmtc/openshift-migration-hook-runner-rhel8 v1.8.4-8, +4 morenot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- yes
- Technical impact
- total
- Assessed
- 2 y ago
Exploit prediction
0.43% chance of exploitation in the next 30 days, higher than 37% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CISA ADP | 3.1 | 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
| CNA | 3.1 | 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
| GitHub | 3.1 | 9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| go | github.com/gin-gonic/gin | <1.6.0 |
1.6.0 |
| go | github.com/gin-contrib/cors | <1.6.0 |
1.6.0 |
Affected products
- gin-contrib cors
Classification
- Weakness
-
- CWE-346 Origin Validation Error
References
-
github.com
/gin-contrib/cors/pull/57
web, patch
-
github.com
/gin-contrib/cors/pull/106
web, patch
-
github.com
/gin-contrib/cors/commit/27b723a473efd80d5a498fa9f5933c80204c850d
web, patch
-
github.com
/gin-contrib/cors/compare/v1.5.0...v1.6.0
web
-
github.com
/gin-contrib/cors/releases/tag/v1.6.0
web
-
lists.debian.org
/debian-lts-announce/2025/08/msg00024.html
web
-
nvd.nist.gov
/vuln/detail/CVE-2019-25211
advisory
-
github.com
/gin-gonic/gin
package
-
github.com
/advisories/GHSA-869c-j7wc-8jqv
advisory
Sources
- CVE List CVE-2019-25211
- GitHub Advisory GHSA-869c-j7wc-8jqv
- NVD CVE-2019-25211
- OSV GO-2024-2955
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.