GO-2021-0052

Source
https://pkg.go.dev/vuln/GO-2021-0052
Import Source
https://vuln.go.dev/ID/GO-2021-0052.json
JSON Data
https://api.test.osv.dev/v1/vulns/GO-2021-0052
Aliases
Published
2021-04-14T20:04:52Z
Modified
2025-01-08T07:26:52.423404Z
Summary
Inconsistent interpretation of HTTP Requests in github.com/gin-gonic/gin
Details

Due to improper HTTP header sanitization, a malicious user can spoof their source IP address by setting the X-Forwarded-For header. This may allow a user to bypass IP based restrictions, or obfuscate their true source.

Database specific
{
    "review_status": "REVIEWED",
    "url": "https://pkg.go.dev/vuln/GO-2021-0052"
}
References
Credits
    • @sorenisanerd

Affected packages

Go / github.com/gin-gonic/gin

Package

Name
github.com/gin-gonic/gin
View open source insights on deps.dev
Purl
pkg:golang/github.com/gin-gonic/gin

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
1.7.7

Ecosystem specific

{
    "imports": [
        {
            "path": "github.com/gin-gonic/gin",
            "symbols": [
                "Context.ClientIP",
                "Context.Next",
                "Context.RemoteIP",
                "Engine.HandleContext",
                "Engine.Run",
                "Engine.RunFd",
                "Engine.RunListener",
                "Engine.RunTLS",
                "Engine.RunUnix",
                "Engine.ServeHTTP"
            ]
        }
    ]
}