> 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/authentication/username-enumeration-via-different-responses.md).

# 通过不同响应进行用户名枚举

### 通过不同响应进行用户名枚举

该网站存在以下漏洞：

* 通过不同的响应消息枚举用户名；
* 密码暴力破解。

目标是：

1. 从词表中找到一个有效用户名。
2. 从另一个词表中暴力破解对应密码。
3. 登录并访问用户账户页面。

<figure><img src="/files/4bb3da535373feb14837ce436614a61e41ff53d0" alt=""><figcaption></figcaption></figure>

#### 设置

* 该网站提供一个经典的 **登录** 表单。
* 有以下列表： **用户名** 和 **passwords** 由实验提供。
* 连接请求被拦截并发送到 **Burp Intruder**.

#### 1. 用户列表

1. 拦截一次连接尝试并发送到 **Intruder**.
2. 在以下位置放置有效载荷： **username** 参数进行利用。

<figure><img src="/files/9310090d66ca05a988174ed54a80b22895901c11" alt=""><figcaption></figcaption></figure>

* 加载 **用户词表** 由实验提供。

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

1. 发起攻击并观察响应（状态、长度等）。

请注意，用户名 **`apollo`**，响应具有不同的 **长度** ，与其他响应不同。

→ 这表明 **`apollo`** 是一个有效的 **username**.

<figure><img src="/files/9ec82e5bfd81b6666bffa10e1cec76fa8b471850" alt=""><figcaption></figcaption></figure>

#### 2. 暴力破解密码

1. 继续使用以下内容发送登录请求： **将用户名固定为 `apollo`**.
2. 再次发送该请求，并在 **Intruder**.
3. 这次将有效载荷放在 **密码** 参数进行利用。
4. 加载 **密码词表** 中。
5. 发起攻击并分析响应。

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

该 **`mustang`** 密码会产生不同的 **响应** （例如长度或内容），表明成功的 **连接**.

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

#### 3. 最终登录

有效凭据为：

* **用户名：** `apollo`
* **密码：** `mustang`


---

# 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/authentication/username-enumeration-via-different-responses.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.
