📊 מדדי אבטחה: מדידת מה שבאמת חשוב
"מה שנמדד מנוהל. מה שלא נמדד נפרץ." — Hagbard Celine
"אם אינכם יכולים למדוד את זה, אינכם יכולים להוכיח שזה עובד. אם אתם מודדים את הדבר הלא נכון, אינכם מוכיחים כלום. אם אתם רק מודדים מה שגורם לכם להיראות טוב, אתם מוכיחים שאתם משקרים לעצמכם."
🍎 התפוח הזהוב: מדדי יוהרה מול אבטחה אמיתית (או: איך לשקר בסטטיסטיקה תוך הרגשה מאובטחת)
צוותי אבטחה אוהבים מדדים. לוחות מחוונים מלאי מספרים. תרשימים צבעוניים. תדריכים מנהלים עם קווים העולים כלפי מעלה. זה תיאטרון אבטחה עם ערכי ייצור טובים יותר.
רוב מדדי האבטחה מודדים את הדברים הלא נכונים. FNORD. האם אתם מודדים אבטחה או מודדים את המראה של מדידת אבטחה? (שואל בשביל חבר. החבר הוא פרנויה.)
מספר המדיניות שנכתבה? לא רלוונטי אם לא נאכף (PDF לא עוצר האקרים). אחוז השלמת הדרכת אבטחה? חסר תועלת אם עובדים עדיין לוחצים על קישורי דיוג (ציות ≠ הבנה). מספר סריקות פגיעות? חסר משמעות ללא מהירות פריסת תיקונים (סריקת פגיעות שמעולם לא תוקנו זה כמו לאבחן סרטן ולחגוג את האבחנה). תעשיית האבטחה-תעשייתית מוכרת כלים המייצרים מדדים המוכיחים שקניתם כלים. הנמקה מעגלית היא מעגלית.
מדדו תוצאות, לא פעילויות. מדדו הפחתת סיכון, לא מאמץ שהושקע. או המשיכו למדוד קלטים ותתפלאו למה הפלטים עדיין גרועים. הבחירה שלכם. שום דבר לא נכון.
🛡️ חמש הקטגוריות של מדדי אבטחה שחשובים
1. זיהוי ותגובה
כמה מהר אתם מזהים ועוצרים התקפות?
MTTD: זמן ממוצע לזיהוי (שעות/ימים). MTTR: זמן ממוצע לתגובה (שעות). MTTR: זמן ממוצע להתאוששות (שעות).
2. ניהול פגיעויות
כמה מהר אתם מתקנים סיכונים קריטיים?
זמן לתיקון CVE קריטיים: ימים מהגילוי לפריסה. פגיעויות גבוה/קריטי פתוחות: ספירה מוחלטת, עם מגמת ירידה.
3. מגמות אירועים
האם אתם משתפרים או מחמירים?
אירועים לחודש: מגמת ירידה? חלוקת חומרה: יותר קריטיים או יותר אינפורמטיביים? אירועים חוזרים: לומדים מכשלונות?
4. בקרת גישה
למי יש גישה למה?
חשבונות עם הרשאות מוגזמות: ספירה, תדירות סקירה. חשבונות לא בשימוש: אישורים רדומים הם סיכון. כיסוי MFA: אחוז מערכות קריטיות.
5. מודעות אבטחה
האם משתמשים נופלים להתקפות?
שיעור קליקים בסימולצ יית דיוג: אחוז לוחצים על קישורים זדוניים. אימיילים חשודים שדווחו: מדד ערנות משתמשים. הפרות מדיניות: אירועים מטעויות משתמשים.
⏰ Leading vs. Lagging Indicators: The Paradox of Time
Lagging indicators tell you what happened. They're forensic evidence of your security posture—the crime scene photos of yesterday's decisions. Useful for autopsies. Not so useful for preventing the murder.
Leading indicators predict what will happen. They're the smoke before the fire, the tremor before the earthquake, the FNORD you almost didn't notice. They're uncomfortable because they reveal problems before they become disasters—and who wants to admit their house is on fire while there's still time to grab the extinguisher?
🔴 Lagging Indicators (Autopsy)
- Number of incidents: Counting corpses
- Breach impact: Calculating damage
- Time to remediate: How long you bled
- Compliance audit findings: Report card from last semester
- Security budget spent: How much you invested in yesterday
Looking backward feels safe. The disaster already happened. Nothing left to prevent.
🟢 Leading Indicators (Prevention)
- Vulnerability age distribution: How long known risks sit unpatched
- Patch deployment velocity: Speed from disclosure to protection
- Phishing simulation trends: User vigilance improving or declining?
- Security awareness engagement: Are people learning or clicking through?
- Access review completion rate: Proactive privilege hygiene
- Unpatched critical systems: Ticking time bombs still armed
Looking forward creates anxiety. The disaster hasn't happened yet. You could still prevent it. That means responsibility.
🤖 Automation: Measuring Without Theater
Manual security metrics are security theater with spreadsheets. If a human has to manually collect the metric, the metric lies. Not because humans are dishonest (though some are), but because manual collection introduces:
- Selection bias: "I'll just check the systems that usually pass..."
- Temporal drift: Metrics from last Tuesday pretending to represent today
- Sampling errors: "I checked 10 of 1000 servers, close enough!"
- Political optimization: "Let's wait until after that patch deploys to run the report..."
- Effort resistance: "This takes 4 hours, we'll do it quarterly instead of weekly"
Automated metrics don't lie. They just reveal truths you'd rather not see.
🛠️ Automation Stack Examples
- GitHub Advanced Security: Continuous code scanning, secret detection, dependency alerts
- AWS Config Rules: Real-time infrastructure compliance monitoring
- OpenSSF Scorecard: Weekly supply chain security assessment
- SonarCloud Quality Gates: Every commit quality and security validation
- FOSSA License Scanning: Continuous SBOM generation and license compliance
- GuardDuty: Automated threat detection without human intervention
📊 Continuous Measurement Patterns
- Every commit: SAST, secret scanning, dependency checks
- Every deploy: Container vulnerability scanning, SBOM generation
- Every hour: Infrastructure configuration compliance
- Every day: Vulnerability age trending, patch status
- Every week: OpenSSF Scorecard, access reviews, security posture
תחשוב בעצמך: If your security metric requires a human to manually collect it, ask why it's not automated. The answer usually reveals whether you're measuring security or measuring the appearance of measuring security. FNORD.
📊 Visualization: Dashboards That Tell Truth vs. Dashboards That Lie
Green dashboards are the opiate of security executives. "Everything's green! We're secure!" Translation: "I carefully selected metrics that make me look good."
Good security dashboards make you uncomfortable. They highlight problems. They trend risks. They show age distributions of unpatched vulnerabilities. They don't show "100% compliant" unless you're actually 100% compliant (you're not).
🎭 Dashboard Theater
- All green tiles: "Everything's fine!" (Narrator: It wasn't.)
- Percentage completions: "99% patched!" (1% = entire DMZ)
- Trend lines pointing up: "Improving!" (More scans ≠ more security)
- Compliance percentages: "97% compliant!" (3% = all authentication)
- Activity metrics: "Blocked 10M threats!" (9.999M = spam)
"Look at all these green numbers! We must be secure. Right? Right??"
✅ Truth Dashboards
- Red/Yellow/Green with context: "23 critical vulns, 19 >30 days old"
- Age distributions: Histograms showing how long risks persist
- Trend arrows (both directions): "MTTR improving, but MTTD worsening"
- Absolute counts: "4 unpatched critical systems in production"
- Ratio metrics: "800% net resolution rate (closed vs opened)"
Uncomfortable truths drive action. Comfortable lies drive breaches.
📋 Hack23's Security Metrics Dashboard
Our metrics program focuses on risk reduction: ISMS-PUBLIC Repository | Security Metrics
- OpenSSF Scorecard Target: ≥7.0/10 — Supply chain security assessment across all repos (CIA: 7.2, Black Trigram, CIA CM)
- SLSA Level 3 Build Provenance — Cryptographically signed attestations for all releases (non-falsifiable provenance)
- CII Best Practices: Passing+ — Open source maturity badges (CIA, Black Trigram, CIA CM all passing)
- SonarCloud Quality Gates: Passed — Zero high/critical vulnerabilities, <3% duplication, ≥80% coverage target
- Vulnerability SLAs — Critical CVEs: 7 days, High: 30 days, Medium: 90 days (live tracking in GitHub Security)
- FOSSA License Compliance — Automated SBOM generation, continuous dependency license monitoring
- GitHub Advanced Security — Secret scanning, Dependabot alerts, CodeQL SAST on every commit
- AWS Security Services — GuardDuty threat detection, Security Hub findings, Config compliance, Inspector vulnerabilities
🔍 GitHub Security Metrics: Real-Time Transparency
Hack23 practices radical transparency through live public security metrics. Our GitHub Security Organization Overview exposes actual vulnerability management performance:
- Current MTTR: 8 days (target: <7 days) — Honest about where we stand
- Alert Resolution Rate: 800% net positive (closed vs opened) — Aggressive remediation
- Secret Detection: 0 secrets bypassed (100% blocked) — Zero tolerance enforcement
- Alert Age: 29 days average (needs improvement) — Acknowledging gaps drives fixes
- Total Closed Alerts: 228 across all repositories — Historical remediation proof
- Autofix Adoption: 0 (opportunity for automation improvement) — Transparency includes weaknesses
This is what real security metrics look like. Not all green. Not perfect. Not hiding problems. Measuring actual security posture with automated tooling that can't be gamed.
🔍 The Five Principles of Effective Security Metrics
- Measure Outcomes, Not Activities - "Vulnerabilities fixed" > "vulnerability scans run"
- Focus on Trends, Not Snapshots - Direction matters more than absolute numbers
- Make Metrics Actionable - Every metric should drive specific decisions
- Avoid Perverse Incentives - Don't measure what can be gamed without improving security
- Report Honestly - Metrics revealing problems are valuable—hiding problems is deadly
🎯 סיכום: מדדו מה שחשוב, הטילו ספק בהכל
מדדי אבטחה הם צפיות למודעות ההגנתית שלכם. כמו מדיטציה החושפת דפוסי מחשבה, מדדים חושפים דפוסי אבטחה. האם אתם הופכים מאובטחים יותר עם הזמן? איפה אתם החלשים ביותר? מה כדאי לתקן הבא? מדדים טובים עונים על שאלות אלה. מדדים גרועים נמנעים מהן.
חמש קטגוריות המדדים (חוק החמישיות מתעורר באופן טבעי): זיהוי ותגובה, ניהול פגיעויות, מגמות אירועים, בקרת גישה, מודעות אבטחה. כל אחת מודדת ממדים שונים של מציאות אבטחה. ביחד יוצרות תמונה שלמה - אם נמדד בכנות.
MTTD ו-MTTR מראים יכולת זיהוי. מהירות תיקון מראה ניהול פגיעויות. מגמות אירועים מראות יעילות למידה. שיעורי דיוג מראים השפעת מודעות. אבל רק אם אתם כנים לגבי המספרים.
רוב מדדי האבטחה הם תיאטרון יוהרה. לוחות מחוונים המראים רק אורות ירוקים. "מספר אימיילי דיוג שנחסמו" (מודדים את מסנן הדוא"ל שלכם, לא את האבטחה שלכם). "אחוז השלמת הדרכה" (מודדים ציות, לא הבנה). "סריקות פגיעות שבוצעו" (מודדים פעילות, לא תוצאות).
מדדי יוהרה מליטפים אגו. מדדים אמיתיים מניעים שיפור. בחרו אי-נוחות על פני אשליה.
Metrics measure security. But metrics also CREATE security culture—or destroy it. Measure vulnerabilities found? Teams stop looking (bad news punished). Measure vulnerabilities fixed? Teams hunt obsessively (problems rewarded). Measure false positive rates? Analysts tune alerts carefully. Ignore false positives? Alert fatigue kills detection.
You become what you measure. Choose metrics that reward the behavior you want:
- Measure time to remediation → Teams fix faster
- Measure phishing simulation trends → Users learn vigilance
- Measure repeat incidents → Organizations learn from failures
- Measure coverage gaps → Teams close blind spots
- Measure false positive rates → Analysts tune quality over quantity
But remember Goodhart's Law: "When a measure becomes a target, it ceases to be a good measure." Metrics optimized become gamed. Question every metric—especially when it makes you look good. The metric that feels comfortable is probably lying to you.
Are you paranoid enough about your metrics lying to you? If your dashboard shows only green, you're either: (a) perfectly secure (you're not), or (b) measuring the wrong things. FNORD.
תחשוב בעצמך, schmuck! Question your security metrics. Especially when they tell you what you want to hear. Security theater performs measurement. Real security measures reality.