15-blue-team-defense
System hardening, detection engineering, security baseline monitoring,
Install / Use
npx skills add Masriyan/Claude-Code-CyberSecurity-Skill --skill 15-blue-team-defenseInstalls into whichever agent you are using.
SKILL.md
Installable skill definition
Quality Score
Category
SecuritySupported Platforms
Our assessment of 15-blue-team-defense
15-blue-team-defense scores 88/100 on our quality scale, 645th of 1,094 Security skills we index.
Its SKILL.md is 25 KB long, well organised into 101 sections with 24 code examples: a thorough specification that gives an agent plenty to work with.
It has 441 GitHub stars, a meaningful sign that others use it.
Maintenance, license and trust
- The repository was last updated about 2 months ago, so 15-blue-team-defense is actively maintained.
- Our last check on 2026-11-01 found the source still online.
- It is released under the MIT license, a permissive license that allows use, modification and commercial use with attribution.
- Its trust signals score 100/100, with no cautions. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.
Safety scan
No issues foundOur scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful.
AI review by kimi-k2.7-code on 2026-10-07. Automated pattern scan on 2026-10-07. It catches known dangerous patterns, not every risk — read a skill before letting an agent act on it.
15-blue-team-defense compared with similar skills
All 4 of these similar skills score higher than 15-blue-team-defense; compare them before choosing.
| Skill | Score | Stars | Updated | Format |
|---|---|---|---|---|
| 15-blue-team-defense (this skill)by Masriyan | 88 | 441 | 2mo ago | SKILL.md |
| Agent-Reachby Panniantong | 100 | 112.8k | 10d ago | CLAUDE.md |
| headroomby headroomlabs-ai | 100 | 79.9k | today | CLAUDE.md |
| Scraplingby D4Vinci | 100 | 104.0k | today | MCP Server |
| crawl4aiby unclecode | 100 | 87.5k | today | MCP Server |
Frequently asked questions
- How do I install 15-blue-team-defense?
- Run
npx skills add Masriyan/Claude-Code-CyberSecurity-Skill --skill 15-blue-team-defense. The install tabs above show the steps for each supported agent. - Which AI agents does 15-blue-team-defense work with?
- It is written for Claude Code, as a SKILL.md file. Other agents that read the same format can often use it too.
- Is 15-blue-team-defense safe to use?
- Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful. It is MIT-licensed and scores 100/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
- Is 15-blue-team-defense still maintained?
- The repository was last updated about 2 months ago, so 15-blue-team-defense is actively maintained.
Skill content
View source on GitHubname: Blue Team Defense & Hardening description: System hardening, detection engineering, security baseline monitoring, patch management, defense-in-depth architecture, and security posture improvement version: 3.1.0 author: Masriyan tags: [cybersecurity, blue-team, defense, hardening, detection, baseline, siem, endpoint, cis]
Blue Team Defense & Hardening
Purpose
Enable Claude to assist defenders with comprehensive security hardening, detection rule engineering, security baseline establishment, patch management, and security architecture review. Claude directly analyzes provided configurations, scripts, and system state — then produces specific hardening commands, detection rules, and improvement plans.
Activation Triggers
This skill activates when the user asks about:
- Hardening Linux (Ubuntu, RHEL, CentOS, Debian) servers
- Hardening Windows Server or Windows workstations (CIS Benchmarks)
- Creating detection rules (Sigma, Splunk, KQL, YARA, Snort/Suricata)
- Security baseline definition and monitoring
- Patch management strategy and prioritization
- Security architecture review (defense-in-depth, zero trust)
- Implementing Sysmon, auditd, or Windows audit policy
- Hardening SSH, nginx, Apache, or database configurations
- Network security controls and microsegmentation
- Endpoint protection (EDR, HIPS) configuration guidance
- Security posture improvement after a red team or pentest
Prerequisites
pip install pyyaml jinja2 requests
Tools used in this skill:
Sysmon— Windows endpoint telemetry (SwiftOnSecurity config recommended)auditd— Linux audit daemonLynis— Linux security auditing toolOpenSCAP / oscap— CIS/STIG compliance scanningfail2ban— SSH and service brute-force protectionCIS-CAT— CIS Benchmark compliance tool
Core Capabilities
1. Linux System Hardening
When the user asks to harden a Linux server:
Claude produces specific commands ready to run.
SSH Hardening
# /etc/ssh/sshd_config — Secure SSH configuration
cat >> /etc/ssh/sshd_config << 'EOF'
# Security hardening
Protocol 2
PermitRootLogin no
PasswordAuthentication no
PermitEmptyPasswords no
MaxAuthTries 3
LoginGraceTime 30
ClientAliveInterval 300
ClientAliveCountMax 2
AllowUsers [specific_users] # Explicit user allowlist
PubkeyAuthentication yes
AuthorizedKeysFile .ssh/authorized_keys
X11Forwarding no
AllowAgentForwarding no
AllowTcpForwarding no
PrintMotd no
Banner /etc/ssh/banner
Subsystem sftp /usr/lib/openssh/sftp-server -l INFO
EOF
# Restart SSH (check config first)
sshd -t && systemctl restart sshd
Kernel Hardening (sysctl)
# /etc/sysctl.d/99-security.conf
cat > /etc/sysctl.d/99-security.conf << 'EOF'
# Disable IP forwarding (unless this is a router)
net.ipv4.ip_forward = 0
net.ipv6.conf.all.forwarding = 0
# Disable source routing (prevents IP spoofing attacks)
net.ipv4.conf.all.accept_source_route = 0
net.ipv6.conf.all.accept_source_route = 0
# Enable SYN cookies (SYN flood protection)
net.ipv4.tcp_syncookies = 1
# Ignore ICMP broadcasts
net.ipv4.icmp_echo_ignore_broadcasts = 1
# Disable ICMP redirects (prevents routing manipulation)
net.ipv4.conf.all.accept_redirects = 0
net.ipv6.conf.all.accept_redirects = 0
net.ipv4.conf.all.send_redirects = 0
# Log suspicious packets
net.ipv4.conf.all.log_martians = 1
# Disable IPv6 if not needed
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
# Address space layout randomization
kernel.randomize_va_space = 2
# Restrict core dumps (prevents memory leaks)
fs.suid_dumpable = 0
# Restrict kernel log access to root
kernel.dmesg_restrict = 1
# Disable magic SysRq key
kernel.sysrq = 0
# Hide kernel pointers
kernel.kptr_restrict = 2
# Restrict ptrace to own processes
kernel.yama.ptrace_scope = 1
EOF
sysctl --system
Firewall Configuration (iptables/nftables)
# UFW (Uncomplicated Firewall) — Ubuntu/Debian
ufw default deny incoming
ufw default allow outgoing
ufw allow ssh # or: ufw allow from [admin_ip] to any port 22
ufw allow from [monitoring_ip] to any port 9100 # Prometheus node exporter (internal only)
ufw enable
ufw status verbose
# iptables — manual approach for fine-grained control
iptables -F # Flush existing rules
iptables -P INPUT DROP # Default deny
iptables -P FORWARD DROP # Default deny forwarding
iptables -P OUTPUT ACCEPT # Allow all outbound (or restrict too)
# Allow established/related connections
iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
# Allow loopback
iptables -A INPUT -i lo -j ACCEPT
# Allow SSH from specific subnet only
iptables -A INPUT -p tcp --dport 22 -s 10.0.0.0/8 -m conntrack --ctstate NEW -j ACCEPT
# Rate-limit SSH to prevent brute force
iptables -A INPUT -p tcp --dport 22 -m recent --set --name SSH
iptables -A INPUT -p tcp --dport 22 -m recent --update --seconds 60 --hitcount 4 --name SSH -j DROP
# Allow HTTPS
iptables -A INPUT -p tcp --dport 443 -m conntrack --ctstate NEW -j ACCEPT
# Log and drop everything else
iptables -A INPUT -j LOG --log-prefix "iptables-DROP: " --log-level 7
iptables -A INPUT -j DROP
# Save rules
iptables-save > /etc/iptables/rules.v4
File System Security
# Find SUID/SGID binaries (audit these)
find / -perm /4000 -type f 2>/dev/null | sort # SUID
find / -perm /2000 -type f 2>/dev/null | sort # SGID
# Remove unnecessary SUID bits
chmod u-s /usr/bin/at # Example: remove SUID from 'at' if not needed
# World-writable files (should be minimal)
find / -perm -002 -type f 2>/dev/null | grep -v proc
# Secure /tmp and /var/tmp
# In /etc/fstab, add: nodev,nosuid,noexec for /tmp
# tmpfs /tmp tmpfs defaults,rw,nosuid,nodev,noexec,relatime 0 0
# Immutable critical files (prevent modification even as root)
chattr +i /etc/passwd
chattr +i /etc/shadow
chattr +i /etc/sudoers
# File integrity monitoring
apt-get install aide
aideinit
aide --check # Run periodically, alert on changes
Audit Logging (auditd)
# Install auditd
apt-get install auditd
# /etc/audit/rules.d/hardening.rules
cat > /etc/audit/rules.d/hardening.rules << 'EOF'
# Monitor system calls
-a always,exit -F arch=b64 -S execve -k exec_tracking
-a always,exit -F arch=b32 -S execve -k exec_tracking
# Monitor authentication
-w /etc/passwd -p wa -k identity
-w /etc/shadow -p wa -k identity
-w /etc/group -p wa -k identity
-w /etc/sudoers -p wa -k sudoers
# Monitor privileged commands
-a always,exit -F path=/usr/bin/sudo -F perm=x -F auid>=1000 -F auid!=4294967295 -k sudo_use
-a always,exit -F path=/usr/bin/su -F perm=x -F auid>=1000 -F auid!=4294967295 -k su_use
# Monitor network configuration changes
-a always,exit -F arch=b64 -S sethostname -k network_changes
-w /etc/hosts -p wa -k network_changes
# Monitor cron
-w /etc/cron.d/ -p wa -k cron
-w /etc/cron.daily/ -p wa -k cron
-w /var/spool/cron/ -p wa -k cron
# Monitor SSH configuration
-w /etc/ssh/sshd_config -p wa -k sshd_config
# Successful file deletion (detect cleanup by attackers)
-a always,exit -F arch=b64 -S unlink,unlinkat,rename,renameat -F auid>=1000 -k delete
# Make the configuration immutable (requires reboot to change)
-e 2
EOF
service auditd restart
# Query audit logs
ausearch -k sudo_use -i # Find all sudo usage
ausearch -k identity -i # Find all user/group changes
Linux Hardening Checklist
Authentication:
[ ] Root login disabled (local and SSH)
[ ] Password authentication disabled for SSH (key-only)
[ ] Strong password policy enforced (PAM pwquality)
[ ] sudo configured with minimal privilege (specific commands, no NOPASSWD)
[ ] Inactive accounts locked or removed (>90 days)
Services:
[ ] Unnecessary services disabled (systemctl list-units --state=active)
[ ] No listening services on 0.0.0.0 that shouldn't be public
[ ] Web server runs as non-root user
[ ] Database not accessible from internet
Kernel & OS:
[ ] Security patches current (apt upgrade / yum update)
[ ] ASLR enabled (randomize_va_space=2)
[ ] ptrace restrictions (yama.ptrace_scope=1)
[ ] Core dumps disabled or restricted
[ ] AppArmor/SELinux in enforcing mode
Monitoring:
[ ] auditd installed and running
[ ] Log forwarding to SIEM configured
[ ] File integrity monitoring active
[ ] fail2ban installed for SSH protection
2. Windows System Hardening
When the user asks to harden a Windows system:
PowerShell — Immediate Hardening Commands:
# Disable LLMNR (used in LLMNR poisoning attacks)
New-Item -Path "HKLM:\Software\Policies\Microsoft\Windows NT\DNSClient" -Force
Set-ItemProperty -Path "HKLM:\Software\Policies\Microsoft\Windows NT\DNSClient" `
-Name "EnableMulticast" -Value 0 -Type DWord
# Disable NBT-NS (NetBIOS Name Service — used in Responder attacks)
$adapters = Get-WmiObject Win32_NetworkAdapterConfiguration | Where-Object {$_.IPEnabled}
foreach ($adapter in $adapters) {
$adapter.SetTcpipNetbios(2) # 2 = Disable NetBIOS over TCP/IP
}
# Enable PowerShell Script Block Logging
$psLogPath = "HKLM:\Software\Policies\Microsoft\Windows\PowerShell\ScriptBlockLogging"
New-Item -Path $psLogPath -Force
Set-ItemProperty -Path $psLogPath -Name "EnableScriptBlockLogging" -Value 1
# Disable SMBv1 (EternalBlue vulnerability)
Set-SmbServerConfiguration -EnableSMB1Protocol $false -Force
Disable-WindowsOptionalFeature -Online -FeatureName SMB1Protocol
# Enable Windows Defender real-time protection
Set-MpPreference -DisableRealtimeMonitoring $false
Set-MpPreference -CloudBlockLevel High
Set-MpPreference -CloudExtendedTimeout 50
Update-MpSignature
# Enable Windows Firewall on all profiles
Set-NetFirewallProfile -Profile Domain,Public,Private -Enabled True
# Enable Credential Guard (requires Windows 10/2016+)
# Set via Group Policy: Computer Configuration → Administrative Templates →
# System → Device Guard → Turn On Virtualization Based Security
Sysmon Deployment for Endpoint Visibility:
# Download Sysmon and SwiftOnSecurity config
Invoke-WebRequest -Uri "https://live.sysinternals.com/Sysmon64.exe" -OutFile C:\Windows\Sysmon64.exe
# Deploy with SwiftOnSecurity config (most commonly recommended)
# Download config: https://github.com/SwiftOnSecurity/sysmon-config/blob/master/sysmonconfig-export.xml
Sysmon64.exe -accepteula -i sysmonconfig-export.xml
# Verify Sysmon is running
Get-Service Sysmon64
Get-WinEvent -LogName "Microsoft-Windows-Sysmon/Operational" -MaxEvents 10
Windows Audit Policy:
# Enable comprehensive Windows audit policy
# (Or configure via Group Policy → Computer Config → Windows Settings → Security Settings → Advanced Audit Policy)
auditpol /set /subcategory:"Logon" /success:enable /failure:enable
auditpol /set /subcategory:"Logoff" /success:enable
auditpol /set /subcategory:"Account Lockout" /failure:enable
auditpol /set /subcategory:"Process Creation" /success:enable
auditpol /set /subcategory:"Account Management" /success:enable /failure:enable
auditpol /set /subcategory:"Privilege Use" /success:enable /failure:enable
auditpol /set /subcategory:"Policy Change" /success:enable
auditpol /set /subcategory:"Directory Service Changes" /success:enable /failure:enable
auditpol /set /subcategory:"Kerberos Authentication Service" /success:enable /failure:enable
auditpol /set /subcategory:"Kerberos Service Ticket Operations" /success:enable /failure:enable
# Enable command line logging in Event ID 4688
reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System\Audit" `
/v ProcessCreationIncludeCmdLine_Enabled /t REG_DWORD /d 1 /f
Windows Hardening Checklist (CIS Level 1):
Account Security:
[ ] Guest account disabled
[ ] Local Administrator account disabled or renamed
[ ] LAPS deployed (Local Administrator Password Solution)
[ ] No accounts with "Password never expires"
[ ] Account lockout: 5 attempts, 30-min lockout
[ ] Adm
Truncated for display — read the full file on GitHub.
Related Skills
Agent-Reach
112.8kGive your AI agent eyes to see the entire internet. Read & search Twitter, Reddit, YouTube, GitHub, Bilibili, XiaoHongShu — one CLI, zero API fees.
headroom
79.9kCompress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.
Scrapling
104.0k🕷️ The BEST Web Scraping framework that handles everything from a single request to a full-scale crawl! Don't be shy, join here: https://discord.gg/EMgGbDceNQ and follow here for daily tips and tricks: https://x.com/Scrapling_dev
crawl4ai
87.5kOfficial Crawl4AI Cloud: a hosted web scraping, extraction, and search API for AI agents. Free API key, 1,000 credits a month, no card. Fully open source: this repo is the Apache-2.0 crawler that powers it, and you can self-host it.
Languages
Trust signals
From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.
