Trusted Design

T1128 - Netsh Helper DLL

概要

Netsh.exe (also referred to as Netshell) is a command-line scripting utility used to interact with the network configuration of a system. It contains functionality to add helper DLLs for extending functionality of the utility. (Citation: TechNet Netsh) The paths to registered netsh.exe helper DLLs are entered into the Windows Registry at HKLM\SOFTWARE\Microsoft\Netsh.

Adversaries can use netsh.exe with helper DLLs to proxy execution of arbitrary code in a persistent manner when netsh.exe is executed automatically with another Persistence technique or if other persistent software is present on the system that executes netsh.exe as part of its normal functionality. Examples include some VPN software that invoke netsh.exe. (Citation: Demaske Netsh Persistence)

Proof of concept code exists to load Cobalt Strike's payload using netsh.exe helper DLLs. (Citation: Github Netsh Helper CS Beacon)

管理者によるコメント

T1128 は、「Netsh Helper DLL(NetshヘルパーDLLの悪用)」です。

Windowsの標準ネットワーク管理ツールである netsh.exe の拡張機能を悪用し、悪意のあるDLLをシステムに登録することで「永続化(Persistence)」と「防御回避(Defense Evasion)」を同時に達成する巧妙な手法です。

1. 概要

この手法で攻撃者は、「ネットワーク設定ツールが起動するたびに、マルウェアを自動実行する隠れ蓑」を手に入れます。

何を実現できるのか

2. 攻撃の流れ

netsh のヘルパーDLLをシステム全体に登録するため、攻撃者は事前に管理者権限(Administrator)を確保している必要があります。

  1. 悪意のあるDLLの作成と配置:
    netsh の仕様(特定の関数エクスポートなど)に沿って作成した攻撃用DLL(例: evil_helper.dll)をシステム内(C:\Windows\System32\ など)に配置します。

  2. DLLの登録(コマンドまたはレジストリ操作):
    攻撃者はWindows標準の netsh.exe コマンドを悪用して、直接このDLLをヘルパーとして登録します。

    • コマンドの例:
      netsh add helper C:\Windows\System32\evil_helper.dll

    • このコマンドが実行されると、Windowsは自動的に以下のレジストリキーにDLLのパスを書き込みます。
      HKLM\SOFTWARE\Microsoft\Netsh

  3. 自動実行のトリガー:
    それ以降、システムやユーザー、あるいは他のプログラムが netsh.exe を起動(例:ネットワーク情報の取得など)するたびに、OSは上記レジストリを参照します。

  4. コード実行:
    netsh.exe は登録された evil_helper.dll を自身のメモリ空間に自動的にロードし、中に仕込まれたマルウェアのコードがSYSTEM権限、あるいは実行したユーザーの権限でバックグラウンド実行されます。

3. 防御・対策

「レジストリの監視」と「コマンド実行ログのチェック」が非常に有効です。

4. 重要ポイント

5. 関連する主なCWE

6. 関連する代表的な事例・ツール

高度な標的型攻撃(APT)において、一般的な自動起動(Runキーなど)を警戒しているセキュリティ組織の目を盗むために選ばれることが多いです。

実務上のアドバイス

もし自社の環境で、セキュリティアラートに「netsh.exe が不審なDLLをロードした」あるいは「netsh add helper が実行された」という記録を見つけた場合は、即座に該当の端末の調査が必要です。その際は、HKLM\SOFTWARE\Microsoft\Netsh レジストリを開き、登録されているDLLのハッシュ値をVirusTotal等で確認するか、フォレンジック担当に提出して解析を行ってください。

分析

この攻撃手法を利用する脅威アクター

関連する CVE

この攻撃手法に関連する CVE は登録されていません。

攻撃手法 – 脅威アクター Graph


← Technique一覧に戻る ← Tactics一覧に戻る