Mastering Host Header Injection: Techniques, Payloads and Real-World Scenarios
文章探讨了攻击者如何通过篡改HTTP请求中的Host头来操控Web应用,并可能导致缓存中毒、密码重置欺骗甚至账户接管等风险。同时介绍了常见的Host头注入技术及其防御方法。 2025-10-16 13:39:36 Author: infosecwriteups.com(查看原文) 阅读量:32 收藏

Learn How Attackers Manipulate Host Headers to Compromise Web Applications and How to Defend Against It

coffinxp

Press enter or click to view image in full size

Introduction

Host header injection is a web vulnerability that arises when a web application trusts the value of the Host header in HTTP requests without proper validation. Attackers can manipulate this header to influence how the server processes requests, potentially leading to cache poisoning, password reset poisoning, web cache deception and even full account takeover in some scenarios.

Understanding the various ways to manipulate the Host header is crucial for both attackers and defenders. Below we explore the most common and advanced techniques for host header manipulation with practical examples and explanations.

Common Host Header Injection Techniques

Spoofing with Malicious Domain

Supply a rogue domain in the Host header to trick the application into generating links or redirects pointing to the attacker’s server.

example:

GET /reset-password HTTP/1.1  
Host: attacker.com

文章来源: https://infosecwriteups.com/mastering-host-header-injection-techniques-payloads-and-real-world-scenarios-e00c9e1f85cd?source=rss----7b722bfd1b8d--bug_bounty
如有侵权请联系:admin#unsafe.sh