MediumGHSA-3vp4-m3rf-835hCVE-2023-26125

Improper input validation in github.com/gin-gonic/gin

Published 4 May 2023 · Updated 8 Nov 2023

Is your project on an affected github.com/gin-gonic/gin?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several Go apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Affected package

Affected
<1.9.0
Fixed in
1.9.0
Update to the fixed version for your release line, for example:go get github.com/gin-gonic/gin@v1.9.0

Details

Versions of the package github.com/gin-gonic/gin before version 1.9.0 are vulnerable to Improper Input Validation by allowing an attacker to use a specially crafted request via the X-Forwarded-Prefix header, potentially leading to cache poisoning.

Note: Although this issue does not pose a significant threat on its own it can serve as an input vector for other more impactful vulnerabilities. However, successful exploitation may depend on the server configuration and whether the header is used in the application logic.

Is GHSA-3vp4-m3rf-835h in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected github.com/gin-gonic/gin, and gives you the command that fixes it.

More advisories for github.com/gin-gonic/gin

  • CriticalCVE-2019-25211Gin mishandles a wildcard at the end of an origin string · 29 Jun 2024
  • MediumCVE-2023-29401Gin Web Framework does not properly sanitize filename parameter of Context.FileAttachment function · 12 May 2023
  • LowCVE-2023-29401Improper handling of filenames in Content-Disposition HTTP header in github.com/gin-gonic/gin · 11 May 2023
  • HighCVE-2020-36567Gin's default logger allows unsanitized input that can allow remote attackers to inject arbitrary log lines · 27 Dec 2022
  • HighCVE-2020-28483Inconsistent Interpretation of HTTP Requests in github.com/gin-gonic/gin · 23 Jun 2021
  • LowCVE-2020-36567Arbitrary log line injection in github.com/gin-gonic/gin · 14 Apr 2021
All 8 advisories for github.com/gin-gonic/gin

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.