CVE-2025-71405: 
Datadog Agent vulnerability analysis and mitigation

Overview

CVE-2025-71405 is a Host Header Injection leading to Open Redirect vulnerability in the RedirectSlashes middleware of the go-chi/chi Go HTTP router framework. All chi versions before v5.2.2 are affected; v5.2.2 is the patched release. The vulnerability was disclosed on June 20, 2025 (GHSA published) and added to NVD on August 14, 2026. It carries a CVSS v4.0 base score of 5.1 (Medium), assigned by VulnCheck (GitHub Advisory, GitHub Advisory DB).

Technical details

The root cause is CWE-601 (URL Redirection to Untrusted Site / Open Redirect). The RedirectSlashes function in middleware/strip.go constructs the redirect URL using the HTTP Host header directly (at line 55 of the source file) without validating that the header value matches the application's expected host. An unauthenticated attacker can send an HTTP request with a crafted Host header (e.g., Host: attacker.com) to any path that triggers the RedirectSlashes middleware, causing the server to issue a redirect response pointing to the attacker-controlled domain. Exploitation requires no privileges but does require active user interaction (the victim must follow the redirect), and notably cannot be triggered from standard browsers or email clients without explicit Host header manipulation — limiting its practical attack surface to scenarios such as server-side request forgery chains or misconfigured proxies (GitHub Advisory).

Impact

Successful exploitation allows an attacker to redirect users from a trusted application domain to an arbitrary attacker-controlled host, enabling phishing attacks, credential harvesting, and potential malware distribution. The confidentiality and integrity of the vulnerable system are partially impacted (low), while availability is unaffected. There is no direct system compromise or lateral movement risk, but the social engineering potential is significant when users trust the originating application's domain (GitHub Advisory, GitHub Advisory DB).

Exploitability

A proof-of-concept (PoC) is publicly documented in the GitHub security advisory, demonstrating exploitation via curl with a crafted Host header. CISA's SSVC assessment classifies exploitation as "poc" with non-automatable, partial technical impact. There is no evidence of active in-the-wild exploitation or threat actor attribution at this time. The EPSS score is approximately 0.307% (23rd percentile), indicating a low near-term exploitation probability. The vulnerability is not listed in the CISA KEV catalog (GitHub Advisory, GitHub Advisory DB).

Exploitation steps

  1. Identify target: Locate a web application built with go-chi/chi versions before v5.2.2 that uses the RedirectSlashes middleware (e.g., via source code review, dependency scanning, or HTTP response fingerprinting).
  2. Identify a triggering path: Find any URL path ending with a trailing slash (or lacking one, depending on middleware configuration) that would cause RedirectSlashes to issue a redirect — for example, http://target.com/somepath/.
  3. Craft the malicious request: Send an HTTP request to the target with a forged Host header pointing to an attacker-controlled domain:
    curl -iL -H "Host: attacker.com" http://target.com/somepath/
  4. Observe redirect: The server responds with a 301/302 redirect to http://attacker.com/somepath (or similar), constructed using the attacker-supplied Host header value.
  5. Deliver to victim: Craft a scenario (e.g., via a misconfigured reverse proxy, SSRF, or social engineering) where the victim's HTTP client follows the redirect to the attacker-controlled host, landing on a phishing page designed to steal credentials or deliver malware (GitHub Advisory).

Indicators of compromise

  • Network: HTTP requests to application endpoints with Host header values that do not match the application's configured domain; redirect responses (301/302) pointing to external or unexpected domains originating from the chi application server.
  • Logs: Web server or application access logs showing requests with anomalous Host header values (e.g., Host: attacker.com) against paths handled by RedirectSlashes middleware; Location response headers in logs pointing to external domains not owned by the organization.
  • Application Behavior: Unexpected outbound redirect chains from the application to third-party domains, particularly following requests to paths with trailing slashes.

Mitigation and workarounds

Upgrade go-chi/chi to version v5.2.2 or later, which resolves the issue by using r.RequestURI instead of r.Host to construct redirect URLs in the RedirectSlashes middleware. As a workaround for deployments that cannot immediately upgrade, implement Host header validation at the reverse proxy or application layer to ensure only expected hostnames are accepted. Additionally, consider adding HTTP Strict-Transport-Security (HSTS) headers and reviewing application logs for suspicious redirect patterns (GitHub Advisory, GitHub Advisory DB).

Community reactions

The vulnerability was reported by security researcher anuraagbaishya and published by go-chi maintainer VojtechVitek via GitHub's security advisory process. The advisory notes this is considered lower-severity because exploitation requires Host header manipulation, which is not possible from standard browsers or email clients. No significant broader media coverage or notable community debate has been identified beyond the advisory itself (GitHub Advisory).

Additional resources

Linux Distribution fix status

Fix availability across major Linux distributions and their releases.

Debian

Fixed

bookworm

golang-github-go-chi-chi

Affected

sid

golang-github-go-chi-chi: 5.2.3-1

Fixed

trixie

golang-github-go-chi-chi

Affected

Ubuntu

Unknown

devel

golang-github-go-chi-chi

Unknown

jammy

golang-github-go-chi-chi

Unknown

jammy (esm-apps)

golang-github-go-chi-chi

Unknown

noble

golang-github-go-chi-chi

Unknown

noble (esm-apps)

golang-github-go-chi-chi

Unknown

resolute

golang-github-go-chi-chi

Unknown

resolute (esm-apps)

golang-github-go-chi-chi

Unknown

RHEL / CentOS

Affected

OpenShift

Not Affected

RHEL 8

Not Affected

Source: This report was generated using AI

Related Datadog Agent vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-48702HIGH7.5
  • Datadog Agent logoDatadog Agent
  • docker-29
NoYesAug 13, 2026
CVE-2026-71557MEDIUM6.3
  • Packer logoPacker
  • rancher-fleet-0.13
NoYesAug 07, 2026
CVE-2026-61711MEDIUM5.3
  • Docker logoDocker
  • buildah
NoYesAug 19, 2026
CVE-2025-71405MEDIUM5.1
  • Datadog Agent logoDatadog Agent
  • rclone
NoYesAug 14, 2026
CVE-2026-61712LOW2.3
  • Docker logoDocker
  • skaffold-fips
NoYesAug 19, 2026

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