🛡️ SIEM Log Correlation & Detection Eng (SOC Analyst Focus)
**Core Concept**
- SIEM ingests logs from FW, EPs, servers, PAM (e.g., CyberArk), and cloud services.
- Correlation rules detect suspicious patterns across logs.
- Analysts tune rules to cut FPs while catching real threats.
**Data Sources**
- Auth Logs: Win Event IDs (4624/4625/4672), Linux auth.log.
- Net Logs: FW denies, IDS/IPS alerts, NetFlow.
- Priv Access Logs: CyberArk vault access, sess recordings, cred checkouts.
- Cloud Telemetry: AWS CloudTrail, Azure AD sign-ins, GCP audit logs.
**Correlation Techniques**
- Rule-based: e.g., 5 failed logins (4625) → successful (4624) from same IP = brute force success.
- Temporal: Link events in a time window (e.g., priv esc <10 min after login).
- Cross-source: VPN login foreign country PAM cred checkout unusual outbound traffic = insider threat.
- Behavioural: Compare vs historical baseline (e.g., normal UK login → sudden Russia).
**Detection Engineering **:
SOC analysts write detection logic in query languages. See few examples below:
- Splunk SPL:
```spl
index=wineventlog EventCode=4625 OR 4624
| stats count by Account_Name, src_ip
| where count > 5
```
- Azure Sentinel KQL:
```kql
SecurityEvent
| where EventID in (4624, 4625)
| summarize Count=count() by Account, IPAddress, bin(TimeGenerated, 10m)
| where Count > 5
```
**Challenges**
- FPs: Broad rules create noise.
- Data Norm: Standardise varied log formats.
- Scalability: Efficient indexing for billions of EPS.
- Enrichment: Add TI feeds, geoIP, and asset criticality to logs.
**SOC Analyst Workflow**
1. Alert fires from the SIEM rule.
2. Triage: Check user/device/time/geo context.
3. Deep dive: Pivot to related logs (EP, PAM, FW).
4. Map to MITRE ATT&CK (e.g., T1078 Valid Accounts).
5. Respond: Escalate IR, isolate host, revoke creds.
6. Feedback: Tune the rule for better accuracy.
**Real-World Ex (PAM Integration)**
- CyberArk logs: Privileged credentials checkout at 2 AM.
- SIEM correlates w/ VPN login foreign IP large outbound transfer.
- Investigation → compromised priv acct.
- Containment: Disable acct, revoke vault access, block IP.
#SOC_Analysts
#ThreatHunting
#IncidentResponse
#SecurityAnalysts
#BlueTeam
#DigitalForensics
#CyberSecurity
#NetworkSecurity
#MalwareAnalysis
#SOC