> 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/ja/hacking-wifi/wpa-wpa2-psk-network-attacks/traffic-manipulation/replacing-web-images-with-xerosploit.md).

# Xerosploit による Web 画像の置き換え

制御された Xerosploit ラボ中に、暗号化されていない Web トラフィック内の画像を置き換える。

Xerosploit は `置換` 暗号化されていないWebトラフィック内の画像を置き換えるモジュールです。

{% embed url="<https://github.com/lionsec/xerosploit/>" %}

### Xerosploit のインストール

インストーラーを実行します：

{% code overflow="wrap" %}

```bash
python3 install.py
```

{% endcode %}

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FGGr6v6RAmZxRNoPJGGuk%2Fimage.png?alt=media&amp;token=5d20751f-57c8-4961-bfb1-67431502c8d2" alt=""><figcaption></figcaption></figure>

### ツールを起動する

Xerosploit を起動します：

{% code overflow="wrap" %}

```bash
sudo python3 xerosploit.py
```

{% endcode %}

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FEwguzgEU2ba6owrbNL8e%2Fimage.png?alt=media&amp;token=97a7c85d-45e5-415d-b42a-9986abcd822d" alt=""><figcaption></figcaption></figure>

### 使用可能なコマンド

* `scan` ネットワークをマップします。
* `iface` ネットワークインターフェースを設定します。
* `gateway` ゲートウェイを設定します。
* `start` スキャンせずに対象のIPアドレスを設定します。
* `rmlog` Xerosploit のログを削除します。
* `help` 使用可能なコマンドを表示します。
* `exit` Xerosploit を終了します。

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FypfDsG63SzenRE048EMZ%2Fimage.png?alt=media&amp;token=4597026a-4a7e-480f-8080-f7113c5f99c2" alt=""><figcaption></figcaption></figure>

### ラボのデバイスを設定する

テスト用デバイスのIPアドレスを設定します：

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FR6ZfPczvBUFBhWdbxwcE%2Fimage.png?alt=media&amp;token=667f2887-7911-4705-823d-a399c6da842f" alt="" width="536"><figcaption></figcaption></figure>

{% code overflow="wrap" %}

```bash
172.20.10.2
```

{% endcode %}

### 置換モジュールを実行する

選択 `置換` モジュール：

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FDn5RLWSfp6MdvnifdovR%2Fimage.png?alt=media&amp;token=cbb2082e-2cfa-45b3-a02c-aaaf2e90f095" alt=""><figcaption></figcaption></figure>

選択し `置換`、その後モジュールを実行します。使用する画像ファイルを読み込んでください：

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FanbnnmzxiwoWMgQl2z5r%2Fimage.png?alt=media&amp;token=f30ca38d-cb5c-45fe-a9d1-0a0a662e4aa0" alt="" width="563"><figcaption></figcaption></figure>

この画像パスを使用します：

`/home/jordan/Downloads/pwned.jpeg`

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FAUd6y7nmOv3Kzdo3rygZ%2Fimage.png?alt=media&amp;token=47d78dc0-4983-4164-8c27-8543e687b114" alt=""><figcaption></figcaption></figure>

テスト用デバイスで訪問したWebページには、置換後の画像が表示されるようになります。これは暗号化されていないHTTPトラフィックにのみ適用されます。

このツールでは、選択したデバイスによって読み込まれた画像も表示できます。


---

# 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/ja/hacking-wifi/wpa-wpa2-psk-network-attacks/traffic-manipulation/replacing-web-images-with-xerosploit.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.
