> For the complete documentation index, see [llms.txt](https://hacking-notes.jord4n.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hacking-notes.jord4n.pro/zh/web-vulnerabilities/execution-after-redirect-ear-attack/ear-execution-after-redirect-pentesting-web.md).

# 重定向后执行

## **漏洞 EAR（重定向后执行）- 跳过重定向**

我们发现有几个页面包含该内容，但会重定向到登录页面。

<figure><img src="/files/c1a96cfd2d807288c332c23a83412a2f8b254393" alt=""><figcaption></figcaption></figure>

我们拦截对 `nav.php` 并使用 Burp Suite 观察到 302 重定向。

<figure><img src="/files/5a0548645e4186fd99f9f717f543986f7a4b28bf" alt=""><figcaption></figcaption></figure>

通过将响应强制设为 `200 OK`，我们即可直接访问该页面 `accounts`.

<figure><img src="/files/fbba1d7acce428504041aba9481b0eaeb9e685a9" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/06031b6cf5d6f6cd1234bf18cc687f9e1d626f1e" alt=""><figcaption></figcaption></figure>

我们在 Burp Suite 中创建一条规则，以自动修改响应 `302 Found` 更改为 `200 OK`.

<figure><img src="/files/0a5c8ad837910cc8033be68d0456fce084dc230d" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/cf1056269e6b23d174ec54aa1d6be729297f12d2" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://hacking-notes.jord4n.pro/zh/web-vulnerabilities/execution-after-redirect-ear-attack/ear-execution-after-redirect-pentesting-web.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
