[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7AA98CTNMSQ04BBZD19Y4DM":3,"skill-same:01M7AA98CTNMSQ04BBZD19Y4DM":91},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":16,"sourceHtmlUrl":17,"categories":18,"keywords":19,"publishedAt":20,"linkOnly":21,"markdownContent":22,"markdownBody":23,"frontMatter":24,"refName":54,"commitSha":55,"skillDirectory":56,"forksCount":14,"repositoryHtmlUrl":57,"repositoryHomepageUrl":6,"ownerHtmlUrl":58,"ownerBlogUrl":6,"ownerDescription":59,"updatedAt":60,"install":61,"resources":74},"01M7AA98CTNMSQ04BBZD19Y4DM","performing-purple-team-exercise",null,"Performs purple team exercises by coordinating red team adversary emulation with blue team detection validation using MITRE ATT&CK-mapped attack scenarios, real-time detection testing, and collaborative gap remediation. Use when SOC teams need to validate detection capabilities, improve analyst skills, and close detection gaps through structured offensive-defensive collaboration.","NeelakshSaxena\u002FVayu","NeelakshSaxena","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F87892838?v=4","01M7A3B9YFS6F6N9DD1787DT86","Neelaksh Saxena","01M7A3B9ZKBT09MNMPX2XN69BY",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fperforming-purple-team-exercise\u002FLICENSE","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fperforming-purple-team-exercise\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: performing-purple-team-exercise\ndescription: 'Performs purple team exercises by coordinating red team adversary emulation\n  with blue team detection validation using MITRE ATT&CK-mapped attack scenarios,\n  real-time detection testing, and collaborative gap remediation. Use when SOC teams\n  need to validate detection capabilities, improve analyst skills, and close detection\n  gaps through structured offensive-defensive collaboration.\n\n  '\ndomain: cybersecurity\nsubdomain: soc-operations\ntags:\n- soc\n- purple-team\n- red-team\n- blue-team\n- mitre-attack\n- adversary-emulation\n- detection-validation\nversion: '1.0'\nauthor: mahipal\nlicense: Apache-2.0\nd3fend_techniques:\n- File Metadata Consistency Validation\n- Application Protocol Command Analysis\n- Identifier Analysis\n- Content Format Conversion\n- Message Analysis\nnist_csf:\n- DE.CM-01\n- DE.AE-02\n- RS.MA-01\n- DE.AE-06\nmitre_attack:\n- T1078\n- T1685.002\n- T1685.005\n- T1566\n---\n# Performing Purple Team Exercise\n\n## When to Use\n\nUse this skill when:\n- SOC teams need to validate that detection rules actually fire for the threats they target\n- Red team assessments produced findings that need translation into detection improvements\n- New detection tools or SIEM migrations require validation of detection coverage\n- Analyst training requires hands-on experience with real attack techniques and SIEM responses\n- Quarterly or semi-annual detection validation cycles are scheduled\n\n**Do not use** for unannounced red team engagements — purple team exercises require explicit coordination between offensive and defensive teams with real-time collaboration.\n\n## Prerequisites\n\n- Red team capability: internal team or contracted purple team operator\n- Attack simulation tools: Atomic Red Team, MITRE Caldera, or C2 framework (authorized)\n- SIEM access for real-time alert monitoring during exercise\n- ATT&CK-mapped detection rule inventory with expected alert names\n- Isolated test environment or approved production scope with change management approval\n- Communication channel (Slack\u002FTeams) for real-time red-blue coordination\n\n## Workflow\n\n### Step 1: Define Exercise Scope and Objectives\n\nDocument exercise parameters:\n\n```yaml\npurple_team_exercise:\n  exercise_id: PT-2024-Q1\n  date: 2024-03-20\n  duration: 8 hours (09:00-17:00 UTC)\n  scope:\n    environment: Production (Finance VLAN, 10.0.5.0\u002F24)\n    systems_in_scope:\n      - WORKSTATION-TEST01 (10.0.5.100) — Test endpoint\n      - DC-TEST (10.0.5.200) — Test domain controller\n      - FILESERVER-TEST (10.0.5.201) — Test file server\n    systems_excluded:\n      - All production domain controllers\n      - Customer-facing systems\n  objectives:\n    - Validate 15 detection rules mapped to FIN7 TTPs\n    - Test SOC analyst response to real attack indicators\n    - Identify detection gaps for credential access and lateral movement\n    - Measure detection latency for each technique\n  threat_scenario: FIN7 campaign targeting financial data via spearphishing\n  authorization: Approved by CISO, Change Request CR-2024-0567\n  communication: #purple-team-2024q1 Slack channel\n```\n\n### Step 2: Build ATT&CK-Mapped Test Plan\n\nCreate technique-by-technique test matrix:\n\n| # | ATT&CK ID | Technique | Test Tool | Expected Detection | Blue Team Metric |\n|---|-----------|-----------|-----------|-------------------|------------------|\n| 1 | T1566.001 | Spearphishing Attachment | Manual email | Email gateway alert | Detection Y\u002FN, latency |\n| 2 | T1204.002 | User Execution | Macro document | Sysmon process creation | Detection Y\u002FN, latency |\n| 3 | T1059.001 | PowerShell | Atomic RT #1-3 | PowerShell execution alert | Detection Y\u002FN, latency |\n| 4 | T1053.005 | Scheduled Task | Atomic RT | Scheduled task creation alert | Detection Y\u002FN, latency |\n| 5 | T1547.001 | Registry Run Keys | Atomic RT | Registry modification alert | Detection Y\u002FN, latency |\n| 6 | T1003.001 | LSASS Memory | Mimikatz | Credential dumping alert | Detection Y\u002FN, latency |\n| 7 | T1550.002 | Pass-the-Hash | Mimikatz | NTLM anomaly detection | Detection Y\u002FN, latency |\n| 8 | T1021.002 | SMB\u002FPsExec | PsExec | PsExec service creation alert | Detection Y\u002FN, latency |\n| 9 | T1047 | WMI | wmic \u002Fnode | WMI remote execution alert | Detection Y\u002FN, latency |\n| 10| T1021.001 | RDP | xfreerdp | RDP lateral movement alert | Detection Y\u002FN, latency |\n| 11| T1071.001 | Web C2 | Cobalt Strike | C2 beacon detection | Detection Y\u002FN, latency |\n| 12| T1041 | Exfiltration C2 | Rclone | Data exfiltration alert | Detection Y\u002FN, latency |\n| 13| T1490 | Inhibit Recovery | vssadmin | Shadow copy deletion alert | Detection Y\u002FN, latency |\n| 14| T1486 | Data Encrypted | Test encryption | Mass encryption detection | Detection Y\u002FN, latency |\n| 15| T1070.001 | Clear Logs | wevtutil | Log clearing detection | Detection Y\u002FN, latency |\n\n### Step 3: Execute Red Team Techniques\n\nRun each technique with Atomic Red Team (or manual execution):\n\n```powershell\n# Install Atomic Red Team\nIEX (IWR 'https:\u002F\u002Fraw.githubusercontent.com\u002Fredcanaryco\u002Finvoke-atomicredteam\u002Fmaster\u002Finstall-atomicredteam.ps1' -UseBasicParsing)\nInstall-AtomicRedTeam -getAtomics\n\n# Test 1: T1059.001 — PowerShell Execution\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1059.001 - PowerShell\"\nInvoke-AtomicTest T1059.001 -TestNumbers 1\n# Notify blue team: \"T1059.001 executed at $(Get-Date)\"\n\n# Test 2: T1053.005 — Scheduled Task Creation\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1053.005 - Scheduled Task\"\nInvoke-AtomicTest T1053.005 -TestNumbers 1\n\n# Test 3: T1547.001 — Registry Run Key\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1547.001 - Registry Persistence\"\nInvoke-AtomicTest T1547.001 -TestNumbers 1,2\n\n# Test 4: T1003.001 — Credential Dumping\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1003.001 - LSASS Access\"\nInvoke-AtomicTest T1003.001 -TestNumbers 1,2\n\n# Test 5: T1490 — Shadow Copy Deletion\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1490 - Inhibit Recovery\"\nInvoke-AtomicTest T1490 -TestNumbers 1\n\n# Cleanup after each test\nInvoke-AtomicTest T1059.001 -TestNumbers 1 -Cleanup\nInvoke-AtomicTest T1053.005 -TestNumbers 1 -Cleanup\nInvoke-AtomicTest T1547.001 -TestNumbers 1,2 -Cleanup\n```\n\n### Step 4: Monitor Blue Team Detection in Real-Time\n\nBlue team monitors SIEM during execution:\n\n```spl\n--- Real-time purple team monitoring dashboard\nindex=notable earliest=-1h\n| where Computer IN (\"WORKSTATION-TEST01\", \"DC-TEST\", \"FILESERVER-TEST\")\n  OR src IN (\"10.0.5.100\", \"10.0.5.200\", \"10.0.5.201\")\n| eval detection_latency = _time - orig_time\n| eval latency_seconds = round(detection_latency, 0)\n| sort _time\n| table _time, rule_name, urgency, src, dest, user, latency_seconds\n\n--- Check specific technique detection\nindex=sysmon Computer=\"WORKSTATION-TEST01\" earliest=-15m\n(EventCode=1 OR EventCode=3 OR EventCode=10 OR EventCode=11 OR EventCode=13)\n| sort _time\n| table _time, EventCode, Image, CommandLine, TargetFilename, TargetObject\n```\n\nRecord results in real-time:\n\n```python\nexercise_results = {\n    \"exercise_id\": \"PT-2024-Q1\",\n    \"results\": [\n        {\n            \"technique\": \"T1059.001\",\n            \"name\": \"PowerShell Execution\",\n            \"execution_time\": \"09:15:00\",\n            \"detected\": True,\n            \"alert_name\": \"Suspicious PowerShell Encoded Command\",\n            \"detection_time\": \"09:15:47\",\n            \"latency_seconds\": 47,\n            \"notes\": \"Detected via Sysmon EventCode 1 with encoded command pattern\"\n        },\n        {\n            \"technique\": \"T1003.001\",\n            \"name\": \"LSASS Memory Access\",\n            \"execution_time\": \"10:30:00\",\n            \"detected\": False,\n            \"alert_name\": None,\n            \"detection_time\": None,\n            \"latency_seconds\": None,\n            \"notes\": \"GAP: No detection rule for LSASS access. Sysmon EventCode 10 present but no correlation rule.\"\n        }\n    ]\n}\n```\n\n### Step 5: Collaborative Gap Remediation\n\nFor each gap, the blue team builds detection rules immediately:\n\n```spl\n--- Gap: T1003.001 — No LSASS access detection\n--- Build rule during exercise\nindex=sysmon EventCode=10 TargetImage=\"*\\\\lsass.exe\"\nGrantedAccess IN (\"0x1010\", \"0x1038\", \"0x1fffff\", \"0x40\")\nNOT SourceImage IN (\"*\\\\svchost.exe\", \"*\\\\csrss.exe\", \"*\\\\MsMpEng.exe\")\n| stats count by Computer, SourceImage, SourceUser, GrantedAccess\n| where count > 0\n```\n\nAfter building, re-test:\n```\nRed Team: \"Re-executing T1003.001 at 11:45\"\nBlue Team: \"Confirmed — alert 'LSASS Memory Access Detected' fired at 11:45:32 (32s latency)\"\nResult: GAP CLOSED\n```\n\n### Step 6: Generate Exercise Report\n\n```python\ndef generate_purple_team_report(results):\n    total = len(results[\"results\"])\n    detected = sum(1 for r in results[\"results\"] if r[\"detected\"])\n    gaps = sum(1 for r in results[\"results\"] if not r[\"detected\"])\n    avg_latency = sum(r[\"latency_seconds\"] for r in results[\"results\"]\n                      if r[\"latency_seconds\"]) \u002F max(detected, 1)\n\n    report = f\"\"\"\nPURPLE TEAM EXERCISE REPORT — {results['exercise_id']}\n{'=' * 60}\n\nSUMMARY:\n  Techniques Tested:     {total}\n  Detected:              {detected} ({detected\u002Ftotal*100:.0f}%)\n  Gaps Identified:       {gaps} ({gaps\u002Ftotal*100:.0f}%)\n  Avg Detection Latency: {avg_latency:.0f} seconds\n\nDETAILED RESULTS:\n\"\"\"\n    for r in results[\"results\"]:\n        status = \"DETECTED\" if r[\"detected\"] else \"GAP\"\n        latency = f\"{r['latency_seconds']}s\" if r[\"latency_seconds\"] else \"N\u002FA\"\n        report += f\"  [{status}] {r['technique']} — {r['name']} (Latency: {latency})\\n\"\n        if not r[\"detected\"]:\n            report += f\"          Action: {r['notes']}\\n\"\n\n    return report\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|-----------|\n| **Purple Team** | Collaborative exercise where red (offensive) and blue (defensive) teams work together to validate and improve detection |\n| **Adversary Emulation** | Structured simulation of specific threat actor TTPs for testing defensive capabilities |\n| **Detection Validation** | Process of confirming that detection rules fire correctly when the targeted technique is executed |\n| **Detection Latency** | Time between technique execution and SIEM alert generation — measured during purple team exercises |\n| **Gap Remediation** | Immediate creation or tuning of detection rules for techniques that were not detected during testing |\n| **Atomic Red Team** | Open-source library of small, focused tests for individual ATT&CK techniques |\n\n## Tools & Systems\n\n- **Atomic Red Team**: Open-source attack test library from Red Canary for technique-by-technique validation\n- **MITRE Caldera**: Automated adversary emulation platform supporting ATT&CK-mapped attack chains\n- **Vectr**: Purple team management platform for tracking exercise results and detection coverage improvements\n- **Prelude Operator**: Adversary emulation tool supporting automated multi-step attack scenarios\n- **AttackIQ**: Breach and Attack Simulation (BAS) platform for continuous detection validation\n\n## Common Scenarios\n\n- **Quarterly Validation**: Test top 20 detection rules against ATT&CK techniques to ensure continued effectiveness\n- **New Tool Validation**: After deploying new EDR, validate detection coverage against baseline techniques\n- **Analyst Training**: Junior analysts observe real attacks in real-time with expert guidance on SIEM investigation\n- **Post-Incident Validation**: After a real incident, emulate the attack chain to verify detection improvements\n- **Compliance Evidence**: Document detection validation results for SOC 2, ISO 27001, or PCI DSS audits\n\n## Output Format\n\n```\nPURPLE TEAM EXERCISE REPORT — PT-2024-Q1\n━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\nDate:         2024-03-20 (09:00-17:00 UTC)\nScenario:     FIN7 Financial Sector Campaign\nScope:        Finance VLAN (10.0.5.0\u002F24)\n\nRESULTS:\n  Techniques Tested:     15\n  Detected:              11 (73%)\n  Gaps Identified:       4 (27%)\n  Gaps Remediated Same Day: 3\n  Avg Detection Latency: 38 seconds\n\nDETAILED RESULTS:\n  [PASS]  T1566.001 Spearphishing Attachment      — 12s latency\n  [PASS]  T1204.002 User Execution (Macro)         — 8s latency\n  [PASS]  T1059.001 PowerShell Execution            — 47s latency\n  [PASS]  T1053.005 Scheduled Task                  — 23s latency\n  [PASS]  T1547.001 Registry Run Keys               — 31s latency\n  [FAIL]  T1003.001 LSASS Memory Access             — REMEDIATED during exercise\n  [FAIL]  T1550.002 Pass-the-Hash                   — REMEDIATED during exercise\n  [PASS]  T1021.002 PsExec                          — 15s latency\n  [PASS]  T1047 WMI Remote Execution                — 42s latency\n  [PASS]  T1021.001 RDP Lateral Movement            — 28s latency\n  [FAIL]  T1071.001 Web C2 Beaconing                — REMEDIATED during exercise\n  [PASS]  T1041 Exfiltration over C2                — 67s latency\n  [PASS]  T1490 Shadow Copy Deletion                — 5s latency\n  [FAIL]  T1486 Data Encryption for Impact          — OPEN — requires endpoint telemetry\n  [PASS]  T1070.001 Event Log Clearing              — 11s latency\n\nPOST-EXERCISE COVERAGE: 93% (14\u002F15) — up from 73% at start\nREMAINING GAP: T1486 requires EDR file monitoring enhancement\n```\n","# Performing Purple Team Exercise\n\n## When to Use\n\nUse this skill when:\n- SOC teams need to validate that detection rules actually fire for the threats they target\n- Red team assessments produced findings that need translation into detection improvements\n- New detection tools or SIEM migrations require validation of detection coverage\n- Analyst training requires hands-on experience with real attack techniques and SIEM responses\n- Quarterly or semi-annual detection validation cycles are scheduled\n\n**Do not use** for unannounced red team engagements — purple team exercises require explicit coordination between offensive and defensive teams with real-time collaboration.\n\n## Prerequisites\n\n- Red team capability: internal team or contracted purple team operator\n- Attack simulation tools: Atomic Red Team, MITRE Caldera, or C2 framework (authorized)\n- SIEM access for real-time alert monitoring during exercise\n- ATT&CK-mapped detection rule inventory with expected alert names\n- Isolated test environment or approved production scope with change management approval\n- Communication channel (Slack\u002FTeams) for real-time red-blue coordination\n\n## Workflow\n\n### Step 1: Define Exercise Scope and Objectives\n\nDocument exercise parameters:\n\n```yaml\npurple_team_exercise:\n  exercise_id: PT-2024-Q1\n  date: 2024-03-20\n  duration: 8 hours (09:00-17:00 UTC)\n  scope:\n    environment: Production (Finance VLAN, 10.0.5.0\u002F24)\n    systems_in_scope:\n      - WORKSTATION-TEST01 (10.0.5.100) — Test endpoint\n      - DC-TEST (10.0.5.200) — Test domain controller\n      - FILESERVER-TEST (10.0.5.201) — Test file server\n    systems_excluded:\n      - All production domain controllers\n      - Customer-facing systems\n  objectives:\n    - Validate 15 detection rules mapped to FIN7 TTPs\n    - Test SOC analyst response to real attack indicators\n    - Identify detection gaps for credential access and lateral movement\n    - Measure detection latency for each technique\n  threat_scenario: FIN7 campaign targeting financial data via spearphishing\n  authorization: Approved by CISO, Change Request CR-2024-0567\n  communication: #purple-team-2024q1 Slack channel\n```\n\n### Step 2: Build ATT&CK-Mapped Test Plan\n\nCreate technique-by-technique test matrix:\n\n| # | ATT&CK ID | Technique | Test Tool | Expected Detection | Blue Team Metric |\n|---|-----------|-----------|-----------|-------------------|------------------|\n| 1 | T1566.001 | Spearphishing Attachment | Manual email | Email gateway alert | Detection Y\u002FN, latency |\n| 2 | T1204.002 | User Execution | Macro document | Sysmon process creation | Detection Y\u002FN, latency |\n| 3 | T1059.001 | PowerShell | Atomic RT #1-3 | PowerShell execution alert | Detection Y\u002FN, latency |\n| 4 | T1053.005 | Scheduled Task | Atomic RT | Scheduled task creation alert | Detection Y\u002FN, latency |\n| 5 | T1547.001 | Registry Run Keys | Atomic RT | Registry modification alert | Detection Y\u002FN, latency |\n| 6 | T1003.001 | LSASS Memory | Mimikatz | Credential dumping alert | Detection Y\u002FN, latency |\n| 7 | T1550.002 | Pass-the-Hash | Mimikatz | NTLM anomaly detection | Detection Y\u002FN, latency |\n| 8 | T1021.002 | SMB\u002FPsExec | PsExec | PsExec service creation alert | Detection Y\u002FN, latency |\n| 9 | T1047 | WMI | wmic \u002Fnode | WMI remote execution alert | Detection Y\u002FN, latency |\n| 10| T1021.001 | RDP | xfreerdp | RDP lateral movement alert | Detection Y\u002FN, latency |\n| 11| T1071.001 | Web C2 | Cobalt Strike | C2 beacon detection | Detection Y\u002FN, latency |\n| 12| T1041 | Exfiltration C2 | Rclone | Data exfiltration alert | Detection Y\u002FN, latency |\n| 13| T1490 | Inhibit Recovery | vssadmin | Shadow copy deletion alert | Detection Y\u002FN, latency |\n| 14| T1486 | Data Encrypted | Test encryption | Mass encryption detection | Detection Y\u002FN, latency |\n| 15| T1070.001 | Clear Logs | wevtutil | Log clearing detection | Detection Y\u002FN, latency |\n\n### Step 3: Execute Red Team Techniques\n\nRun each technique with Atomic Red Team (or manual execution):\n\n```powershell\n# Install Atomic Red Team\nIEX (IWR 'https:\u002F\u002Fraw.githubusercontent.com\u002Fredcanaryco\u002Finvoke-atomicredteam\u002Fmaster\u002Finstall-atomicredteam.ps1' -UseBasicParsing)\nInstall-AtomicRedTeam -getAtomics\n\n# Test 1: T1059.001 — PowerShell Execution\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1059.001 - PowerShell\"\nInvoke-AtomicTest T1059.001 -TestNumbers 1\n# Notify blue team: \"T1059.001 executed at $(Get-Date)\"\n\n# Test 2: T1053.005 — Scheduled Task Creation\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1053.005 - Scheduled Task\"\nInvoke-AtomicTest T1053.005 -TestNumbers 1\n\n# Test 3: T1547.001 — Registry Run Key\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1547.001 - Registry Persistence\"\nInvoke-AtomicTest T1547.001 -TestNumbers 1,2\n\n# Test 4: T1003.001 — Credential Dumping\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1003.001 - LSASS Access\"\nInvoke-AtomicTest T1003.001 -TestNumbers 1,2\n\n# Test 5: T1490 — Shadow Copy Deletion\nWrite-Host \"[$(Get-Date -Format 'HH:mm:ss')] Executing T1490 - Inhibit Recovery\"\nInvoke-AtomicTest T1490 -TestNumbers 1\n\n# Cleanup after each test\nInvoke-AtomicTest T1059.001 -TestNumbers 1 -Cleanup\nInvoke-AtomicTest T1053.005 -TestNumbers 1 -Cleanup\nInvoke-AtomicTest T1547.001 -TestNumbers 1,2 -Cleanup\n```\n\n### Step 4: Monitor Blue Team Detection in Real-Time\n\nBlue team monitors SIEM during execution:\n\n```spl\n--- Real-time purple team monitoring dashboard\nindex=notable earliest=-1h\n| where Computer IN (\"WORKSTATION-TEST01\", \"DC-TEST\", \"FILESERVER-TEST\")\n  OR src IN (\"10.0.5.100\", \"10.0.5.200\", \"10.0.5.201\")\n| eval detection_latency = _time - orig_time\n| eval latency_seconds = round(detection_latency, 0)\n| sort _time\n| table _time, rule_name, urgency, src, dest, user, latency_seconds\n\n--- Check specific technique detection\nindex=sysmon Computer=\"WORKSTATION-TEST01\" earliest=-15m\n(EventCode=1 OR EventCode=3 OR EventCode=10 OR EventCode=11 OR EventCode=13)\n| sort _time\n| table _time, EventCode, Image, CommandLine, TargetFilename, TargetObject\n```\n\nRecord results in real-time:\n\n```python\nexercise_results = {\n    \"exercise_id\": \"PT-2024-Q1\",\n    \"results\": [\n        {\n            \"technique\": \"T1059.001\",\n            \"name\": \"PowerShell Execution\",\n            \"execution_time\": \"09:15:00\",\n            \"detected\": True,\n            \"alert_name\": \"Suspicious PowerShell Encoded Command\",\n            \"detection_time\": \"09:15:47\",\n            \"latency_seconds\": 47,\n            \"notes\": \"Detected via Sysmon EventCode 1 with encoded command pattern\"\n        },\n        {\n            \"technique\": \"T1003.001\",\n            \"name\": \"LSASS Memory Access\",\n            \"execution_time\": \"10:30:00\",\n            \"detected\": False,\n            \"alert_name\": None,\n            \"detection_time\": None,\n            \"latency_seconds\": None,\n            \"notes\": \"GAP: No detection rule for LSASS access. Sysmon EventCode 10 present but no correlation rule.\"\n        }\n    ]\n}\n```\n\n### Step 5: Collaborative Gap Remediation\n\nFor each gap, the blue team builds detection rules immediately:\n\n```spl\n--- Gap: T1003.001 — No LSASS access detection\n--- Build rule during exercise\nindex=sysmon EventCode=10 TargetImage=\"*\\\\lsass.exe\"\nGrantedAccess IN (\"0x1010\", \"0x1038\", \"0x1fffff\", \"0x40\")\nNOT SourceImage IN (\"*\\\\svchost.exe\", \"*\\\\csrss.exe\", \"*\\\\MsMpEng.exe\")\n| stats count by Computer, SourceImage, SourceUser, GrantedAccess\n| where count > 0\n```\n\nAfter building, re-test:\n```\nRed Team: \"Re-executing T1003.001 at 11:45\"\nBlue Team: \"Confirmed — alert 'LSASS Memory Access Detected' fired at 11:45:32 (32s latency)\"\nResult: GAP CLOSED\n```\n\n### Step 6: Generate Exercise Report\n\n```python\ndef generate_purple_team_report(results):\n    total = len(results[\"results\"])\n    detected = sum(1 for r in results[\"results\"] if r[\"detected\"])\n    gaps = sum(1 for r in results[\"results\"] if not r[\"detected\"])\n    avg_latency = sum(r[\"latency_seconds\"] for r in results[\"results\"]\n                      if r[\"latency_seconds\"]) \u002F max(detected, 1)\n\n    report = f\"\"\"\nPURPLE TEAM EXERCISE REPORT — {results['exercise_id']}\n{'=' * 60}\n\nSUMMARY:\n  Techniques Tested:     {total}\n  Detected:              {detected} ({detected\u002Ftotal*100:.0f}%)\n  Gaps Identified:       {gaps} ({gaps\u002Ftotal*100:.0f}%)\n  Avg Detection Latency: {avg_latency:.0f} seconds\n\nDETAILED RESULTS:\n\"\"\"\n    for r in results[\"results\"]:\n        status = \"DETECTED\" if r[\"detected\"] else \"GAP\"\n        latency = f\"{r['latency_seconds']}s\" if r[\"latency_seconds\"] else \"N\u002FA\"\n        report += f\"  [{status}] {r['technique']} — {r['name']} (Latency: {latency})\\n\"\n        if not r[\"detected\"]:\n            report += f\"          Action: {r['notes']}\\n\"\n\n    return report\n```\n\n## Key Concepts\n\n| Term | Definition |\n|------|-----------|\n| **Purple Team** | Collaborative exercise where red (offensive) and blue (defensive) teams work together to validate and improve detection |\n| **Adversary Emulation** | Structured simulation of specific threat actor TTPs for testing defensive capabilities |\n| **Detection Validation** | Process of confirming that detection rules fire correctly when the targeted technique is executed |\n| **Detection Latency** | Time between technique execution and SIEM alert generation — measured during purple team exercises |\n| **Gap Remediation** | Immediate creation or tuning of detection rules for techniques that were not detected during testing |\n| **Atomic Red Team** | Open-source library of small, focused tests for individual ATT&CK techniques |\n\n## Tools & Systems\n\n- **Atomic Red Team**: Open-source attack test library from Red Canary for technique-by-technique validation\n- **MITRE Caldera**: Automated adversary emulation platform supporting ATT&CK-mapped attack chains\n- **Vectr**: Purple team management platform for tracking exercise results and detection coverage improvements\n- **Prelude Operator**: Adversary emulation tool supporting automated multi-step attack scenarios\n- **AttackIQ**: Breach and Attack Simulation (BAS) platform for continuous detection validation\n\n## Common Scenarios\n\n- **Quarterly Validation**: Test top 20 detection rules against ATT&CK techniques to ensure continued effectiveness\n- **New Tool Validation**: After deploying new EDR, validate detection coverage against baseline techniques\n- **Analyst Training**: Junior analysts observe real attacks in real-time with expert guidance on SIEM investigation\n- **Post-Incident Validation**: After a real incident, emulate the attack chain to verify detection improvements\n- **Compliance Evidence**: Document detection validation results for SOC 2, ISO 27001, or PCI DSS audits\n\n## Output Format\n\n```\nPURPLE TEAM EXERCISE REPORT — PT-2024-Q1\n━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\nDate:         2024-03-20 (09:00-17:00 UTC)\nScenario:     FIN7 Financial Sector Campaign\nScope:        Finance VLAN (10.0.5.0\u002F24)\n\nRESULTS:\n  Techniques Tested:     15\n  Detected:              11 (73%)\n  Gaps Identified:       4 (27%)\n  Gaps Remediated Same Day: 3\n  Avg Detection Latency: 38 seconds\n\nDETAILED RESULTS:\n  [PASS]  T1566.001 Spearphishing Attachment      — 12s latency\n  [PASS]  T1204.002 User Execution (Macro)         — 8s latency\n  [PASS]  T1059.001 PowerShell Execution            — 47s latency\n  [PASS]  T1053.005 Scheduled Task                  — 23s latency\n  [PASS]  T1547.001 Registry Run Keys               — 31s latency\n  [FAIL]  T1003.001 LSASS Memory Access             — REMEDIATED during exercise\n  [FAIL]  T1550.002 Pass-the-Hash                   — REMEDIATED during exercise\n  [PASS]  T1021.002 PsExec                          — 15s latency\n  [PASS]  T1047 WMI Remote Execution                — 42s latency\n  [PASS]  T1021.001 RDP Lateral Movement            — 28s latency\n  [FAIL]  T1071.001 Web C2 Beaconing                — REMEDIATED during exercise\n  [PASS]  T1041 Exfiltration over C2                — 67s latency\n  [PASS]  T1490 Shadow Copy Deletion                — 5s latency\n  [FAIL]  T1486 Data Encryption for Impact          — OPEN — requires endpoint telemetry\n  [PASS]  T1070.001 Event Log Clearing              — 11s latency\n\nPOST-EXERCISE COVERAGE: 93% (14\u002F15) — up from 73% at start\nREMAINING GAP: T1486 requires EDR file monitoring enhancement\n```\n",{"name":5,"tags":25,"author":33,"domain":34,"license":15,"version":35,"nist_csf":36,"subdomain":41,"description":42,"mitre_attack":43,"d3fend_techniques":48},[26,27,28,29,30,31,32],"soc","purple-team","red-team","blue-team","mitre-attack","adversary-emulation","detection-validation","mahipal","cybersecurity","1.0",[37,38,39,40],"DE.CM-01","DE.AE-02","RS.MA-01","DE.AE-06","soc-operations","Performs purple team exercises by coordinating red team adversary emulation with blue team detection validation using MITRE ATT&CK-mapped attack scenarios, real-time detection testing, and collaborative gap remediation. Use when SOC teams need to validate detection capabilities, improve analyst skills, and close detection gaps through structured offensive-defensive collaboration.\n",[44,45,46,47],"T1078","T1685.002","T1685.005","T1566",[49,50,51,52,53],"File Metadata Consistency Validation","Application Protocol Command Analysis","Identifier Analysis","Content Format Conversion","Message Analysis","main","7540bbccf0c1ded6156a467b02c95b61ad62413f",".agents\u002Fskills\u002Fperforming-purple-team-exercise","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena","Currently exploring the intersection of tech","2026-09-11 03:02:31",{"source":8,"skillName":5,"commands":62,"prompt":72,"zipAvailable":73},[63,66,69],{"tool":64,"command":65},"npx","npx skills add NeelakshSaxena\u002FVayu --skill performing-purple-team-exercise",{"tool":67,"command":68},"bunx","bunx skills add NeelakshSaxena\u002FVayu --skill performing-purple-team-exercise",{"tool":70,"command":71},"pnpm","pnpm dlx skills add NeelakshSaxena\u002FVayu --skill performing-purple-team-exercise","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fperforming-purple-team-exercise\u002FSKILL.md",true,[75,79,85],{"path":76,"resourceType":76,"resourceTypeDesc":77,"sizeBytes":78,"sourceHtmlUrl":16},"LICENSE","许可证",11255,{"path":80,"resourceType":81,"resourceTypeDesc":82,"sizeBytes":83,"sourceHtmlUrl":84},"references\u002Fapi-reference.md","REFERENCE","参考文档",1681,"https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fperforming-purple-team-exercise\u002Freferences\u002Fapi-reference.md",{"path":86,"resourceType":87,"resourceTypeDesc":88,"sizeBytes":89,"sourceHtmlUrl":90},"scripts\u002Fagent.py","SCRIPT","脚本",7878,"https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fperforming-purple-team-exercise\u002Fscripts\u002Fagent.py",[92,99,106,113,120,127],{"skillNo":93,"name":94,"nameZh":6,"description":95,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":20},"01M7ACCCVNCFKMA9X6D15X6G98","runpodctl","Runpod CLI for managing GPU\u002FCPU workloads from the terminal — pods, serverless endpoints, templates, network volumes, Hub deploys, models, SSH, and file transfer (send\u002Freceive). Use for terminal\u002FCI\u002Fscripting, Hub browse\u002Fdeploy, SSH setup, `doctor`, or when the Runpod MCP tools are not connected. For structured tool calls in an MCP-enabled session, prefer runpod-mcp.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpodctl\u002FSKILL.md",[],[],{"skillNo":100,"name":101,"nameZh":6,"description":102,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":103,"categories":104,"keywords":105,"publishedAt":20},"01M7ACC63SRHEA5KMCHSMZK2TC","runpod","Start here for any Runpod task — running GPU\u002FCPU pods, deploying serverless endpoints, templates, network volumes, building images, or understanding how Runpod works. Routes to the right skill (runpod-mcp, runpodctl, flash, companion-clis, runpod-usage, runpod-templates, runpod-migrate) and indexes two dozen live-verified end-to-end examples (golden paths) — use it when the lane is unclear, and for any multi-step or provisioning task even when it is not.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod\u002FSKILL.md",[],[],{"skillNo":107,"name":108,"nameZh":6,"description":109,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":110,"categories":111,"keywords":112,"publishedAt":20},"01M7ACC0Q1C89N9BZBV91CTQTF","runpod-usage","How Runpod works and how to work it — pods vs serverless, GPU\u002FVRAM selection, storage, building a container, networking, plus the agentic pod development loop (provision → ssh-exec → set up → poll readiness) and on-pod install hygiene (uv\u002Fapt). Use to answer \"how does X work\", \"which GPU\", \"how do I build a container\", or \"how do I stand up a workload on a pod\". Guidance, not a tool — execute with runpodctl, runpod-mcp, or flash.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-usage\u002FSKILL.md",[],[],{"skillNo":114,"name":115,"nameZh":6,"description":116,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":117,"categories":118,"keywords":119,"publishedAt":20},"01M7ACBRPE345GF5GM5B8P8RRC","runpod-templates","Runpod's official prebuilt pod templates (ComfyUI, PyTorch, and others): what each image ships, which ports and paths it uses, how to pick one, how to pin a version, and what is missing on first boot. Use when a task says \"run \u003CX> on a pod\" and an official template already covers it, instead of building an image — and when a user needs help with or wants to fix something about a Runpod template they are already running (won't boot, can't reach the UI, missing models, wrong CUDA line, broken ComfyUI workflow metadata on imported workflows): start here and route onward. Deploy with runpodctl or runpod-mcp; end-to-end walkthroughs live in the runpod router's golden paths.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-templates\u002FSKILL.md",[],[],{"skillNo":121,"name":122,"nameZh":6,"description":123,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":124,"categories":125,"keywords":126,"publishedAt":20},"01M7ACBJATHKVX1TWES2F44GY8","runpod-migrate","Migrate a codebase from the Runpod GraphQL API or REST v1 to REST v2 — inventory which parts use which API version, rewrite the call sites, flag breaking changes, and verify. Use when someone asks to move to v2, asks what v2 would change, or asks which Runpod API their code is on. For managing infrastructure rather than migrating code, use runpod-mcp or runpodctl.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-migrate\u002FSKILL.md",[],[],{"skillNo":128,"name":129,"nameZh":6,"description":130,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":131,"categories":132,"keywords":133,"publishedAt":20},"01M7ACBC7GHVH6T9YEAPCG2AP8","runpod-mcp","Manage Runpod infrastructure — pods, serverless endpoints, jobs, templates, network volumes, container-registry auth, GPU\u002FCPU catalog, and billing — via the Runpod MCP server's structured tool calls. Use when the Runpod MCP tools (create-pod, list-endpoints, …) are connected in this session, or to connect them (hosted OAuth or local npx). Prefer this over runpodctl for plain infra CRUD when MCP is available; use runpodctl for the terminal, file transfer, or SSH setup.","https:\u002F\u002Fgithub.com\u002FNeelakshSaxena\u002FVayu\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frunpod-mcp\u002FSKILL.md",[],[]]