A quantitative cyber risk model integrating MITRE ATT&CK, dependency-aware control strengths, and a hybrid Bayesian network + Monte Carlo attacker simulator.
This repository implements an advanced cyber risk quantification engine that merges:
- FAIR-style frequency × magnitude modeling
- MITRE ATT&CK technique-level behavioral modeling
- Bayesian networks for estimating attacker success and detection probabilities
- Monte Carlo attacker-path simulation incorporating retries, fallbacks, adaptability, and detection
- Control dependency logic (group health, “requires” relationships, influence weighting)
- Technique relevance mapping for attacker capability modeling
The engine is designed to support both interactive analysis and automated integration into larger systems.
.
├── build_mitigation_influence_template.py
├── build_technique_relevance_template.py
├── cyber_incident_pymc.py
├── mitre_control_strength_dashboard.py
├── mitigation_control_strengths.csv
├── technique_relevance.csv
└── README.md
These capabilities come from the original README and remain fully valid:
- Dependency-aware mitigation strength computation
- Group health modeling
- Influence weighting
- Technique relevance extraction
- Tactic-level fallback simulation
- Monte Carlo loss modeling
- Poisson frequency modeling
- Lognormal loss severity modeling
- Flexible CSV-driven configuration
Nothing in the new Bayesian model removes or replaces these features.
A fully dynamic Bayesian network is constructed when technique-level inputs are available.
- λ (lambda) — Annual attack attempt frequency
- Technique success nodes — One per
(tactic, technique)pair - Technique detection nodes — One per technique
- Tactic nodes — Deterministic OR of technique successes
- Chain success node — AND of all relevant tactic nodes
Technique priors derive from effective mitigation strengths with dependency logic, group health, and influence weighting.
Tactics with zero relevant techniques are automatically excluded from the BN chain.
When technique inputs exist, the model uses a hybrid approach:
- Posterior λ
- Posterior technique success probabilities
- Posterior technique detection probabilities
- Technique selection
- Retries
- Adaptability gating
- Detection increments
- Fallback behavior
- Final chain success
- Triggered only under explicit conditions
- Moves attacker backward exactly one tactic
- Technique selection is re-randomized (may repeat previous technique)
Adaptability no longer modifies success probability.
It controls only whether retries are allowed.
If available, detection probability is drawn from technique BN posterior nodes.
Per attempt:
detect_prob += rng.uniform(DETECT_INC_MIN, DETECT_INC_MAX)
If rng.random() < detect_prob, the chain terminates immediately.
Activated whenever technique inputs can be constructed.
Used only when:
- technique relevance file missing
- mitigation dashboard unavailable
- no technique priors can be formed
_simulate_attacker_path(record_path=True) returns:
(success: bool, path_log: List[Dict])
Each log entry includes:
- tactic
- technique
- BN-derived success probability
- BN-derived detection probability
- retry count
- fallback occurrence
- per-step outcome
All dependency logic from the dashboard now influences BN priors:
- Supporting-control influence
- Requires-dependencies
- Group health sampling
- Influence weighting
- Cycle detection
- Defense-in-depth aggregation
- Annual loss distribution
- Annual incident counts
- Posterior λ distribution
- Posterior chain success distribution
- Technique BN posterior dumps
- Attacker path logs (JSON or CSV)
Example command:
python cyber_incident_pymc.py \
--technique-relevance technique_relevance.csv \
--mitigation-strengths mitigation_control_strengths.csvDisable stochastic adaptability:
--no-adapt-stochastic
Disable stochastic impact reduction:
--no-stochastic-impact
Processes all control dependencies and mitigation strengths.
Constructs λ, technique success/detection nodes, tactic aggregators, and chain success.
Technique mode (default)
Tactic mode (fallback only)
Combines BN posterior with Monte Carlo progression simulation.
- Calibrate mitigation ranges regularly
- Use relevance templates to focus on specific actors
- Review dependency and group definitions to ensure realistic modeling
- Validate modeled AAL and SLE against internal data
- Version all CSV inputs to preserve analytic lineage
FAIR–MITRE ATT&CK Quantitative Cyber Risk Framework
Copyright 2025 Joshua M. Connors
Licensed under the Apache License, Version 2.0.
This software incorporates public data from the MITRE ATT&CK® framework.