π‘οΈ HIERARKI THREAT MODELING β Dari Intuisi Developer (Level 0) sampai Formal Verification (Level 5)
Threat modeling adalah proses sistematis untuk menjawab βApa yang terburuk yang bisa terjadi?β sebelum kode ditulis. Bukan mendokumentasikan ancaman untuk kepentingan audit β tapi untuk mengubah keputusan desain sebelum terlambat. Hirarki ini memetakan evolusi kedalaman analisis: dari sekadar STRIDE checklist, sampai formal verification yang membuktikan properti keamanan secara matematis. Untuk metodologi lengkap + praktik, lihat threat-modeling-deepdive.
Cara Baca
Level 0 = intuisi (murah, subjektif). Level 5 = formal proof (mahal, presisi). Semakin tinggi level, semakin pasti jawabannya β tapi semakin mahal. Organisasi yang baik memilih level yang sepadan dengan criticality sistem.
Tabel Utama β Level 0 sampai Level 5
| π‘οΈ Level | π§ Pendekatan | β‘ Metodologi | β οΈ Tembok Kematian | π― Kapan Digunakan |
|---|---|---|---|---|
| Level 0 β Intuisi Developer | βApa yang berbahaya?β tanpa framework formal. Brainstorm berdasar pengalaman | Semua orang bisa β hanya butuh knowledge domain + pengalaman security | Bias konfirmasi: lo hanya lihat ancaman yang sudah lo kenal. Tidak sistematis, banyak blind spot | Side project, MVP, personal app tanpa data sensitif |
| Level 1 β STRIDE Checklist | Microsoft STRIDE: Spoofing, Tampering, Repudiation, Information Disclosure, Denial of Service, Elevation of Privilege | Cocok STRIDE tiap elemen DFD. Sederhana, mudah diingat, dokumentasi rapi | Tidak bisa capture business logic flaw. Tidak bisa prioritasi risiko. Satu model cocok untuk semua (tidak spesifik industri) | Startup, mid-size company, secure SDLC awal |
| Level 2 β Attack Tree | Pohon AND/OR: dari goal attacker β sub-actions leaf. Setiap leaf punya cost/skill indicator | Visual intuitif. Komunikasi dengan non-teknis. Bisa kuantifikasi effort attacker | Pohon membesar eksponensial untuk sistem kompleks. Tidak handle multiple attackers parallel | Bug bounty scoping, threat intel brief, komunikasi manajemen |
| Level 3 β PASTA (7-Stage) | Process for Attack Simulation and Threat Analysis: 1. Business objective 2. Technical scope 3. App decomposition 4. Threat analysis 5. Vuln analysis 6. Attack simulation 7. Risk & impact | Risk-based + business-driven. Output: risk register, prioritized mitigations | Heavy process (butuh ~2 hariβ1 minggu per sistem). Butuh threat modeling specialist | Sistem kritis (finansial, healthcare), regulated industry, enterprise risk management |
| Level 4 β Continuous Threat Modeling | Integrasi TM di CI/CD: OWASP Threat Dragon β update otomatis di pipeline. Security champion review tiap sprint | Threat model tidak dokumen statis β hidup berubah bersama kode. OWASP Threat Dragon: open-source TM tool | Butuh budaya security champion. CI/CD integration tooling masih berkembang. False positive noise tinggi | DevOps mature, platform engineering, unicorn/enterprise |
| β οΈ Level 5 β Formal Verification | ProVerif, Tamarin, Alloy, TLA+, formal proof of security properties | Mathematical proof bahwa properti keamanan berlaku untuk semua state. Tidak ada false positive β hitam-putih | Waktu: formal verification satu protokol kripto butuh bulanβtahun. Butuh PhD-level knowledge. Skalabilitas rendah | Protokol kripto, secure boot chain, hardware security module, military grade system |
Peta Visual β Effort vs Certainty
Certainty β
L5 β Formal Proof β
L4 β Continuous TM βββ
L3 β PASTA 7-Stage ββββ
L2 β Attack Tree βββββ
L1 β STRIDE Checklist βββββ
L0 β Intuition ββββββ
ββββββββββββββββββββββββββ Effort
Level 0β1 Cukup untuk 80% Kasus
Jangan over-invest di threat modeling. Untuk aplikasi CRUD internal tanpa data sensitif β STRIDE checklist (L1) + attack tree untuk fitur kritis (L2) sudah cukup. Level 3+ untuk sistem yang jika breach = kebangkrutan atau kematian. (Pikirkan: medical device, flight control, core banking.)
Kenapa Hirarki Ini Penting
1. Threat Modeling Bukan Sekali β Harus Iteratif
Setiap perubahan arsitektur β update threat model. API baru β tambah STRIDE per endpoint. Dependencies baru β attack tree baru untuk supply chain.
Threat model yang tidak pernah diupdate adalah dokumen yang menua tanpa guna. Level 4 (continuous TM) mengatasi ini dengan integrasi otomatis di pipeline.
2. Output Threat Model = Input untuk Security Testing
| Level Threat Model | Output β Untuk |
|---|---|
| L0βL1 (STRIDE) | Checklist security requirement β SAST rules |
| L2 (Attack Tree) | Attack path β prioritasi penetration test |
| L3 (PASTA) | Risk register β control allocation |
| L4 (Continuous) | Auto-generated test case β DAST/IAST |
| L5 (Formal) | Proof of security β certification (CC EAL7, FIPS) |
3. Dual-Use: Red Team Juga Threat Model β Tapi Untuk Goal Berbeda
Defender: βBagaimana attacker bisa masuk?β Red teamer/attacker: βApa kontrol defender yang paling lemah?β
Kedua threat model menggunakan hirarki dan metodologi yang sama β hanya perspektif yang berbeda.
Plot Twists
Plot Twist 1: STRIDE Tidak Handle Business Logic
STRIDE excellent untuk ancaman teknis. Tapi business logic flaw (lo bisa transfer uang tanpa otorisasi karena race condition) bukan milik kategori STRIDE manapun. Complement STRIDE dengan misuse case atau process flow analysis untuk tangkap ancaman business logic.
Plot Twist 2: Attack Tree (L2) Paling Efektif Untuk Komunikasi Dengan Bos Non-Teknis Attack tree: visual, intuitif, langsung lihat "kalau attacker mau capai X, harus lewat jalur Y." Untuk presentasi ke CTO/CEO β attack tree mengalahkan STRIDE table mana pun. Tambahkan cost indikator ($$$ per node) untuk justifikasi budget security.
Plot Twist 3: Formal Verification (L5) Digunakan NSA, Bukan Startup ProVerif dan Tamarin dipakai untuk verifikasi protokol kripto TLS 1.3, Signal Protocol, WireGuard. Butuh waktu bulanβtahun untuk satu protokol. Untuk aplikasi web biasa, Level 5 adalah overshoot. Tapi untuk secure boot chain, HSM firmware, dan protokol kripto baru β L5 adalah satu-satunya cara untuk "pasti."
Plot Twist 4: AI-Assisted Threat Modeling Sedang Muncul (2025+)
LLM-based TM tools mulai muncul: generate STRIDE dari arsitektur diagram, expand attack tree dari deskripsi, saran mitigasi dari CVE database. Tapi belum bisa gantikan human reasoning β untuk ancaman yang membutuhkan konteks bisnis spesifik atau zero-day technique, AI masih hallucinate. Level 4 (continuous TM) akan sangat terbantu AI untuk automasi rutin.
Sumber & Telusur Lebih Lanjut
- Deep Dive Threat Modeling β threat-modeling-deepdive (STRIDE, PASTA, Attack Tree lengkap)
- Security Requirements dari Threat Model β comprehensive-threat-directory (taksonomi ancaman)
- Endpoint Security (STRIDE per device) β endpoint-detection-playbook
- Network Threat Model (STRIDE per OSI) β hierarchy-network-security
- Formal Verification β quantum-cryptography-deepdive (formal proof in crypto context)
- Master Index β master-index
Threat modeling bukan tentang βberapa banyak ancaman yang lo temukan.β Ini tentang seberapa yakin lo bahwa lo sudah menemukan ancaman yang paling berbahaya. Pilih level yang membangun keyakinan itu β tanpa menghabiskan budget untuk ancaman yang tidak relevan.
Threat Modeling Hierarchy | Level 0 (Intuition) β Level 5 (Formal Verification) Β· Seberapa Yakin Kamu?