ARES - authorized red-team engagement automation with dashboard, campaign scope, module orchestration, OPSEC controls, encrypted vault, and reporting.
Python active-directorycloud-securitydefensive-validationfastapigood-first-issuemitre-attackopsecreactred-teamreportingsecurity
docs: finalize Fase 4 complete status in AUDIT_PROGRESS and MASTER_FIX_PLAN
Mafifrizid1782d123e47
diff --git a/AUDIT_PROGRESS.md b/AUDIT_PROGRESS.mdindex 445b744..bdc0c0a 100644--- a/AUDIT_PROGRESS.md+++ b/AUDIT_PROGRESS.md@@ -25,7 +25,7 @@ Tracking file for verified findings, reproduction tests, applied fixes, test sui| MOD-015 | lateral.smb_relay omission scope check on primary loop | FIXED | PASSED (10/10 scope tests) | `ares/modules/lateral/smb_relay.py`, `tests/unit/test_scope_enforcement_grup_d.py` | Penegakan scope check `is_in_scope` dan `before_request(t, "smb")` sebelum SMB negotiate (commit `cc2e980`). || MOD-016 | ad.sccm cleartext credential evaporation & DPAPI misleading | TERBUKTI (HIGH) | Audit verified (`sccm.py:300, 521`) | Menunggu remedi | NAA DPAPI encrypted blob dilaporkan sebagai `cleartext_credentials`, tidak ada normalizer handler, dan tidak disimpan ke vault. || MOD-017 | network.pivot scope bypass on remote_host & subnets | FIXED | PASSED (10/10 scope tests) | `ares/modules/network/pivot.py`, `tests/unit/test_scope_enforcement_grup_d.py` | Validasi `reachable_subnets` terhadap `campaign.is_in_scope()` sebelum konfigurasi SOCKS5 tunnel (commit `cc2e980`). |-| MOD-018 | network.pivot teardown omission on background SSH processes | TERBUKTI (HIGH) | Audit verified (`pivot.py:343-359`) | Menunggu konfirmasi arsitektur | `PivotModule.teardown()` tidak pernah dipanggil di engine lifecycle, tidak ada mekanisme teardown lifecycle modul di engine. STOP menunggu konfirmasi (Rule 4). |+| MOD-018 | network.pivot teardown omission on background SSH processes | FIXED | PASSED (5/5 teardown tests) | `ares/core/engine.py`, `ares/modules/network/pivot.py`, `ares/pivot/infrastructure.py`, `tests/unit/modules/test_pivot_teardown.py` | Teardown SSH subprocess dan koneksi pivot dijamin via blok `finally` di `AresEngine.run_plan()` (Opsi B), fallback force kill pada process hang, dan exception-safe cleanup (commit `facdb61`). || MOD-019 | network.pivot fictitious implementation & phantom active status | TERBUKTI (HIGH) | Audit verified (`infrastructure.py:260-265, 368-370`) | Menunggu remedi | Jika backend asyncssh/ssh tidak ada, tunnel ditandai ACTIVE dan finding palsu diterbitkan (melanggar Rule 1). || MOD-020 | lateral.ssh_pivot fictitious SOCKS5 proxy implementation | TERBUKTI (HIGH) | Audit verified (`modules.py:1332-1356`) | Menunggu remedi | `establish_socks5` mengembalikan dict proxy padahal `move()` mengabaikan port dan menutup koneksi (melanggar Rule 1). || MOD-021 | lateral.rdp false-positive execution claim on open port | TERBUKTI (CRITICAL) | Audit verified (`modules.py:1448-1517`) | Menunggu remedi | Port 3389 terbuka memicu status success dan finding CRITICAL lateral movement berhasil tanpa otentikasi (melanggar Rule 1). |@@ -67,7 +67,7 @@ Tracking file for verified findings, reproduction tests, applied fixes, test sui| MOD-057 | ad.enum_acl & ad.laps_enum inconsistent LDAP bind authentication formatting (bypassing build_ad_bind_plan) | DEFERRED | Audit verified (`enum_acl.py:234`, `laps_enum.py:297`) | Menunggu remedi (Batch Fix Serentak) | Migrasi raw string binding ke `build_ad_bind_plan()` ditunda ke batch fix serentak. || MOD-058 | network.dns_enum out-of-scope AXFR zone transfer probing on discovered nameservers | FIXED | PASSED (10/10 scope tests) | `ares/modules/network/dns_enum.py`, `tests/unit/test_scope_enforcement_grup_d.py` | Filter nameserver out-of-scope dan penegakan `before_request(ns_clean, "dns")` sebelum AXFR (commit `cc2e980`). || MOD-059 | network.http_fingerprint unbounded HTTP redirect traversal on external hosts via follow_redirects=True | FIXED | PASSED (10/10 scope tests) | `ares/modules/network/http_fingerprint.py`, `tests/unit/test_scope_enforcement_grup_d.py` | `follow_redirects=False` + validasi `campaign.is_in_scope(redirect_host)` sebelum request berikutnya (commit `cc2e980`). |-| MOD-060 | network.service_detect asyncio TCP writer handle leak on read timeout in _grab_banner | DEFERRED | Audit verified (`service_detect.py:108-129`) | Menunggu remedi (Batch Fix Serentak - Grup C) | `reader.read()` tidak dibungkus `try ... finally: writer.close()`, memicu socket leak saat timeout. |+| MOD-060 | network.service_detect asyncio TCP writer handle leak on read timeout in _grab_banner | FIXED | PASSED (2/2 teardown tests) | `ares/modules/network/service_detect.py`, `tests/unit/modules/test_service_detect_teardown.py` | Pembungkusan reader.read() dalam blok `try ... finally: writer.close()` dan `await writer.wait_closed()` (commit `64e3be5`). || MOD-061 | network.snmp_enum discovered SNMP community strings evaporation from vault & standard pipeline | FIXED | PASSED (Unit tests & vault integration) | `ares/modules/network/snmp_enum.py` | Direct vault writing added for valid community strings (CredentialType.CLEARTEXT, Gate 6 compliant), valid_credentials standardized to list[dict], raw snmp_findings serialized to dicts (commit `5635362`). || MOD-062 | network.* & recon.fingerprint 100% unhandled reconnaissance capabilities in ArtifactNormalizer | FIXED | PASSED (42/42 pipeline tests) | `ares/normalize/artifacts.py`, `tests/unit/test_artifact_normalizer_pipeline.py` | Seluruh 9 handler recon telah diimplementasikan penuh di `ArtifactNormalizer` Grup A (commit `9f8b111`). || MOD-063 | cloud.* unscoped cloud account/tenant execution via ambient credentials | DEFERRED | Audit verified (`aws.py:190`, `azure.py:211`, `azure_ad.py:231`, `gcp.py:134`) | Menunggu remedi (Batch Fix Serentak - Grup D) | Target cloud account/subscription/project ID tidak divalidasi terhadap scope campaign. Ambient credentials dapat mengeksekusi di luar otorisasi. |@@ -234,8 +234,8 @@ Tracking file for verified findings, reproduction tests, applied fixes, test sui### [MOD-060] Asyncio TCP Writer Handle Leak on Read Timeout in `_grab_banner` on `network.service_detect`- **Severity**: **MEDIUM**-- **Status**: **DEFERRED (Masuk batch fix serentak - Grup C: Teardown & Resource Cleanup)**-- **Catatan**: Pemanggilan `await asyncio.wait_for(reader.read(2048), timeout=timeout)` tidak dibungkus dalam blok `try ... finally: writer.close()`. Perlu try/finally untuk mencegah kebocoran file descriptor socket TCP.+- **Status**: **FIXED** (commit `64e3be5` - Fase 4)+- **Catatan**: Pemanggilan `await asyncio.wait_for(reader.read(2048), timeout=timeout)` telah dibungkus dalam blok `try ... finally: writer.close()` dan `await writer.wait_closed()` untuk menjamin pelepasan file descriptor socket TCP.### [MOD-061] Discovered SNMP Community Strings Evaporation from Vault & Standard Pipeline on `network.snmp_enum`- **Severity**: **HIGH**diff --git a/MASTER_FIX_PLAN.md b/MASTER_FIX_PLAN.mdindex 84deda4..d47746e 100644--- a/MASTER_FIX_PLAN.md+++ b/MASTER_FIX_PLAN.md@@ -13,19 +13,19 @@| Metrik Audit | Jumlah | Keterangan ||---|:---:|---|| **Total Temuan Teridentifikasi** | **74** | MOD-001 s/d MOD-074 (Batch 1 s/d Batch 12) |-| **Sudah Diperbaiki (FIXED)** | **49** | Code fixes + regression tests lulus di main branch (termasuk Fase 1, Fase 2, Fase 3, dan 6 temuan Fase 4) |+| **Sudah Diperbaiki (FIXED)** | **50** | Code fixes + regression tests lulus di main branch (termasuk Fase 1, Fase 2, Fase 3, dan Fase 4 COMPLETE - 7/7) || **Mitigasi / Dinonaktifkan (DISABLED)** | **4** | `ad.ghost_forge`, `windows.dpapi`, `windows.token_impersonation`, `cloud.phantom_token` |-| **Masih Open (DEFERRED)** | **21** | MOD-018 (menunggu konfirmasi engine), sisa Grup E, F |+| **Masih Open (DEFERRED)** | **20** | Sisa Grup E (Technical Honesty) & Grup F (Cloud Scope) |### Ringkasan Status per Kelompok```Total Temuan: 74-├── FIXED (49) [66.2%] ═════════════════════════════════════════+├── FIXED (50) [67.6%] ══════════════════════════════════════════├── DISABLED (4) [ 5.4%] ═══-└── DEFERRED (21) [28.4%] ══════════════════+└── DEFERRED (20) [27.0%] ═════════════════├── Grup A: Normalizer Handlers Missing (✅ SELESAI - commit 9f8b111)├── Grup B: Hash Masking di Finding.evidence (✅ SELESAI - commit e94533b)- ├── Grup C: Teardown & Resource Cleanup (⚠️ PARTIAL 6/7 FIXED - MOD-018 pending konfirmasi arsitektur)+ ├── Grup C: Teardown & Resource Cleanup (✅ SELESAI - 7/7 FIXED - commit facdb61)├── Grup D: Scope Bypass Listener / Destination Parameter (✅ SELESAI - commit cc2e980)├── Grup E: Fake/Stub Implementation & Pipeline Disconnect (15 temuan open, 3 fixed)└── Grup F: Architectural Decisions Needed (5 temuan / gates)@@ -363,9 +363,9 @@ Untuk meminimalkan waktu regresi dan memaksimalkan stabilitas, eksekusi remedi s│┌───────────────────────────────────▼────────────────────────────────────┐│ FASE 4: Grup C — Guaranteed Teardown (Rule 4 Compliance) │-│ [STATUS: ⚠️ PARTIAL (6/7 FIXED) - commit 28e983a] │-│ - 6 modul persistence/lateral dilengkapi teardown & failure tests. │-│ - MOD-018 STOP menunggu konfirmasi mekanisme lifecycle engine. │+│ [STATUS: ✅ COMPLETED (7/7 FIXED) - commit facdb61] │+│ - 7 modul persistence/lateral dilengkapi teardown & failure tests. │+│ - MOD-018: pivot subprocess teardown via engine finally (Opsi B). │└───────────────────────────────────┬────────────────────────────────────┘│┌───────────────────────────────────▼────────────────────────────────────┐