> 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/ru/web/authentication/password-brute-force-via-password-change.md).

# Перебор пароля через функцию смены пароля

Заметки по лабораторным работам PortSwigger Web Security Academy о переборе пароля через функцию смены пароля, включая рабочий процесс эксплуатации, тестирование полезной нагрузки, проверку в Burp Suite и контекст устранения уязвимости

### Подбор пароля методом перебора через смену пароля

В этой лабораторной работе демонстрируется уязвимость в функциональности **смены пароля**, позволяющая атаковать с помощью **брутфорс**. / Цель — определить пароль **Карлоса**, а затем получить доступ к его странице \*\*

**Предоставленные учетные данные:**

* Пользователь: `wiener`
* Пароль: `peter`

**Целевой пользователь:**

* `carlos`

Раздел позволяет изменить пароль после аутентификации. / Когда указан неверный **текущего пароля** , приложение возвращает конкретное сообщение об ошибке.

<figure><img src="https://4248209978-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-b28b2b93c3c2f8c2b40b13ba25a0e4fb6e224b05%2F%7BDC9BF2F7-E41F-4D00-ADF9-7111E3DBF354%7D.png?alt=media" alt=""><figcaption></figcaption></figure>

Пример запроса, отправленного приложением:

{% code overflow="wrap" %}

```bash
username=wiener&current-password=test&new-password-1=test1234&new-password-2=test123
```

{% endcode %}

Если `current-password` поле недопустимо, отображаемая ошибка указывает, что текущий пароль неверен.

<figure><img src="https://4248209978-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-e2878fffa7229fc9a42c61bc57ea36721199917c%2F%7B498293B7-D204-419C-A18B-8BC457FB303A%7D.png?alt=media" alt=""><figcaption></figcaption></figure>

При замене `wiener` на `carlos` в запросе, **сообщение об ошибке остаётся таким же**, пока проверяемый пароль не является правильным. Настройте атаку Burp Intruder

<figure><img src="https://4248209978-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-b08fe73486c2f05bd5e404e7a9b5470e007bd9e3%2F%7BE3795651-6554-4698-B348-00BE94804022%7D.png?alt=media" alt=""><figcaption></figcaption></figure>

Однако для **правильного пароля**, сообщение об ошибке меняется:/ вместо неверного пароля приложение указывает, что **данные для идентификации не совпадают**.

Это различие в ответе позволяет нам **отличить действительный пароль от недействительного**.

<figure><img src="https://4248209978-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-fd1d049f8656f4a739ba6652b1c93cf983237e54%2F%7B527509D2-E1A4-41E7-A224-3A9100A5010C%7D.png?alt=media" 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://hacking-notes.jord4n.pro/ru/web/authentication/password-brute-force-via-password-change.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
