{"id":"CVE-2019-25211","aliases":["DEBIAN-CVE-2019-25211","DLA-4285-1","EUVD-2024-1974","GHSA-869c-j7wc-8jqv","GO-2024-2955","UBUNTU-CVE-2019-25211","USN-8983-1"],"status":"published","title":"Gin mishandles a wildcard at the end of an origin string","description":"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.","severity":{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical","assessor":"adp","from":"cve"},"epss":{"day":"2026-11-08","score":0.00431,"percentile":0.37642,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-346"],"published":"2024-06-28T00:00:00Z","modified":"2026-11-04T03:43:14Z","fixes":[{"ecosystem":"Go","package":"github.com/gin-gonic/gin","fixed_in":["1.6.0"],"sources":["ghsa","osv"]},{"ecosystem":"Go","package":"github.com/gin-contrib/cors","fixed_in":["1.6.0"],"sources":["ghsa","osv"]},{"ecosystem":"Debian:12","package":"golang-github-gin-contrib-cors","fixed_in":["1.4.0-1+deb12u1"],"sources":["osv"]},{"ecosystem":"Debian:13","package":"golang-github-gin-contrib-cors","fixed_in":["1.4.0-1+deb13u1"],"sources":["osv"]},{"ecosystem":"Debian:11","package":"golang-github-gin-contrib-cors","fixed_in":["1.3.1-1+deb11u1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:20.04:LTS","package":"golang-github-gin-contrib-cors","fixed_in":["1.3.0-2ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:22.04:LTS","package":"golang-github-gin-contrib-cors","fixed_in":["1.3.1-1+deb11u1build0.22.04.1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:24.04:LTS","package":"golang-github-gin-contrib-cors","fixed_in":["1.4.0-1ubuntu0.1~esm1"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"Go","package":"github.com/gin-gonic/gin","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0"}]}]},{"source":"ghsa","ecosystem":"Go","package":"github.com/gin-contrib/cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.0"}]}]},{"source":"osv","ecosystem":"Debian:12","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.0-1+deb12u1"}]}],"versions":["1.4.0-1"]},{"source":"osv","ecosystem":"Debian:13","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.0-1+deb13u1"}]}],"versions":["1.4.0-1"]},{"source":"osv","ecosystem":"Debian:11","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.1-1+deb11u1"}]}],"versions":["1.3.1-1"]},{"source":"osv","ecosystem":"Go","package":"github.com/gin-gonic/gin","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.6.0"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gin-contrib/cors","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.6.0"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gin-contrib/cors","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.6.0"}]}]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.0-2ubuntu0.1~esm1"}]}],"versions":["1.3.0-2"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.1-1+deb11u1build0.22.04.1"}]}],"versions":["1.3.1-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:24.04:LTS","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.0-1ubuntu0.1~esm1"}]}],"versions":["1.4.0-1"]},{"source":"osv","ecosystem":"Ubuntu:25.10","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.4.0-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.0-2ubuntu0.1~esm1"}]}],"versions":["1.3.0-2"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.1-1+deb11u1build0.22.04.1"}]}],"versions":["1.3.1-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:24.04:LTS","package":"golang-github-gin-contrib-cors","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.4.0-1ubuntu0.1~esm1"}]}],"versions":["1.4.0-1"]}],"products":[{"vendor":"gin-contrib","product":"cors"}],"references":[{"url":"https://github.com/gin-contrib/cors/pull/57","tags":["x_transferred","fix","web","report"]},{"url":"https://github.com/gin-contrib/cors/pull/106","tags":["x_transferred","fix","web","report"]},{"url":"https://github.com/gin-contrib/cors/compare/v1.5.0...v1.6.0","tags":["x_transferred","web","report"]},{"url":"https://github.com/gin-contrib/cors/releases/tag/v1.6.0","tags":["x_transferred","web","report"]},{"url":"https://github.com/gin-contrib/cors/commit/27b723a473efd80d5a498fa9f5933c80204c850d","tags":["x_transferred","fix","web","report"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/08/msg00024.html","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2019-25211","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-869c-j7wc-8jqv","tags":["advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2019-25211","tags":["advisory"]},{"url":"https://github.com/gin-gonic/gin","tags":["package"]},{"url":"https://ubuntu.com/security/CVE-2019-25211","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2019-25211","tags":["report"]},{"url":"https://ubuntu.com/security/notices/USN-8983-1","tags":["advisory"]}],"sources":{"cve":[{"id":"CVE-2019-25211","description":"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.","status":"published","published":"2024-06-28T00:00:00Z","modified":"2025-11-03T18:07:54.695Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical","assessor":"adp"}],"cwes":["CWE-346"],"updated_at":"2026-11-02T14:20:19.737165Z"}],"euvd":[{"id":"EUVD-2024-1974","description":"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.","status":"published","published":"2024-06-28T00:00:00Z","modified":"2025-11-03T18:07:54Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"}],"updated_at":"2026-11-02T19:49:35.000596Z"}],"ghsa":[{"id":"GHSA-869c-j7wc-8jqv","title":"Gin mishandles a wildcard at the end of an origin string","description":"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.","status":"published","published":"2024-06-29T06:31:40Z","modified":"2025-11-03T22:47:04Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"},{"version":"4.0","score":9.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","level":"critical"}],"cwes":["CWE-346"],"updated_at":"2026-11-02T14:39:05.278442Z"}],"nvd":[{"id":"CVE-2019-25211","description":"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.","status":"published","published":"2024-06-29T00:15:02.107Z","modified":"2026-06-17T02:31:45.35Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical","assessor":"secondary"}],"cwes":["CWE-346"],"updated_at":"2026-11-02T14:05:49.099942Z"}],"osv":[{"id":"CVE-2019-25211","description":"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.","status":"published","published":"2024-06-29T00:15:02.107Z","modified":"2026-10-20T10:51:39.147458817Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"}],"updated_at":"2026-11-02T15:44:12.363788Z"},{"id":"DEBIAN-CVE-2019-25211","description":"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.","status":"published","published":"2024-06-29T00:15:02.107Z","modified":"2026-10-14T06:00:04.398812549Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"}],"updated_at":"2026-11-02T15:45:32.221385Z"},{"id":"GHSA-869c-j7wc-8jqv","title":"Gin mishandles a wildcard at the end of an origin string","description":"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.","status":"published","published":"2024-06-29T06:31:40Z","modified":"2025-11-03T22:47:01Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"},{"version":"4.0","score":9.3,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N","level":"critical"}],"cwes":["CWE-346"],"updated_at":"2026-11-02T15:46:42.077781Z"},{"id":"UBUNTU-CVE-2019-25211","description":"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.","status":"published","published":"2024-06-29T00:15:00Z","modified":"2026-11-04T03:30:06.67080561Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"}],"updated_at":"2026-11-04T03:56:45.249606Z"},{"id":"DLA-4285-1","title":"golang-github-gin-contrib-cors - security update","status":"published","published":"2025-08-28T00:00:00Z","modified":"2026-03-09T02:10:32.442461Z","updated_at":"2026-11-02T15:46:12.7027Z"},{"id":"GO-2024-2955","title":"Gin mishandles a wildcard in the origin string in github.com/gin-contrib/cors","description":"Gin-Gonic CORS middleware mishandles a wildcard at the end of an origin string. Examples: https://example.community/* is accepted by the origin string https://example.com/* and http://localhost.example.com/* is accepted by the origin string http://localhost/* .","status":"published","published":"2024-07-02T19:23:53Z","modified":"2024-07-02T19:57:15.180688Z","updated_at":"2026-11-02T15:47:01.453823Z"},{"id":"USN-8983-1","title":"golang-github-gin-contrib-cors vulnerability","description":"It was discovered that the Gin CORS middleware incorrectly handled\nwildcards at the end of origin strings. A remote attacker could possibly\nuse this issue to bypass the configured origin restrictions.","status":"published","published":"2026-11-03T17:35:44Z","modified":"2026-11-04T03:43:14.199616348Z","updated_at":"2026-11-04T03:56:18.279609Z"}]}}
