CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



GHSA-VHJ5-X93P-67JW

GHSA-vhj5-x93p-67jw: Host Header Poisoning and Open Redirect in actix-web-lab

Alon Barad
Alon Barad
Software Engineer

Mar 11, 2026·5 min read·26 visits

Executive Summary (TL;DR)

actix-web-lab middleware uses unvalidated Host headers for HTTP redirects, enabling Open Redirect attacks. Version 0.26.0 introduces an allowlist mechanism that must be explicitly configured by developers to secure the application.

The actix-web-lab crate prior to version 0.26.0 contains a host header poisoning vulnerability in its redirect middleware components. Attackers can manipulate the incoming HTTP Host header or forwarding headers to dictate the Location header in the application's redirect responses. This mechanism results in an Open Redirect vulnerability, allowing attackers to route users to arbitrary, untrusted domains.

Vulnerability Overview

The actix-web-lab package is a collection of experimental extractors and middleware for the Actix Web framework in Rust. It provides utility functions that often graduate to the main actix-web crate. Among these utilities are the RedirectHttps, RedirectToWww, and RedirectToNonWww middlewares, which handle automatic URL redirection for canonicalization and security upgrades.

These specific middlewares are vulnerable to host header poisoning (CWE-601). They construct absolute redirect URLs using unvalidated host information derived from the incoming HTTP request. This information is typically extracted from the Host header or forwarding headers like X-Forwarded-Host.

Because the framework implicitly trusts these headers without validation, an attacker can supply arbitrary domains. The middleware incorporates the malicious domain into the Location header of the HTTP response. This behavior creates an Open Redirect vulnerability, permitting attackers to redirect users to untrusted external sites.

Root Cause Analysis

The root cause of this vulnerability is the direct use of the req.connection_info().host() method to build absolute URIs for HTTP redirection. The connection_info() function extracts the host from the request headers, which are entirely user-controlled.

When the middleware processes an incoming request, it evaluates whether a redirect is necessary. For example, RedirectHttps checks if the current request scheme is HTTP. If a redirect is required, the middleware retrieves the host string and concatenates it with the requested path to form the target URL.

No sanitization or validation is performed on the host string before it is interpolated into the Location header. If the server environment passes the Host or X-Forwarded-Host headers directly to the application without a strictly configured reverse proxy, the application inherits the manipulated values. This architectural reliance on client-provided headers for sensitive routing decisions enables the exploitation.

Code Analysis

Prior to version 0.26.0, the middleware implementations instantiated redirects by blindly trusting the connection info. The vulnerable logic effectively extracted the host and path, combined them, and issued a 307 or 308 redirect status code.

// Vulnerable logic pattern in actix-web-lab redirect middleware
let host = req.connection_info().host();
let path = req.uri().path();
let target_uri = format!("https://{}{}", host, path);
return Ok(Redirect::to(target_uri).respond_to(&req));

The patch introduced in commit 142c28b82eb59b67445a859a2a9b75e01a9964ee resolves this by adding a HostAllowlist structure and a validation routine. The reject_untrusted_host function verifies the incoming host against the configured allowlist.

// New validation function introduced in src/redirect_host.rs
pub(crate) fn reject_untrusted_host(
    configured_allowlist: Option<&HostAllowlist>,
    host: &str,
) -> Option<HttpResponse<()>> {
    if configured_allowlist.is_some_and(|allowlist| !allowlist.contains(host)) {
        return Some(HttpResponse::with_body(StatusCode::BAD_REQUEST, ()));
    }
    None
}

If an allowlist is present and the host does not match, the middleware aborts the redirect and returns a 400 Bad Request. This strict validation prevents arbitrary domains from entering the response headers.

Exploitation Methodology

Exploitation requires an attacker to identify a target application utilizing the vulnerable actix-web-lab middleware. The attacker must then craft an HTTP request targeting an endpoint that triggers the redirection logic, such as an HTTP endpoint when RedirectHttps is enforced.

The attacker modifies the HTTP request to include a malicious Host header. If the target server sits behind a reverse proxy that normalizes the Host header, the attacker may alternative inject an X-Forwarded-Host header, provided the proxy forwards it and the Actix application is configured to trust it.

GET /login HTTP/1.1
Host: malicious-domain.com

The vulnerable middleware processes this request, constructs the absolute URI using the malicious domain, and returns an HTTP 307 or 308 redirect. The victim's browser, upon receiving this response, automatically navigates to the attacker-controlled server.

HTTP/1.1 307 Temporary Redirect
Location: https://malicious-domain.com/login

Impact Assessment

The primary impact of this vulnerability is an Open Redirect, which facilitates sophisticated phishing and social engineering campaigns. Attackers can distribute seemingly legitimate links pointing to the trusted application domain. When victims click these links, the server explicitly instructs their browsers to navigate to an attacker-controlled site.

This mechanism degrades user trust and bypasses security training that teaches users to verify the initial domain in a URL. The vulnerability holds a CVSS v3.1 score of 6.1 (Medium), reflecting the requirement for user interaction and the limited direct impact on the server's confidentiality or integrity.

While the server infrastructure itself is not compromised, the application becomes an active participant in attacks against its user base. This can lead to credential theft if the attacker's site perfectly mimics the target application's authentication portal.

Remediation and Mitigation

To remediate this vulnerability, developers must upgrade the actix-web-lab crate to version 0.26.0 or later. However, upgrading the dependency alone is insufficient. The patch is not secure by default and requires explicit configuration to enable the protection.

Developers must implement the .allow_hosts() method on all instances of the redirect middleware. This method accepts an array of trusted domains. Applications failing to configure this allowlist remain vulnerable even after the crate is updated.

use actix_web_lab::middleware::RedirectHttps;
 
App::new()
    .wrap(RedirectHttps::default().allow_hosts(["example.com", "www.example.com"]))

In environments where code changes cannot be immediately deployed, operators can mitigate the flaw at the reverse proxy layer. Proxies like Nginx or HAProxy should be configured to strictly validate the Host header against known virtual hosts and sanitize untrusted X-Forwarded-Host headers before they reach the Actix application.

Fix Analysis (1)

Technical Appendix

CVSS Score
6.1/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

Affected Systems

actix-web-lab

Affected Versions Detail

Product
Affected Versions
Fixed Version
actix-web-lab
actix
< 0.26.00.26.0
AttributeDetail
CWE IDCWE-601
CWE NameOpen Redirect
CVSS Score6.1 (Medium)
Attack VectorNetwork
AuthenticationNone
User InteractionRequired
Exploit StatusProof-of-Concept
CISA KEVNot Listed

MITRE ATT&CK Mapping

T1190Exploit Public-Facing Application
Initial Access
T1566Phishing
Initial Access
CWE-601
URL Redirection to Untrusted Site ('Open Redirect')

A web application accepts a user-controlled input that specifies a link to an external site, and uses that link in a Redirect. This simplifies phishing attacks.

References & Sources

  • [1]GHSA-vhj5-x93p-67JW Advisory
  • [2]Fix Commit 142c28b82eb59b67445a859a2a9b75e01a9964ee
  • [3]Fix Pull Request #292

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•about 12 hours ago•CVE-2026-39922
6.3

CVE-2026-39922: Server-Side Request Forgery in GeoNode Service Registration Endpoint

GeoNode versions prior to 4.4.5 and 5.0.2 are vulnerable to Server-Side Request Forgery (SSRF) in the service registration endpoint. Authenticated attackers with low privileges can exploit insufficient input validation in the Web Map Service (WMS) registration module to force the application server to make outbound network queries to loopback addresses, private RFC1918 subnets, link-local scopes, and cloud metadata endpoints. This technical report details the mechanics of the vulnerability, the underlying architectural flaw, and how to effectively remediate and mitigate the associated security risks.

Alon Barad
Alon Barad
4 views•7 min read
•about 21 hours ago•CVE-2022-0492
7.8

CVE-2022-0492: Privilege Escalation and Container Escape via cgroups v1 release_agent

CVE-2022-0492 is a high-severity missing authorization vulnerability in the Linux kernel's Control Groups (cgroups) v1 implementation. The flaw resides within the cgroup_release_agent_write function in kernel/cgroup/cgroup-v1.c, where the kernel fails to validate if the process writing to the release_agent file possesses administrative capabilities in the initial user namespace. This allows a local attacker inside a container with root privileges (UID 0) to abuse user namespaces, mount a cgroups v1 directory, modify the release_agent parameter, and execute arbitrary commands on the host system as host root, effectively achieving a complete container escape.

Amit Schendel
Amit Schendel
8 views•7 min read
•3 days ago•GHSA-G72G-R7M4-9X4G
6.3

GHSA-G72G-R7M4-9X4G: Insufficient Session Expiration of OAuth Tokens in NocoDB

NocoDB is subject to an insufficient session expiration vulnerability where OAuth access and refresh tokens are not invalidated or revoked during security-sensitive actions such as password changes, forgot-password requests, or password resets. This allows an attacker possessing an active OAuth token to maintain unauthorized persistence.

Amit Schendel
Amit Schendel
11 views•6 min read
•3 days ago•GHSA-FGMC-2HQJ-86V4
6.9

GHSA-FGMC-2HQJ-86V4: Default Administrative Credentials in vantage6-server

A vulnerability in the vantage6 federated learning framework allows unauthenticated remote attackers to gain administrative control of the server via hardcoded default credentials (root/root) when deployed under default configurations in versions 4.2.3 and below.

Amit Schendel
Amit Schendel
8 views•5 min read
•3 days ago•GHSA-X9F6-9RVM-MMRG
6.9

GHSA-X9F6-9RVM-MMRG: Improper Access Control and Volume Mount Isolation Bypass in vantage6 Node

An improper access control vulnerability in the vantage6 node component allows concurrently running algorithm containers to read and modify sensitive input and output files of other tasks. The lack of strict workspace directory isolation exposes a significant attack surface in multi-tenant or federated environments where untrusted algorithms are executed.

Amit Schendel
Amit Schendel
3 views•4 min read
•3 days ago•CVE-2026-47760
8.7

CVE-2026-47760: Cross-Site Scripting (XSS) via SVG Namespace Sanitizer Bypass in TinyMCE

TinyMCE versions 6.8.0 through 7.0.1 contain a high-severity Cross-Site Scripting (XSS) vulnerability. The flaw exists in the custom HTML parser and sanitizer module, which incorrectly manages SVG namespace scopes when parsing nested elements. A low-privileged or unauthenticated attacker can submit a crafted HTML payload containing nested SVG structures to bypass sanitization filters, leading to arbitrary JavaScript execution in the context of the victim's browser session.

Alon Barad
Alon Barad
30 views•7 min read