UBUNTU-CVE-2019-25211: Critical severity ubuntu/golang-github-gin-contrib-cors vulnerability

Published Jun 29, 2024
·
Updated

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.

Affected Software

4 affected components
ubuntu/golang-github-gin-contrib-cors*
ubuntu/golang-github-gin-contrib-cors*
ubuntu/golang-github-gin-contrib-cors*
ubuntu/golang-github-gin-contrib-cors*

Event History

Jun 29, 2024
CVE Published
via OSV·12:15 AM
Data Sourced
via OSV·12:15 AM
DescriptionSeverityAffected Software

Frequently Asked Questions

1

Which applications are exposed to this issue?

Applications using the Gin-Gonic CORS middleware version before 1.6.0 are exposed if they configure wildcard origin rules intended to restrict requests to a specific origin pattern.

2

What does an attacker need to exploit the issue?

An attacker needs to make a request with an Origin value that matches the middleware's overly broad wildcard parsing. No authentication or user interaction is required according to the supplied severity vector.

3

Are default CORS settings affected?

The issue depends on use of wildcard origin rules. The provided information does not indicate that configurations without such rules are affected.

4

What can be done if updating is not immediately possible?

Avoid wildcard origin patterns and use explicit allowed origins instead, particularly for rules where a trailing wildcard is intended to apply only to a specific hostname or localhost.

5

How can I check whether an application is affected?

Check whether it uses Gin-Gonic CORS middleware before version 1.6.0 and whether its allowed-origin configuration includes trailing wildcard patterns. Test whether unintended origins such as https://example.community or http://localhost.example.com are accepted for patterns intended for https://example.com or http://localhost.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203