New to Claude Skills? Learn how to install them →

mukul975 on GitHub

Continuous Security Validation

Free

Automate ongoing security control validation with BAS.

Get this skill

Free · Opens the source repo

What Continuous Security Validation does

Implementing Continuous Security Validation with BAS provides a robust framework for organizations looking to enhance their cybersecurity posture through automated, continuous testing. This skill leverages Breach and Attack Simulation (BAS) platforms such as SafeBreach, AttackIQ, Picus, and others to simulate real-world attack scenarios based on the MITRE ATT&CK framework. Unlike traditional penetration testing, which is often a one-off exercise, BAS allows for ongoing validation of security controls by continuously emulating potential threats across the entire IT environment.

The skill is particularly useful for security teams that need to ensure their defenses are effective against evolving threats. By deploying BAS agents across various segments of the network, organizations can test the effectiveness of their endpoint protection, network security, email gateways, and incident response capabilities without the risks associated with live exploitation. This approach not only identifies control gaps but also provides actionable insights for improving security measures.

With prerequisites including familiarity with the MITRE ATT&CK framework and a deployed security infrastructure, this skill is aimed at security professionals involved in compliance, security architecture, and ongoing security assessments. It emphasizes the importance of continuous validation over point-in-time assessments, enabling organizations to proactively address vulnerabilities before they can be exploited by attackers.

By implementing this skill, teams can automate the validation of their security controls, ensuring they remain resilient against sophisticated threats while maintaining compliance with industry standards and regulations.

When to use it

Use this skill when you need to implement or enhance continuous security validation in your environment, particularly when compliance and security architecture are priorities.

When not to use it

This skill may not be suitable for environments without the necessary BAS platform licenses or where security controls are not yet deployed.

What you can build with it

Continuous Compliance Testing

Use this skill to automate compliance testing by continuously validating your security controls against industry standards.

Proactive Threat Simulation

Implement this skill to proactively simulate attacks and identify vulnerabilities before they can be exploited.

Security Architecture Improvement

Leverage this skill to assess and improve your security architecture by identifying control gaps through ongoing validation.

How to install Continuous Security Validation

View source

1. Install with the skills CLI

npx skills add mukul975/anthropic-cybersecurity-skills/implementing-continuous-security-validation-with-bas --agent claude-code

2. Or install it manually

Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.

Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs

Inside SKILL.md

Written by mukul975

Implementing Continuous Security Validation with BAS

Overview

Breach and Attack Simulation (BAS) is an automated, continuous approach to validating security control effectiveness by safely executing real-world attack techniques against production security infrastructure. Unlike traditional penetration testing (point-in-time), BAS platforms continuously simulate threats mapped to MITRE ATT&CK, testing endpoint protection, network security, email gateways, SIEM detection, and incident response capabilities. Leading platforms include SafeBreach, AttackIQ, Picus Security (2024 Gartner Customers' Choice), Cymulate, Pentera, and SCYTHE. BAS 2.0 solutions safely emulate real attacker behavior across the entire IT environment without requiring pre-deployed agents on every endpoint.

When to Use

  • When deploying or configuring implementing continuous security validation with bas capabilities in your environment
  • When establishing security controls aligned to compliance requirements
  • When building or improving security architecture for this domain
  • When conducting security assessments that require this implementation

Prerequisites

  • BAS platform license (SafeBreach, AttackIQ, Picus, Cymulate, or Pentera)
  • Deployed security controls to validate (EDR, NGFW, email gateway, SIEM, WAF)
  • MITRE ATT&CK framework familiarity
  • Network segments accessible by BAS agents/simulators
  • Security operations team to act on validation results
  • Change management approval for running simulations in production

Core Concepts

BAS vs Traditional Security Testing

AspectBASPenetration TestingRed Team
FrequencyContinuous/scheduledAnnual/quarterlyAnnual
AutomationFully automatedManual with toolsManual
ScopeFull kill chainSpecific targetsGoal-oriented
SafetySafe simulation, no exploitationControlled exploitationReal exploitation
CoverageThousands of techniquesHundreds of testsFocused scenarios
OutputControl gap analysisVulnerability reportNarrative report
Cost modelSubscriptionPer engagementPer engagement

MITRE ATT&CK Coverage Mapping

TacticExample BAS SimulationsControls Tested
Initial AccessPhishing payload delivery, exploit public appsEmail gateway, WAF, IPS
ExecutionPowerShell, WMI, malicious macrosEDR, application control
PersistenceRegistry run keys, scheduled tasks, servicesEDR, SIEM detection rules
Privilege EscalationToken manipulation, UAC bypassEDR, PAM, SIEM
Defense EvasionProcess injection, obfuscation, timestompingEDR, behavioral analytics
Credential AccessMimikatz, Kerberoasting, LSASS dumpEDR, credential guard
DiscoveryAD enumeration, network scanningSIEM, NDR
Lateral MovementPsExec, WMI, RDP, SMBNDR, microsegmentation
CollectionScreen capture, keylogging, email collectionDLP, UEBA
ExfiltrationHTTP/DNS exfil, cloud storage uploadDLP, CASB, proxy
Command & ControlC2 beaconing, DNS tunneling, encrypted channelsNGFW, proxy, NDR

Security Control Validation Score

Control Effectiveness = (Attacks Prevented + Attacks Detected) / Total Attacks Simulated * 100

Example:
  Total simulations:  500
  Prevented (blocked): 350
  Detected (alerted):  100
  Missed (no action):   50

  Prevention Rate: 350/500 = 70%
  Detection Rate:  100/500 = 20%
  Overall Score:   450/500 = 90%
  Gap Rate:         50/500 = 10%

Workflow

Step 1: Deploy BAS Platform Components

Architecture:
  Management Console (Cloud SaaS):
    - Central orchestration and reporting
    - Attack scenario library management
    - MITRE ATT&CK mapping dashboard

  Simulation Agents:
    - Attacker Agent: Simulates threat actor behavior
    - Target Agent: Receives simulated attacks
    - Network Agent: Tests network-level controls

  Deploy agents across zones:
    - Corporate network (workstations)
    - DMZ (web servers)
    - Data center (critical servers)
    - Cloud environments (AWS/Azure/GCP)
    - Remote/VPN segment

Step 2: Configure Attack Scenarios

# Example BAS scenario configuration
scenario:
  name: "APT29 (Cozy Bear) Full Kill Chain"
  threat_group: APT29
  mitre_attack_techniques:
    - T1566.001  # Spearphishing Attachment
    - T1059.001  # PowerShell Execution
    - T1547.001  # Registry Run Key Persistence
    - T1003.001  # LSASS Memory Credential Dump
    - T1021.002  # SMB/Windows Admin Shares
    - T1071.001  # Web Protocol C2
    - T1048.003  # DNS Exfiltration

  phases:
    - name: "Initial Access"
      actions:
        - deliver_phishing_payload:
            type: office_macro
            target: email_gateway
            variants: [docm, xlsm, ppam]

    - name: "Execution & Persistence"
      actions:
        - execute_powershell:
            encoded: true
            amsi_bypass: true
        - create_scheduled_task:
            technique: T1053.005

    - name: "Credential Access"
      actions:
        - dump_lsass:
            method: [procdump, comsvcs, nanodump]

    - name: "Lateral Movement"
      actions:
        - psexec_lateral:
            target: internal_server
        - wmi_lateral:
            target: file_server

    - name: "Exfiltration"
      actions:
        - dns_exfiltration:
            data_size: 10MB
            encoding: base64

Step 3: Map Results to Security Controls

def map_bas_results_to_controls(simulation_results):
    """Map BAS results to security control effectiveness."""
    control_scores = {}

    control_mapping = {
        "email_gateway": ["T1566.001", "T1566.002", "T1566.003"],
        "edr": ["T1059.001", "T1003.001", "T1055", "T1547.001"],
        "ngfw": ["T1071.001", "T1071.004", "T1048"],
        "siem": ["T1053.005", "T1021.002", "T1087"],
        "dlp": ["T1048.003", "T1567", "T1041"],
        "ndr": ["T1071", "T1021", "T1040"],
    }

    for control, techniques in control_mapping.items():
        relevant = [r for r in simulation_results
                    if r["technique_id"] in techniques]
        if not relevant:
            continue

        prevented = sum(1 for r in relevant if r["result"] == "prevented")
        detected = sum(1 for r in relevant if r["result"] == "detected")
        missed = sum(1 for r in relevant if r["result"] == "missed")
        total = len(relevant)

        control_scores[control] = {
            "total_tests": total,
            "prevented": prevented,
            "detected": detected,
            "missed": missed,
            "prevention_rate": round(prevented / total * 100, 1),
            "detection_rate": round(detected / total * 100, 1),
            "effectiveness": round((prevented + detected) / total * 100, 1),
        }

    return control_scores

Step 4: Schedule Continuous Validation

Validation Schedule:
  Daily:
    - Malware delivery simulation (email gateway test)
    - C2 communication simulation (firewall/proxy test)
    - Known ransomware behavior simulation (EDR test)

  Weekly:
    - Full kill chain simulation (APT scenario)
    - Lateral movement simulation (network segmentation test)
    - Data exfiltration simulation (DLP test)

  Monthly:
    - Full MITRE ATT&CK coverage assessment
    - New threat group TTP simulation
    - Regression testing after security control changes

  On-Demand:
    - After firewall rule changes
    - After EDR policy updates
    - After new threat intelligence (zero-day response)

Best Practices

  1. Start with known threat group simulations relevant to your industry
  2. Always run simulations in safe mode first before enabling full emulation
  3. Coordinate with SOC team so they can distinguish BAS traffic from real attacks
  4. Use BAS results to prioritize SIEM detection rule development
  5. Track control effectiveness scores over time to demonstrate security posture improvement
  6. Integrate BAS with ticketing systems to auto-generate remediation tickets for gaps
  7. Run validation after every security control change to catch regressions
  8. Map all simulations to MITRE ATT&CK for standardized reporting

Common Pitfalls

  • Running BAS without informing the SOC, causing unnecessary incident response
  • Testing only prevention and ignoring detection/response validation
  • Not acting on BAS findings, leading to persistent security gaps
  • Deploying BAS agents only in one network zone, missing cross-zone gaps
  • Focusing only on commodity threats instead of APT-relevant scenarios
  • Treating BAS as a replacement for penetration testing rather than a complement

Related Skills

  • implementing-attack-path-analysis-with-xm-cyber
  • performing-purple-team-exercise
  • implementing-siem-use-cases-for-detection
  • implementing-threat-modeling-with-mitre-attack

Frequently asked questions about Continuous Security Validation

Similar skills