Authentication Credential Leakage in Ruby URI Gem
CVE-2025-27221
5.3MEDIUM
What is CVE-2025-27221?
The URI gem for Ruby, prior to version 1.0.3, exhibits a critical issue where authentication credentials can inadvertently leak due to improper handling during host changes. Specifically, methods such as URI.join, URI#merge, and URI#+ retain user information even after the host has been altered, potentially exposing sensitive data to unauthorized parties. Developers utilizing this gem should review their implementation to mitigate risks associated with this vulnerability.
Affected Version(s)
URI 0 < 0.11.3
URI 0.12.0 < 0.12.4
URI 0.13.0 < 0.13.2