> 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/information-disclosure/information-disclosure-via-version-control-history.md).

# Раскрытие информации через историю системы контроля версий

### Раскрытие информации в истории системы контроля версий

**Описание лабораторной работы**

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

**Первичный анализ**

Исследуя приложение, мы видим наличие каталога **`.git`** доступного напрямую с веб-сервера.

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

Это указывает на то, что полный Git-репозиторий открыт для публичного доступа, что потенциально позволяет получить исходный код и историю изменений.

**Эксплуатация**

**Извлечение Git-репозитория**/ Для загрузки содержимого `.git` каталога:

```bash
git-dumper https://0a7800030384626580b39ee5001e00b1.web-security-academy.net/.git .git
```

<figure><img src="/files/430c1bf079e36efe6cbdfc29e9e5075bb1fa8d0b" alt=""><figcaption></figcaption></figure>

**Анализ истории коммитов**/ После локального восстановления репозитория изучается история коммитов:

```bash
git log
```

Анализ показывает, что один из коммитов содержит удаление пароля администратора.

<figure><img src="/files/027269ab6d571c555ad1479e39fad02117035a6a" alt=""><figcaption></figcaption></figure>

**Просмотр различий**/ Точное содержимое этого коммита просматривается, чтобы определить удаленную информацию:

```bash
git log -p ab875bcd9cf3ea84ad6af9471521aea4c3a1852d
```

Отображаемые различия позволяют найти пароль пользователя **administrator**.

* q0b3xu3ko6pqcqdjofrq

<figure><img src="/files/be6467678bac5043c7adc9acb3be5aa89bb71ea6" 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/ru/web/information-disclosure/information-disclosure-via-version-control-history.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.
