본문으로 건너뛰기
Skillpedia
에이전트35k · #8341

post-exploiting-microsoft-graph-with-graphrunner

하는 일

이 도구는 초기 접근을 얻은 후 Microsoft 365 시스템(이메일, 파일 등)을 탐색하고 제어하는 데 도움을 줍니다. 정보를 찾고, 접근을 유지하며, 시스템 내에서 권한을 상승시키는 데 사용할 수 있습니다.

사용하는 경우

  • ✓허가를 받은 Microsoft 365 시스템에 접근한 뒤.
  • ✓권한과 보안 정책을 확인할 때.
  • ✓공격자가 접근을 유지하거나 권한을 상승시키는 방법을 시연하는 경우.

스킬 링크

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/post-exploiting-microsoft-graph-with-graphrunner/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/post-exploiting-microsoft-graph-with-graphrunner/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“민감한 정보를 찾고 접근을 유지하기 위해 Microsoft 365 시스템을 탐색하고 싶습니다.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

도구는 Microsoft Graph API를 사용해 시스템과 상호작용합니다. 정상 트래픽처럼 위장하여 데이터 도난, 가짜 접근 생성, 그룹에 구성원 추가 같은 작업을 수행할 수 있습니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Post-Exploiting Microsoft Graph with GraphRunner

Authorized use only: GraphRunner performs offensive actions against live Microsoft 365 / Entra ID tenants — deploying OAuth apps, cloning groups, adding members, and reading mailboxes, SharePoint, and Teams. Run it only against tenants you own or are explicitly authorized in writing to test. Unauthorized use is illegal.

Overview

GraphRunner (Beau Bullock / Black Hills Information Security) is a PowerShell post-exploitation toolset built entirely on the Microsoft Graph API. Given a foothold token, it performs recon, establishes persistence, escalates privilege, and pillages M365 data — all through Graph, which blends in with normal traffic and bypasses many endpoint controls. It is the natural follow-on to credential/token theft (e.g., device-code phishing or ROADtools): once you hold Graph access, GraphRunner operationalizes it.

The toolset is a single PowerShell module (GraphRunner.ps1) exposing dozens of functions grouped by purpose:

  • Authentication — Get-GraphTokens (device-code login), Invoke-RefreshGraphTokens, Invoke-AutoTokenRefresh, Invoke-ImportTokens, Invoke-RefreshToSharePointToken.
  • Recon & Enumeration — Invoke-GraphRecon (tenant/user permission summary), Invoke-DumpCAPS (conditional-access policies), Invoke-DumpApps (app registrations / consent grants), Get-AzureADUsers, Get-SecurityGroups, Get-UpdatableGroups, Get-DynamicGroups, Invoke-SearchUserAttributes, Invoke-GraphOpenInboxFinder, Find-PermissiveCalendars.
  • Persistence — Invoke-InjectOAuthApp (deploy a malicious OAuth app for consent-grant persistence), Invoke-CreateInboxForwardingRule.
  • Privilege Escalation — Get-UpdatableGroups, Invoke-AddGroupMember, Invoke-SecurityGroupCloner, Invoke-InviteGuest.
  • Pillage / Data Search — Invoke-SearchMailbox, Invoke-SearchSharePointAndOneDrive, Invoke-SearchTeams, Get-TeamsChat, Invoke-DriveFileDownload.
  • Master runner — Invoke-GraphRunner runs an automated recon-and-pillage pass; List-GraphRunnerModules prints all modules.

This maps to MITRE ATT&CK T1098 — Account Manipulation: GraphRunner manipulates accounts, groups, and OAuth grants (adding members, injecting apps, cloning groups, inviting guests) to maintain and escalate access in the cloud identity plane.

When to Use

  • After obtaining a valid Microsoft Graph access/refresh token during an authorized M365/Entra engagement.
  • When mapping tenant permissions, conditional-access policies, and OAuth app exposure.
  • When establishing cloud persistence via OAuth consent grants or inbox forwarding (in scope).
  • When demonstrating privilege escalation through updatable/dynamic groups.
  • When searching mailboxes, SharePoint/OneDrive, and Teams for sensitive data to evidence impact.

Prerequisites

  • Written authorization and scope for the target tenant.
  • A Graph token foothold (from Get-GraphTokens device-code login, or imported tokens).
  • PowerShell 5.1+ or PowerShell 7 (cross-platform).
# Clone and import the module
git clone https://github.com/dafthack/GraphRunner.git
cd GraphRunner
Import-Module .\GraphRunner.ps1

# List every available module
List-GraphRunnerModules

Objectives

  • Authenticate to Microsoft Graph and maintain tokens via refresh.
  • Enumerate tenant users, groups, CA policies, and OAuth apps.
  • Identify updatable groups and demonstrate privilege escalation.
  • Establish persistence via an injected OAuth app and/or inbox forwarding rule.
  • Search mailboxes, SharePoint/OneDrive, and Teams for sensitive content.

MITRE ATT&CK Mapping

ID Tactic Official Technique Name Role in this skill
T1098 Persistence Account Manipulation Add group members, clone groups, invite guests to retain/escalate access
T1098.003 Privilege Escalation Account Manipulation: Additional Cloud Roles Adding members to privileged/updatable groups
T1528 Credential Access Steal Application Access Token Get-GraphTokens device-code token acquisition
T1087.004 Discovery Account Discovery: Cloud Account Get-AzureADUsers, Invoke-SearchUserAttributes
T1114.002 Collection Email Collection: Remote Email Collection Invoke-SearchMailbox over Graph
T1606.002 Credential Access Forge Web Credentials: SAML/OAuth Invoke-InjectOAuthApp consent-grant persistence

…

자주 묻는 질문

이 도구를 사용하려면 허가가 필요한가요?

네, 어떤 시스템에서든 사용하려면 명시적인 서면 허가가 필요합니다. 허가 없이 사용하는 것은 불법입니다.

‘Graph 토큰’이란 무엇인가요?

전통적인 비밀번호 없이도 도구가 Outlook이나 파일 같은 Microsoft 서비스와 상호작용할 수 있게 해 주는 특별한 접근 키입니다.

이 도구는 어떤 시스템에 영향을 주나요?

Microsoft 365와 Entra ID(예전 이름 Azure AD) 생태계 안에서 작동하며, Outlook, SharePoint, Teams 같은 서비스에 영향을 줄 수 있습니다.

상세 정보

작성자의 원본 설명

Runs GraphRunner, a PowerShell post-exploitation toolset built on the Microsoft Graph API, to perform tenant recon, establish persistence (OAuth app injection, inbox rules), escalate privilege via group manipulation, and pillage mailboxes, SharePoint, and Teams data from a foothold Graph token. Use during authorized red-team engagements against Microsoft 365/Entra ID tenants once you hold a Graph

repo: mukul975/Anthropic-Cybersecurity-Skills

인기도

GitHub 스타
35k
순위
#8341
라이선스
Apache-2.0
업데이트
2026. 8. 31.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬