CVE-2024-45258
vulnerability analysis and mitigation

Overview

The req package before version 3.43.4 for Go contains a vulnerability where it may send unintended requests when a malformed URL is provided. This occurs because the cleanHost function in http.go intentionally uses a "garbage in, garbage out" design. The vulnerability was discovered and disclosed in August 2024 (NVD).

Technical details

The vulnerability exists in the URL parsing mechanism of the req library. When malformed URLs are provided, inconsistencies between how the net/url and req libraries parse URLs can lead to the failure of defensive strategies. The CVSS v3.1 score for this vulnerability is 9.8 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H (CISA-ADP).

Impact

The vulnerability can lead to security threats such as Server-Side Request Forgery (SSRF) and Remote Code Execution (RCE). This is particularly impactful because the req library is widely used, and the vulnerability can help attackers bypass protections that developers have set up for schemes and hosts (GitHub Commit).

Mitigation and workarounds

The vulnerability has been fixed in version 3.43.4 of the req package. The fix involves improving the handling of malformed URLs and preventing successful requests to invalid hosts. Users should upgrade to version 3.43.4 or later to receive the security patch (GitHub Compare).

Additional resources


SourceThis report was generated using AI

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

“Best User Experience I have ever seen, provides full visibility to cloud workloads.”
David EstlickCISO
“Wiz provides a single pane of glass to see what is going on in our cloud environments.”
Adam FletcherChief Security Officer
“We know that if Wiz identifies something as critical, it actually is.”
Greg PoniatowskiHead of Threat and Vulnerability Management