Advisory

GHSA-869c-j7wc-8jqv

Also known as: CVE-2019-25211, GO-2024-2955

Summary

Gin mishandles a wildcard at the end of an origin string

Details

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

Critical Basis: The source's own band: CRITICAL

Dates

Published
2024-06-29 06:31 UTC
Modified
2025-11-03 22:47 UTC

Affected packages and fixes

github.com/gin-gonic/gin

Go · All systems

Affected

  • introduced 0, fixed 1.6.0 (semver)

Fixed versions

1.6.0

Fix

github.com/gin-contrib/cors

Go · All systems

Affected

  • introduced 0, fixed 1.6.0 (semver)

Fixed versions

1.6.0

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences