detecting-entra-offensive-tools-in-graph-logs
Fungsinya
Alat ini mencari tanda-tanda program berbahaya yang digunakan untuk mengumpulkan informasi tentang akun Microsoft Anda. Alat ini memeriksa log aktivitas Microsoft Graph dan Azure AD Graph untuk mengidentifikasi aktivitas mencurigakan.
Kapan dipakai
- βSaat Anda mencurigai kredensial Microsoft Anda telah dicuri.
- βSaat menyelidiki aktivitas yang tidak biasa di akun Microsoft Anda.
- βSelama pengujian keamanan untuk melihat apakah alat serangan dapat terdeteksi.
Link skill
https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-entra-offensive-tools-in-graph-logs/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βCari aktivitas pengumpulan informasi yang mencurigakan di akun Microsoft saya.β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Alat ini menganalisis log aktivitas Microsoft Graph dan Azure AD Graph. Alat ini mencari pola penggunaan tertentu serta tanda tangan (signature) dari program pengumpul data yang sudah dikenal.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Detecting Entra Offensive Tools in Graph Logs
Overview
For nearly a decade the legacy Azure AD Graph API (graph.windows.net) was a defender blind spot: requests to it produced no first-class activity log, so tools like ROADtools (roadrecon) and AADInternals β which lean heavily on AAD Graph β could enumerate an entire tenant with little trace. That changed when Microsoft shipped AADGraphActivityLogs (general availability in 2026), the counterpart to the already-available MicrosoftGraphActivityLogs (graph.microsoft.com). Together these two tables give SOCs request-level visibility into directory API traffic: the caller identity, app, source IP, HTTP method, request URI, and crucially the User-Agent.
This skill is the defensive complement to offensive Entra tooling. It hunts the two Graph activity tables for the behavioral and string fingerprints those tools leave behind. Many operators forget to spoof the User-Agent, so ROADtools (built on Python's aiohttp) emits a User-Agent like Python/3.12 aiohttp/3.10.4, and AADInternals frequently leaves AADInternals or library strings in the agent. Even when the agent is spoofed, the tools betray themselves through a characteristic endpoint-sweep pattern: roadrecon gather pulls users, groups, applications, serviceprincipals, devices, directoryroles, roledefinitions, oauth2permissiongrants, and more within a tight time window β a signature that survives header spoofing.
The activity being detected maps to MITRE ATT&CK T1078.004 β Valid Accounts: Cloud Accounts: an adversary using legitimate (often phished or token-stolen) cloud credentials to enumerate and operate against the tenant via the Graph APIs. These detections both surface live intrusions and validate that the offensive techniques in the companion red-team skills are observable.
When to Use
- Building or tuning detections for Microsoft Sentinel / Log Analytics covering Entra ID
- Threat hunting after suspected credential theft, device-code phishing, or OAuth consent abuse
- Purple-team exercises validating that ROADtools/AADInternals/AzureHound activity is detectable
- Investigating an alert and needing to correlate Graph API calls back to a sign-in/session
- Closing the legacy Azure AD Graph visibility gap after enabling AADGraphActivityLogs
Prerequisites
- A Microsoft Sentinel workspace (or Log Analytics) ingesting:
- MicrosoftGraphActivityLogs (diagnostic setting on Microsoft Entra ID -> graph.microsoft.com)
- AADGraphActivityLogs (diagnostic setting on Microsoft Entra ID -> legacy Azure AD Graph)
SigninLogsandAADNonInteractiveUserSignInLogsfor correlation- Microsoft Sentinel Reader/Responder (or Log Analytics Reader) RBAC to run KQL
- Familiarity with Kusto Query Language (KQL)
- Enable the diagnostic settings (Azure Portal -> Microsoft Entra ID -> Diagnostic settings -> send
MicrosoftGraphActivityLogsandAADGraphActivityLogsto your workspace), or via CLI:az monitor diagnostic-settings create \ --name "entra-graph-logs" \ --resource "/providers/microsoft.aadiam/diagnosticSettings" \ --logs '[{"category":"MicrosoftGraphActivityLogs","enabled":true},{"category":"AADGraphActivityLogs","enabled":true}]' \ --workspace "<log-analytics-workspace-id>"
Objectives
- Confirm both Graph activity tables are flowing into the workspace
- Detect User-Agent string fingerprints of ROADtools, AADInternals, and AzureHound
- Detect the endpoint-sweep behavioral fingerprint that survives User-Agent spoofing
- Correlate suspicious Graph activity back to a sign-in/session and source identity
- Operationalize the best queries as scheduled analytics rules
MITRE ATT&CK Mapping
| ID | Technique | Application in this skill |
|---|---|---|
| T1078.004 | Valid Accounts: Cloud Accounts | Detecting adversaries using valid cloud credentials/tokens to enumerate the tenant via the Microsoft Graph and legacy Azure AD Graph APIs |
Related techniques surfaced by these hunts: T1087.004 Account Discovery: Cloud Account, T1069.003 Permission Groups Discovery: Cloud Groups, T1526 Cloud Service Discovery.
Workflow
Step 1: Confirm both tables are ingesting
Before hunting, verify the data exists and inspect the schema fields you will pivot on.
union withsource=Tbl MicrosoftGraphActivityLogs, AADGraphActivityLogs
| where TimeGenerated > ago(1d)
β¦
Pertanyaan umum
Apa itu 'Graph Logs'?
Ini adalah catatan rinci dari semua interaksi dengan layanan Microsoft Graph dan Azure AD Graph, yang digunakan untuk mengelola akun dan sumber daya Anda di Microsoft.
Apa itu 'ROADtools', 'AADInternals', dan 'AzureHound'?
Ini adalah contoh alat yang dapat digunakan untuk mengumpulkan informasi tentang lingkungan Microsoft, terkadang untuk tujuan jahat. Alat ini membantu mendeteksinya.
Apa itu 'User-Agent'?
Ini adalah informasi yang dikirim oleh browser atau program Anda ke situs web atau layanan, yang mengidentifikasi program mana yang sedang terhubung. Alat berbahaya mungkin mencoba menyamarkan informasi ini.
Detail
Deskripsi asli dari pembuat
Hunt AADGraphActivityLogs and MicrosoftGraphActivityLogs in Microsoft Sentinel/Log Analytics using KQL to fingerprint offensive Entra ID enumeration tools such as ROADtools, AADInternals, and AzureHound, including User-Agent signatures, roadrecon endpoint sweeps, and sign-in correlation. Use when investigating suspicious Microsoft Graph API activity, Entra ID reconnaissance, or building Sentinel a
Popularitas
- Bintang GitHub
- 35k
- Peringkat
- #7827
- Lisensi
- Apache-2.0
- Diperbarui
- 31/8/2026
Komentar
- β¦
Skill lain dari repositori ini
abusing-dpapi-for-credential-access
35kMemberi agent AI Anda instruksi siap pakai untuk tugas tertentu, sehingga hasilnya lebih baik dan pengerjaannya lebih cepat.
abusing-shadow-credentials-for-privesc
35kMengajarkan agent AI Anda menulis teks yang jelas dan terstruktur dengan baik.
achieving-cmmc-level-2-compliance
35kMembantu agent Anda menyiapkan lingkungan untuk kepatuhan CMMC Level 2. Skill ini menerapkan persyaratan keamanan dan mengelola dokumentasi yang diperlukan.
acquiring-disk-image-with-dd-and-dcfldd
35kMembantu agent Anda membuat salinan persis dari hard drive. Berguna untuk memastikan tidak ada informasi yang hilang atau berubah selama investigasi.
Skill serupa
reverse-engineer-anything
422kMembantu agent Anda memeriksa aplikasi dan paket yang sudah dirilis untuk menjelaskan fitur, membandingkan versi, atau memandu pembangunan ulang dengan alat REA.
1password
394kMembantu agent Anda mengatur CLI 1Password, masuk, serta membaca atau menyisipkan rahasia tanpa menampilkan nilainya di chat.
healthcheck
394kMembantu agent Anda mengaudit komputer atau server OpenClaw dari risiko keamanan seperti SSH, firewall, pembaruan, dan cadangan, lalu menyarankan perbaikan aman.