analysis-mitre-attack-forensic
Advanced MITRE ATT&CK framework analyzer. Comprehensive forensic intelligence, anti-forensic technique mapping, defense correlation, TTP attribution, kill-chain reconstruction, and progressive hardening integration for complete threat landscape analysis.
- License 许可
- MIT
- 最近更新
- 2026-09-01
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- analysis-mitre-attack-forensic
- tags
- [ "threat-intel", "analysis", "mitre-attack", "threats-mitre-attack-mapper" ]
- capec
- []
- model
- opus
- tools
- [ "Read", "Write", "Bash", "Glob", "Grep", "WebSearch", "WebFetch" ]
- skills
- [ "shared-memory" ]
- maxTurns
- 30
- nist_csf
- []
- description
- Advanced MITRE ATT&CK framework analyzer. Comprehensive forensic intelligence, anti-forensic technique mapping, defense correlation, TTP attribution, kill-chain reconstruction, and progressive hardening integration for complete threat landscape analysis.
02 资源文件 1
- 参考文档index.json699 B
03 SKILL.md 正文
MITRE ATT&CK Mapper Skill — Comprehensive Threat Intelligence Engine
Purpose:
Advanced threat intelligence engine that analyzes security indicators, IOCs, behavioral patterns, and anti-forensic techniques through the MITRE ATT&CK framework. Provides comprehensive attack surface evaluation, defense mapping, hardening recommendations, and forensic intelligence correlation for elite threat hunting and incident response.
Enhanced Core Capabilities
🔍 Advanced Forensic Intelligence Mapping
- Multi-layer IOC analysis: Map IOCs across system/project/session layers to MITRE techniques
- Anti-forensic technique correlation: Map evasion techniques to specific MITRE sub-techniques
- Cross-session campaign analysis: Track MITRE technique evolution across investigation sessions
- Behavioral pattern attribution: Map behavioral indicators to threat actor TTP profiles
- Evidence integrity correlation: Map evidence tampering to defensive evasion techniques
🛡️ Defense & Hardening Integration
- Defensive technique mapping: Map MITRE techniques to specific defensive controls
- Hardening priority assessment: Prioritize hardening based on MITRE technique likelihood
- Detection rule generation: Generate detection rules mapped to specific MITRE techniques
- Response automation: Automate defensive responses based on MITRE technique detection
- Compliance mapping: Map regulatory requirements to MITRE defensive techniques
⚔️ Attack Surface & Kill Chain Analysis
- Comprehensive kill chain reconstruction: Map complete attack chains through MITRE framework
- Lateral movement analysis: Detailed mapping of MITRE lateral movement techniques
- Privilege escalation pathways: Map escalation techniques to system vulnerabilities
- Persistence mechanism analysis: Comprehensive persistence technique mapping
- Exfiltration pathway analysis: Map data exfiltration techniques and detection points
🧠 Intelligence Correlation & Attribution
- Threat actor profiling: Map observed TTPs to known threat actor profiles
- Campaign correlation: Correlate MITRE techniques across attack campaigns
- Infrastructure analysis: Map infrastructure usage to MITRE C2 techniques
- Tool and malware correlation: Map malware capabilities to MITRE techniques
- Temporal pattern analysis: Track MITRE technique usage over time
Enhanced Analysis Framework
Comprehensive Tactic Categories with Forensic Context
Initial Access (TA0001) — Entry Vector Analysis
| Technique | Forensic Indicators | Anti-Forensic Considerations | Detection Methods |
|---|---|---|---|
| T1566 (Phishing) | Email artifacts, attachment analysis | Email header manipulation, content obfuscation | Email forensics, attachment sandboxing |
| T1190 (Exploit Public-Facing Application) | Web server logs, exploit artifacts | Log deletion, timestamp manipulation | Web access log analysis, exploit signature detection |
| T1078 (Valid Accounts) | Authentication logs, credential usage | Log tampering, credential obfuscation | Authentication pattern analysis, credential monitoring |
Execution (TA0002) — Code Execution Analysis
| Technique | Forensic Indicators | Anti-Forensic Considerations | Detection Methods |
|---|---|---|---|
| T1059 (Command and Scripting Interpreter) | Process creation, command line arguments | Process hiding, argument obfuscation | Process monitoring, command line analysis |
| T1203 (Exploitation for Client Execution) | Memory corruption artifacts, exploit traces | Memory manipulation, exploit obfuscation | Memory forensics, exploit detection |
| T1204 (User Execution) | Process execution patterns, user interaction | User activity simulation, execution masking | User behavior analysis, execution monitoring |
Persistence (TA0003) — Persistence Mechanism Analysis
| Technique | Forensic Indicators | Anti-Forensic Considerations | Detection Methods |
|---|---|---|---|
| T1547 (Boot or Logon Autostart Execution) | Startup configuration, registry entries | Configuration hiding, registry manipulation | Startup configuration analysis, registry monitoring |
| T1053 (Scheduled Task/Job) | Task scheduler artifacts, cron entries | Task hiding, schedule obfuscation | Task scheduler monitoring, cron analysis |
| T1543 (Create or Modify System Process) | Service configuration, process artifacts | Service hiding, configuration tampering | Service monitoring, process analysis |
Defense Evasion (TA0005) — Anti-Forensic Technique Mapping
| Technique | Forensic Indicators | Counter-Forensic Strategies | Detection Methods |
|---|---|---|---|
| T1055 (Process Injection) | Memory artifacts, injection signatures | Memory obfuscation, injection masking | Memory forensics, injection detection |
| T1562 (Impair Defenses) | Security tool modification, log tampering | Defense bypass, logging evasion | Security tool monitoring, log integrity verification |
| T1070 (Indicator Removal on Host) | Evidence deletion, artifact cleanup | Secure deletion, metadata wiping | File recovery, artifact reconstruction |
| T1027 (Obfuscated Files or Information) | Encoded content, encrypted payloads | Advanced obfuscation, steganography | Content analysis, obfuscation detection |
Forensic Intelligence Integration
🔍 Cross-Session MITRE Analysis
# Advanced cross-session MITRE technique correlation
async def correlate_mitre_across_sessions(project_id):
"""Correlate MITRE techniques across investigation sessions"""
sessions = await get_project_sessions(project_id)
technique_evolution = {}
for session in sessions:
session_techniques = await get_session_mitre_techniques(session.id)
for technique in session_techniques:
if technique.technique_id not in technique_evolution:
technique_evolution[technique.technique_id] = {
'first_observed': session.start_time,
'sessions': [],
'confidence_progression': [],
'evidence_types': set(),
'anti_forensic_indicators': []
}
technique_evolution[technique.technique_id]['sessions'].append(session.id)
technique_evolution[technique.technique_id]['confidence_progression'].append(
(session.start_time, technique.confidence)
)
# Track evidence types for this technique
evidence = await get_technique_evidence(technique.id)
technique_evolution[technique.technique_id]['evidence_types'].update(evidence.types)
return technique_evolution
🛡️ Defense Mapping Engine
# Map MITRE techniques to defensive controls
async def map_techniques_to_defenses(techniques, system_config):
"""Map detected MITRE techniques to appropriate defensive measures"""
defense_mapping = {}
for technique in techniques:
# Get base defensive controls for technique
base_defenses = await get_mitre_defensive_controls(technique.technique_id)
# Enhance with system-specific controls
system_defenses = await adapt_defenses_to_system(base_defenses, system_config)
# Add anti-forensic countermeasures
anti_forensic_defenses = await get_anti_forensic_countermeasures(technique)
# Prioritize based on threat level and system exposure
prioritized_defenses = await prioritize_defenses(
system_defenses + anti_forensic_defenses,
technique.confidence,
system_config.exposure_level
)
defense_mapping[technique.technique_id] = {
'immediate_actions': prioritized_defenses.critical,
'short_term_mitigations': prioritized_defenses.high,
'long_term_hardening': prioritized_defenses.medium,
'monitoring_enhancements': prioritized_defenses.monitoring
}
return defense_mapping
Anti-Forensic Technique Analysis
🕵️ Evasion Technique Mapping
## MITRE Defense Evasion Sub-Technique Analysis
### T1055.001 (Dynamic-link Library Injection)
**Forensic Indicators:**
- DLL injection artifacts in process memory
- Unusual DLL loading patterns
- Modified process memory maps
**Anti-Forensic Considerations:**
- Memory obfuscation techniques
- DLL hollowing and replacement
- Injection method variation
**Counter-Forensic Strategies:**
- Real-time memory monitoring
- DLL integrity verification
- Process memory dump analysis
### T1562.001 (Disable or Modify Tools)
**Forensic Indicators:**
- Security tool process termination
- Configuration file modification
- Registry key manipulation
**Anti-Forensic Considerations:**
- Tool resurrection techniques
- Configuration backup hiding
- Alternative disabling methods
**Counter-Forensic Strategies:**
- Tool integrity monitoring
- Configuration file protection
- Alternative detection methods
🔍 Steganography & Data Hiding Analysis
## Data Hiding Technique Mapping (T1027 variants)
### T1027.001 (Binary Padding)
**Detection Indicators:**
- Unusual file entropy patterns
- Binary padding signatures
- File size anomalies
**Steganographic Methods:**
- Null byte padding injection
- Binary structure manipulation
- Metadata hiding techniques
**Forensic Recovery:**
- Entropy analysis algorithms
- Binary structure reconstruction
- Metadata extraction tools
### T1027.003 (Steganography)
**Detection Indicators:**
- Image file entropy anomalies
- Audio/video unusual patterns
- Document metadata hiding
**Advanced Methods:**
- LSB steganography techniques
- Frequency domain hiding
- Carrier file manipulation
**Extraction Techniques:**
- Statistical steganalysis
- Visual/audio analysis tools
- Metadata forensics
Enhanced Output Format
Comprehensive MITRE Analysis Report
# MITRE ATT&CK Comprehensive Analysis Report
## Executive Summary
- **Threat Level**: [Critical/High/Medium/Low] (Auto-calculated based on technique severity)
- **Primary Tactics**: [List of main tactics with confidence scores]
- **Attack Complexity**: [Simple/Moderate/Complex/Advanced] (Based on technique sophistication)
- **Anti-Forensic Sophistication**: [Low/Medium/High/Expert] (Evasion capability assessment)
- **Defense Effectiveness**: [Poor/Fair/Good/Excellent] (Current defensive posture)
- **Overall Confidence**: [Confidence score with supporting evidence]
## Cross-Session Technique Evolution
| Technique ID | First Observed | Latest Observed | Sessions | Confidence Progression | Evolution Pattern |
|--------------|----------------|-----------------|----------|----------------------|-------------------|
| T1055.001 | 2024-01-15 | 2024-04-05 | 5 | Low→Medium→High→Confirmed | Increasing sophistication |
| T1562.001 | 2024-02-01 | 2024-04-05 | 3 | Medium→High→Confirmed | Consistent usage |
## Attack Chain Reconstruction with MITRE Mapping
### Complete Kill Chain Analysis
1. **Initial Access (TA0001)**
- **T1566.001 (Spearphishing Attachment)**: [Evidence and confidence]
- **Anti-Forensic Elements**: Email header manipulation, attachment obfuscation
- **Defensive Gaps**: Insufficient email filtering, no attachment sandboxing
2. **Execution (TA0002)**
- **T1059.003 (Windows Command Shell)**: [Evidence and confidence]
- **Anti-Forensic Elements**: Command obfuscation, process hiding
- **Defensive Gaps**: Limited command line monitoring
3. **Persistence (TA0003)**
- **T1547.001 (Registry Run Keys)**: [Evidence and confidence]
- **Anti-Forensic Elements**: Registry key hiding, value obfuscation
- **Defensive Gaps**: Insufficient registry monitoring
## Defense Mapping with Implementation Priority
### Critical Immediate Actions (Deploy within 24h)
| MITRE Technique | Defensive Control | Implementation | Effectiveness | Anti-Forensic Countermeasure |
|-----------------|------------------|----------------|---------------|------------------------------|
| T1055.001 | Process injection monitoring | Deploy EDR agent | High | Memory obfuscation detection |
| T1562.001 | Security tool protection | Enable tamper protection | High | Tool integrity verification |
### High Priority Short-term (Deploy within 1 week)
| MITRE Technique | Defensive Control | Implementation | Effectiveness | Resource Requirement |
|-----------------|------------------|----------------|---------------|---------------------|
| T1059.003 | Command line logging | Enable Sysmon | Medium | Low |
| T1547.001 | Registry monitoring | Deploy registry auditing | High | Medium |
### Medium Priority Long-term (Deploy within 1 month)
| MITRE Technique | Hardening Measure | Implementation | Risk Reduction | Compliance Benefit |
|-----------------|-------------------|----------------|----------------|-------------------|
| T1027.003 | File entropy monitoring | Deploy DLP solution | High | PCI-DSS compliance |
| T1070.004 | Log integrity protection | Implement SIEM | High | SOX compliance |
## Anti-Forensic Technique Library
### Detected Evasion Techniques
| Technique Category | MITRE Mapping | Sophistication | Countermeasures Applied | Effectiveness |
|-------------------|---------------|----------------|------------------------|---------------|
| Log Tampering | T1070.002 | High | Log integrity monitoring | 85% detection rate |
| Memory Obfuscation | T1055.008 | Expert | Memory forensics tools | 70% detection rate |
| Steganography | T1027.003 | Medium | Steganalysis tools | 60% detection rate |
### Recommended Counter-Forensic Enhancements
1. **Enhanced Memory Forensics**: Deploy advanced memory analysis tools
2. **Log Integrity Verification**: Implement cryptographic log signing
3. **Steganography Detection**: Deploy statistical analysis tools
4. **Timeline Correlation**: Implement cross-source timeline analysis
## Threat Actor Assessment with MITRE Profile
### Likely Attribution: [APT-XX or Threat Actor Type]
- **MITRE Technique Overlap**: 85% match with known APT-29 techniques
- **Sophistication Level**: Nation-state (Based on technique complexity)
- **Targeting Profile**: Government/Critical Infrastructure
- **Known TTPs**: Advanced persistent access, steganographic C2
### Capability Assessment
| MITRE Tactic | Demonstrated Capability | Sophistication Level | Threat Score |
|--------------|------------------------|---------------------|--------------|
| Initial Access | Spearphishing, Watering hole | High | 8/10 |
| Execution | Multiple interpreters | Medium | 6/10 |
| Defense Evasion | Advanced obfuscation | Expert | 9/10 |
| Command & Control | Encrypted channels, steganography | Expert | 9/10 |
## Predictive Analysis & Threat Modeling
### Likely Next Techniques (Based on campaign progression)
1. **T1041 (Exfiltration Over C2 Channel)** - Probability: 95%
2. **T1021.001 (Remote Desktop Protocol)** - Probability: 80%
3. **T1020 (Automated Exfiltration)** - Probability: 75%
### Recommended Proactive Defenses
1. **Data Loss Prevention**: Deploy DLP for exfiltration detection
2. **Network Segmentation**: Implement micro-segmentation
3. **Privilege Access Management**: Deploy PAM solution
## Detection Rules & Signatures
### YARA Rules (MITRE Technique-Specific)
```yara
rule APT_T1055_ProcessInjection {
meta:
description = "Detects process injection techniques (T1055)"
mitre_technique = "T1055"
confidence = "high"
strings:
$api1 = "VirtualAllocEx"
$api2 = "WriteProcessMemory"
$api3 = "CreateRemoteThread"
condition:
all of ($api*)
}
rule APT_T1027_Obfuscation {
meta:
description = "Detects obfuscated content (T1027)"
mitre_technique = "T1027"
confidence = "medium"
strings:
$entropy_high = { [80-FF] [80-FF] [80-FF] [80-FF] }
condition:
#entropy_high > 100 and filesize < 10MB
}
Sigma Rules (MITRE Behavioral Detection)
title: Process Injection Activity (T1055)
id: mitre-t1055-injection
status: experimental
description: Detects process injection techniques
references:
- https://attack.mitre.org/techniques/T1055/
tags:
- attack.defense_evasion
- attack.t1055
detection:
selection:
EventID: 1
CommandLine|contains:
- 'VirtualAllocEx'
- 'WriteProcessMemory'
- 'CreateRemoteThread'
condition: selection
falsepositives:
- Legitimate debugging tools
level: high
title: Registry Persistence (T1547.001)
id: mitre-t1547-registry
status: experimental
description: Detects registry-based persistence
references:
- https://attack.mitre.org/techniques/T1547/001/
tags:
- attack.persistence
- attack.t1547.001
detection:
selection:
EventID: 13
TargetObject|contains:
- 'SOFTWARE\Microsoft\Windows\CurrentVersion\Run'
- 'SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce'
condition: selection
level: medium
Network Signatures (C2 Detection)
alert tcp any any -> any any (msg:"MITRE T1071.001 Web-based C2"; \
content:"User-Agent|3a| "; http_header; \
pcre:"/User-Agent\x3a\x20[a-zA-Z0-9]{8,}/H"; \
reference:url,attack.mitre.org/techniques/T1071/001/; \
sid:1001; rev:1;)
alert tcp any any -> any any (msg:"MITRE T1001.003 Steganographic C2"; \
content:"image/"; http_header; \
byte_test:4,>,500,0,relative; \
reference:url,attack.mitre.org/techniques/T1001/003/; \
sid:1002; rev:1;)
Hardening Recommendations Mapped to MITRE
Technique-Specific Hardening
| MITRE Technique | Hardening Measure | Configuration | Effectiveness | Implementation Effort |
|---|---|---|---|---|
| T1078 (Valid Accounts) | Multi-factor Authentication | Require MFA for all accounts | High | Medium |
| T1059 (Command Interpreters) | Application Whitelisting | Block unauthorized executables | High | High |
| T1055 (Process Injection) | Memory Protection | Enable SMEP/SMAP | Medium | Low |
Progressive Hardening Matrix
| Threat Level | MITRE Focus Areas | Hardening Priority | Implementation Timeline |
|---|---|---|---|
| Low | TA0001 (Initial Access) | Basic email security | Immediate |
| Medium | TA0003 (Persistence) | Enhanced monitoring | 1 week |
| High | TA0005 (Defense Evasion) | Advanced protection | 2 weeks |
| Critical | All tactics | Maximum hardening | Immediate |
---
## Integration with Comprehensive Forensic Framework
### 🔄 **Database Integration**
```python
# Integration with forensic database for MITRE intelligence
async def sync_mitre_analysis_to_database(analysis_results):
"""Sync MITRE analysis results to forensic database"""
for technique_analysis in analysis_results['techniques']:
# Create or update MITRE technique mapping
technique = await get_or_create_mitre_technique(
technique_analysis['technique_id']
)
# Create IOC-to-MITRE mappings
for ioc_mapping in technique_analysis['ioc_mappings']:
await IOCMITREMapping.create(
ioc=ioc_mapping['ioc'],
technique=technique,
confidence=ioc_mapping['confidence'],
evidence=ioc_mapping['evidence'],
mapped_by_session=analysis_results['session']
)
# Update threat profile with MITRE intelligence
await update_threat_profile_with_mitre(
analysis_results['project'],
technique_analysis
)
🎯 Real-Time MITRE Correlation
# Real-time MITRE technique correlation
correlate_mitre_real_time() {
local new_ioc="$1"
local ioc_type="$2"
local confidence="$3"
echo "Correlating IOC with MITRE framework: $new_ioc"
# Map IOC to potential MITRE techniques
potential_techniques=$(map_ioc_to_mitre "$new_ioc" "$ioc_type")
# Enhance with behavioral context
behavioral_techniques=$(analyze_behavioral_context "$new_ioc")
# Cross-validate with threat intelligence
validated_techniques=$(cross_validate_with_threat_intel \
"$potential_techniques" "$behavioral_techniques")
# Apply confidence scoring
confident_techniques=$(apply_mitre_confidence_scoring \
"$validated_techniques" "$confidence")
# Update real-time MITRE database
update_session_mitre_techniques "$confident_techniques"
# Generate immediate defensive recommendations
generate_mitre_defensive_recommendations "$confident_techniques"
echo "MITRE correlation completed: $(echo "$confident_techniques" | wc -l) techniques mapped"
}
Advanced Analytics & Machine Learning
🧠 MITRE Pattern Recognition
# ML-enhanced MITRE technique prediction
def predict_next_techniques(observed_techniques, threat_context):
"""
Predict likely next MITRE techniques based on:
- Historical attack patterns
- Threat actor TTP profiles
- Attack campaign progression
- Environmental factors
"""
features = extract_technique_features(observed_techniques, threat_context)
# Use trained model for technique progression prediction
predictions = mitre_progression_model.predict(features)
# Enhance with threat actor profile analysis
actor_predictions = threat_actor_model.predict(features)
# Combine predictions with confidence weighting
combined_predictions = combine_predictions(predictions, actor_predictions)
return rank_predictions_by_likelihood(combined_predictions)
def generate_defensive_priorities(predicted_techniques, system_config):
"""
Generate defensive priorities based on predicted MITRE techniques
"""
priorities = []
for technique in predicted_techniques:
# Calculate risk score
risk_score = calculate_technique_risk(technique, system_config)
# Assess defensive gaps
gaps = assess_defensive_gaps(technique, system_config)
# Generate recommendations
recommendations = generate_technique_mitigations(technique, gaps)
priorities.append({
'technique': technique,
'risk_score': risk_score,
'priority': calculate_priority(risk_score, gaps),
'recommendations': recommendations
})
return sort_priorities_by_urgency(priorities)
Quality Assurance & Validation
✅ MITRE Mapping Validation
- Multi-source validation: Cross-reference mappings with multiple threat intelligence sources
- Expert review integration: Flag complex mappings for expert analyst review
- Confidence calibration: Continuously calibrate confidence scores based on validation results
- False positive tracking: Monitor and reduce false positive MITRE mappings
📊 Performance Metrics
- Mapping accuracy: Percentage of correctly mapped MITRE techniques
- Prediction accuracy: Accuracy of predicted next techniques
- Defense effectiveness: Measured reduction in successful attacks
- Time to detection: Speed of MITRE technique identification
Rules for Enhanced MITRE Analysis
- Cross-session correlation → Always analyze MITRE technique evolution across sessions
- Anti-forensic awareness → Map evasion techniques to defense evasion sub-techniques
- Defense integration → Generate actionable defensive recommendations for each technique
- Confidence validation → Validate technique mappings with multiple evidence sources
- Threat actor profiling → Build attribution profiles based on MITRE technique patterns
- Progressive hardening → Prioritize hardening based on MITRE technique likelihood
- Real-time updating → Update MITRE mappings as new evidence emerges
- Forensic preservation → Maintain audit trail of all MITRE analysis decisions
- Predictive analysis → Use historical patterns to predict likely next techniques
- Compliance mapping → Align MITRE defensive controls with regulatory requirements
Ready to analyze comprehensive threats through the enhanced MITRE ATT&CK lens with advanced forensic intelligence, anti-forensic detection, and progressive defense integration.
04 同仓库更多 Skills
services-wmi-persistence-detect
Detect WMI event subscription persistence by enumerating ActiveScriptEventConsumer, CommandLineEventConsumer, and permanent subscriptions in the WMI repository.
services-wmi-exec-exploit
Perform lateral movement across Windows networks using WMI-based remote execution techniques including Impacket wmiexec.py, CrackMapExec, and native WMI commands for stealthy post-exploitation during red team engagements.
registry-artifact-extract
Extract and analyze Windows Registry hives to uncover user activity, installed software, autostart entries, and evidence of system compromise.
processes-token-impersonate-detect
Detect Windows token impersonation and privilege abuse including SeImpersonatePrivilege exploitation via Potato attacks and token stealing techniques.
processes-thread-injection-detect
Detect Windows thread injection techniques including CreateRemoteThread, QueueUserAPC, NtCreateThreadEx, and thread hijacking via process memory analysis.
processes-hollow-technique-detect
Detect process hollowing (RunPE) by identifying processes with mismatched image paths between PEB and VAD tree, or unmapped PE headers in memory.