
【CODE BLUE 2024】武田 貴寛 / Takahiro Takeda - 講演関連資料 / Presentation resources -
●講演概要 / Abstract
[ja] IDA / Ghidraによるアンチデバッグの自動検出とサポート機能によるデバッグプロセスの効率化
マルウェアの作成者は、しばしばアンチデバッグ技術を用いて解析を妨害する。デバッガ上で実行されると、マルウェアはデバッガの存在を検出し、その後の動作を停止するか、通常とは異なる動作を行うため、解析が困難になる。アンチデバッグの実装方法は、マルウェアごとにさまざまである。
特に、大規模なメール送信キャンペーンで拡散されるマルウェアや、組織に影響を与える人気のランサムウェアには、複数のアンチデバッグ技術が確認されている。たとえば、アンチデバッグ技術には、デバッグ環境を検出するためのVM検出、デバッグ中にプログラムの実行を一時停止するブレークポイントの検出、デバッガを使用してマルウェアを解析する際の実行時間の違いを利用する時間差検出などが含まれる。
「AntiDebugSeeker」は、解析者によく利用されるバイナリ解析ツールIDAとGhidra用のオープンソース・プラグインであり、Windowsマルウェアに組み込まれたアンチデバッグ技術を自動的に識別することで、マルウェア解析プロセスを効率化する。アンチデバッグ機能に関連するコードは、例えば、マルウェアが使用するプロセスインジェクションの準備ステップとも重なる。したがって、検出ルールを柔軟にカスタマイズすることで、アンチデバッグ機能を特定するだけでなく、マルウェアの機能を理解することも可能である。さらに、このツールは、これらのアンチデバッグに対する説明やデバッグする際のサポート情報を提供し、アナリストが理解し、回避するための対策を講じる能力を向上させる。
本講演では、マルウェア解析を実演し、このツールの機能をどのように使用するかを説明し、実際の脅威シナリオでこれらの機能がどのように応用できるかを実践的に理解する。
[en] Automatically Detect and Support Against Anti-Debug with IDA/Ghidra to Streamline Debugging Process
Malware authors often employ anti-debugging techniques to obstruct analysis.
When executed on a debugger, the malware detects the debugger and either stops its subsequent actions or behaves differently than usual, making analysis difficult.
The number of anti-debugging implementations varies with each malware.
Notably, malware spread through mass-mailing campaigns that affect many organizations,
and popular ransomware has been confirmed to possess multiple anti-debugging techniques.
For example, anti-debugging techniques include VM detection, which checks for a debugging environment,
detection of Breakpoints (which temporarily pause program execution during debugging),
and time difference detection, which utilizes the difference in execution time when analyzing malware with a debugger.
`AntiDebugSeeker` is an open-source plugin for the binary analysis tools IDA and Ghidra, which are frequently utilized by analysts.
It streamlines the malware analysis process by automatically identifying the anti-debugging techniques embedded within Windows malware.
Code with anti-debug capabilities often overlaps with techniques used for anti-analysis, as well as with the preparatory steps for process injection, which are frequently employed by malware.
Therefore, by flexibly customizing the detection rules, it is possible not only to identify anti-debugging features but also to understand the functionalities of the malware.
Furthermore, the tool also provides functionalities to explain these anti-debugging measures and approaches to the corresponding functions.
This enhances the analyst's ability to understand and counteract the malware's evasion techniques effectively, offering a more comprehensive understanding and response strategy against such threats.
In this presentation, we will demonstrate malware analysis and explain how to use the tool's features, providing a practical understanding of how these features can be applied in actual threat scenarios.
●略歴 / Bio
[ja] 武田 貴寛
武田貴寛は、東京にあるLACのサイバー緊急対応センターのメンバーで、マルウェア解析およびサイバー脅威インテリジェンスを専門としている。彼は、セキュリティインシデントに関与したマルウェアの解析に従事しており、その知識を広めるために、書籍の執筆や教育活動にも力を注いでいる。これまでに、日本セキュリティオペレーションセンター(JSOC)でMSSを通じてIDSおよびIPSログの解析を行った経験や、日本サイバー犯罪対策センター(JC3)への出向中にサイバー脅威調査官を務めた経験を持つ。さらに、PacSec、AVAR、HITCONなどのさまざまなカンファレンスで研究成果を発表している。
[en] Takahiro Takeda
Takahiro Takeda is a member of the Cyber Emergency Center at LAC in Tokyo, Japan, specializing in malware analysis and cyber threat intelligence.
He has dedicated himself to analyzing malware involved in security incidents.
Additionally, he is committed to spreading his knowledge through writing books and participating in educational activities.
His experience includes analyzing IDS and IPS logs through MSS at the Japan Security Operation Center (JSOC) and serving as a cyber threat investigator during his secondment to the Japan Cyber Crime Control Center (JC3).
Furthermore, he has presented his research findings at various conferences, including PACSEC, AVAR, and HITCON.
●事前インタビュー / Pre-Event Interview
[ja] インタビュー
Q1 あなたがこのトピックに取り組むようになったきっかけは何ですか?
マルウェア解析を始めて、つまずいてしまうポイントとしてアンチデバッグなどの解析妨害があります。その結果、解析が難しくなり、マルウェアの挙動を詳しく解析するのに時間を要してしまう、または、解析を始めたばかりの人などは、諦めてしまうことにもつながりかねないと思います。実際にそういった声もあり、この最初の障壁をどうにかできないかと思い、研究・開発を始めました。
Q2 研究の過程でどのような点で苦労しましたか?
あまりマルウェア解析をやったことがない方でも使いやすいツールを心掛けて、このツールは開発しました。苦労というよりも、検討した点としては、使いやすいツールとはどういうものかを考えて、実装したことです。
考えた結果、アンチデバッグを見つけるだけでなく、検知したアンチデバッグの説明をコメントとして追加し、ユーザーのニーズによってルールを編集・追記しやすい定義ファイル、さらにIDA版のプラグインには、デバッグアシスト機能をツールに持たせました。
また、IDAのプラグインは有償ライセンスが必要であるため、IDAだけでなく、Ghidraのプラグインも開発し、幅広い方の解析のお手伝いができるツールになればと思っています。Ghidraのプラグイン開発は、初めてだったので、Ghidra本を読みながら勉強してJavaのコードを書いたり、GUIを操作したりする点で特に苦労しました…
Q3 CODEBLUEの参加者、参加を検討している人に向けてメッセージをお願いします。
私の研究発表では、マルウェア解析の効率化と初心者へのサポートに力を入れたツールの紹介を行います。
マルウェア解析の分野は難しい部分もありますが、少しでも解析のハードルを下げることで、より多くの方がこの分野に挑戦し、理解を深められることを目指しています。参加される皆様が、CODEBLUEを通じて新しい知見を得たり、同じ志を持つ方々と交流を深めたりすることを願っています。
当日お会いできるのを楽しみにしています。
[en] Interview
Q1 What led you to making this presentation?
When I began analyzing malware, one of the common stumbling blocks I encountered was anti-debugging techniques, which are designed to obstruct analysis. These techniques make it more difficult to thoroughly analyze the behavior of malware and can significantly increase the time required for analysis. For those new to malware analysis, it can even lead to frustration and giving up. I’ve heard similar concerns from others as well, which motivated me to start researching and developing solutions to overcome this initial barrier.
Q2 What were some challenges you faced during this research?
I developed this tool with a focus on making it easy to use, even for those who don’t have much experience in malware analysis. Rather than facing difficulties, what I carefully considered was what constitutes an easy-to-use tool, and then I implemented those ideas. As a result, the tool not only detects anti-debugging techniques but also provides comments explaining the detected anti-debugging methods. Additionally, I designed a definition file that makes it easy for users to edit and add rules according to their needs. Furthermore, for the IDA version of the plugin, I added a debugging assist function to the tool.
Since the IDA plugin requires a paid license, I also developed a Ghidra plugin to support a wider range of users in their analysis. As it was my first time developing a Ghidra plugin, I had to study by reading Ghidra books, writing Java code, and working with the GUI, which was particularly challenging.
Q3 What message would you like to convey to those considering attending this talk?
In my presentation, I will introduce a tool designed to improve the efficiency of malware analysis and provide support for beginners. While malware analysis can be challenging, my goal is to lower the barriers to entry, allowing more people to take on this field and deepen their understanding. I hope that those attending CODEBLUE will gain new insights and connect with others who share the same passion. I look forward to meeting you at the event.
●講演動画 / Presentation video
●講演スライド / Presentation slide

(Click the image to open the PDF via an external link)
●写真 / Photo
