用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/CyberStrikeus/CyberStrike --skill cis-ubuntu2004-v300-4-2-7命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
macOS post-exploitation for credential harvesting, DTrace monitoring, TCC bypass, and stealth operations via native tools
Windows userland post-exploitation for credential harvesting, monitoring, AMSI/ETW bypass, and stealth operations
Kubernetes post-exploitation for container escape, secret extraction, RBAC abuse, and cluster persistence
基于 SOC 职业分类
正在显示 SKILL.md
| name | cis-ubuntu2004-v300-4-2-7 |
| description | Ensure ufw firewall rules exist for all open ports |
| category | cis-networking |
| version | 3.0.0 |
| author | cyberstrike-official |
| tags | ["cis","ubuntu","linux","ubuntu-20.04","firewall","ufw"] |
| cis_id | 4.2.7 |
| cis_benchmark | CIS Ubuntu Linux 20.04 LTS Benchmark v3.0.0 |
| tech_stack | ["ubuntu","linux"] |
| cwe_ids | [] |
| chains_with | [] |
| prerequisites | [] |
| severity_boost | {} |
Services and ports can be accepted or explicitly rejected.
Note:
To reduce the attack surface of a system, all services and ports should be blocked unless required.
Run the following script to verify a firewall rule exists for all open ports:
#!/usr/bin/env bash
{
unset a_ufwout
unset a_openports
# Read UFW Ports
while read -r l_ufwport; do
[ -n "$l_ufwport" ] && a_ufwout+=("$l_ufwport")
done < <(ufw show raw 2>&1 |grep -Po 'dpt:\K\d+' |sort -u)
# Read Multiport Rules
while read -r l_multiport; do
for port in $(echo "$l_multiport" | awk -F'--dports ' '{print $2}' | awk -F' ' | );
[[ == *:* ]];
IFS= -r start_port end_port <<<
((i=start_port; i<=end_port; i++));
a_ufwout+=()
a_ufwout+=()
< /etc/ufw/user.rules
-r l_openport;
[ -n ] && a_openports+=()
< <(ss -tuln | awk |
-u)
a_diff=()
[[ -n ]];
-e
-e
}
- Audit Passed -
- All open ports have a rule in UFW
For each port identified in the audit which does not have a firewall rule, evaluate the service listening on the port and add a rule for accepting or denying inbound connections in accordance with local site policy: Examples:
ufw allow in <port>/<tcp or udp protocol>
ufw deny in <port>/<tcp or udp protocol>
Note: Examples create rules for from any, to any. More specific rules should be concentered when allowing inbound traffic e.g only traffic from this network. Example to allow traffic on port 443 using the tcp protocol from the 192.168.1.0 network:
ufw allow from 192.168.1.0/24 to any proto tcp port 443
Not applicable.
v8 - 4.4 Implement and Manage a Firewall on Servers v7 - 9.4 Apply Host-based Firewalls or Port Filtering
MITRE ATT&CK Mappings: T1562, T1562.004 | TA0011 | M1031, M1037