Correlation Rules
Correlation rules link multiple detections together. They fire when two rules match the same entity within a time window—detecting attack patterns that individual rules miss.Why Correlation?
Single rule detection:- ✅ Failed login attempt detected
- ✅ Successful login detected
- ❌ Doesn’t connect them as potential credential stuffing
- ✅ Failed login followed by successful login from same IP
- ✅ Within 5 minutes
- ✅ High confidence attack pattern
How Correlation Works
- Rule A fires - e.g., “Failed Login Attempt”
- CHAD tracks the entity - e.g., source IP
192.168.1.50 - Rule B fires - e.g., “Successful Login”
- Same entity within time window - same source IP, within 5 minutes
- Correlation alert created - links both detections
Creating Correlation Rules
- Navigate to Correlation Rules
- Click Create Correlation Rule
- Configure the rule
- Deploy to activate
Configuration
| Field | Description | Example |
|---|---|---|
| Name | Descriptive title | Failed then Successful Login |
| Rule A | First detection rule | Failed Login Attempt |
| Rule B | Second detection rule | Successful Login |
| Entity Field | Field to correlate on | source.ip |
| Time Window | Maximum time between rules | 5 minutes |
| Severity | Correlation alert severity | High |
Entity Field
The entity field determines what “same” means:| Entity Field | Correlates on |
|---|---|
source.ip | Same source IP |
user.name | Same username |
host.name | Same host |
process.pid | Same process |
Time Window
How long to wait for Rule B after Rule A:| Window | Use Case |
|---|---|
| 1 minute | Rapid attacks (brute force) |
| 5 minutes | Standard correlation |
| 15 minutes | Slower attack chains |
| 1 hour | Long-running attacks |
Example Correlations
Credential Stuffing
Lateral Movement
Data Exfiltration
Privilege Escalation
Correlation State
CHAD tracks correlation state per entity:Managing Correlation Rules
Version Control
Like standard rules, correlation rules have:- Full version history
- Diff view between versions
- One-click rollback
Deploy/Undeploy
Correlation rules must be deployed to be active:- Deployed - Actively correlating
- Undeployed - Saved but inactive
Enable/Disable
Temporarily disable without undeploying:- Rule remains configured
- No new correlations created
Correlation Alerts
When correlation matches:- New alert created with correlation type
- Links to both original alerts (Rule A and B matches)
- Severity from correlation rule (often higher)
- Full context from both matched logs
Investigation
Open a correlation alert to see:- Both matched logs
- Timeline of events
- Entity that connected them
- Time between detections
Bidirectional Correlation
By default, correlation is directional: A then B. For bidirectional (A then B, or B then A):- Create two correlation rules
- Swap Rule A and Rule B
- Or use the bidirectional option if available
Performance Considerations
Correlation adds overhead:- Entity tracking - Memory for pending correlations
- State management - Database writes for state
- Time windows - Longer windows = more state
- Use specific entity fields (not wildcards)
- Keep time windows reasonable
- Monitor correlation state table size
Best Practices
Start simple
Start simple
Begin with obvious correlations (failed → success).
Use specific entities
Use specific entities
source.ip is better than user.name which can be spoofed.Tune time windows
Tune time windows
Start short, extend based on real attack timelines.
Set appropriate severity
Set appropriate severity
Correlations often warrant higher severity than individual rules.
Document the attack chain
Document the attack chain
Add descriptions explaining what the correlation detects.
Troubleshooting
Correlation not firing
- Both rules must be deployed
- Entity field must exist in both logs
- Check time window (Rule B must fire after Rule A within window)
- Verify entity values match exactly
Too many correlations
- Entity field too broad (try more specific)
- Time window too long
- Base rules fire too frequently
State growing large
- Reduce time windows
- Clean up old correlation state
- More specific entity fields