operating-havoc-c2
Skill này làm gì
Công cụ này giúp thiết lập máy chủ command and control (C2) tên Havoc. Nó cho phép bạn tạo agent (chương trình độc hại) khó bị phần mềm bảo mật phát hiện nhờ các kỹ thuật né tránh nâng cao. Bạn có thể dùng công cụ này cho các kiểm thử bảo mật hệ thống đã được cho phép.
Khi nào nên dùng
- ✓Trong các bài kiểm thử red-team được ủy quyền cần một hệ thống C2 nâng cao.
- ✓Để mô phỏng cách kẻ tấn công thực sự dùng các công cụ như Havoc.
- ✓Để kiểm tra xem phần mềm bảo mật có phát hiện các agent cố ẩn mình hay không.
Liên kết skill
https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/operating-havoc-c2/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Thiết lập máy chủ Havoc C2 với một profile dùng sleep obfuscation và indirect syscalls để tạo agent Demon né tránh.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Bạn viết một file cấu hình (profile) mô tả cách máy chủ và agent hoạt động. Sau đó, bạn khởi động máy chủ và dùng một chương trình đồ họa (client) để tạo agent và gửi lệnh cho chúng.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Operating Havoc C2
Legal Notice: This skill is for authorized security testing, sanctioned red-team engagements, and education only. Deploying a C2 framework or its agents against systems you do not own or lack explicit written authorization to test is illegal. Operate strictly within a signed rules-of-engagement document.
Overview
Havoc is an open-source, modern command-and-control framework created by @C5pider (https://github.com/HavocFramework/Havoc). Its primary implant, the Demon, is written in C and assembly and was designed from the ground up for evasion: it supports indirect syscalls (Hell's Gate / Halo's Gate), return-address and stack spoofing, and sleep obfuscation techniques (Ekko / FOLIAGE) that encrypt the agent in memory while it sleeps. The team server is the backend that starts listeners, queues tasks, manages agent check-ins, and brokers operator connections over an encrypted WebSocket. Operators connect with the Havoc client, a Qt GUI.
Havoc's behavior is driven by a Yaotl profile — a configuration language forked from HashiCorp's HCL — which defines the team server, operators, listeners, and Demon defaults. Because Havoc has been observed in real intrusions and is favored for its evasion features, exercising it during authorized engagements is valuable for emulating advanced adversary tradecraft and for testing whether EDR and network sensors detect its HTTP(S) C2 and in-memory techniques. This skill covers building Havoc, writing a profile, launching the team server, generating Demon agents, and running post-exploitation and lateral movement.
When to Use
- When an authorized red-team engagement calls for an evasive, GUI-driven C2
- When emulating an adversary that uses Havoc/Demon (per threat intelligence) in a purple-team exercise
- When validating EDR detection of indirect syscalls, sleep obfuscation, and stack spoofing
- When demonstrating post-exploitation impact and lateral movement for a report
Prerequisites
- A dedicated Linux host (Debian/Ubuntu/Kali) for the team server
- Go 1.18+ for the team server; Python 3.10 and Qt5 libraries for the client
- mingw-w64 and nasm for cross-compiling the Demon for Windows targets
- Signed authorization / rules of engagement
Install dependencies and build from source:
# Clone the framework
git clone https://github.com/HavocFramework/Havoc.git
cd Havoc
# Debian/Ubuntu/Kali build dependencies
sudo apt update && sudo apt install -y \
git build-essential cmake libfontconfig1 libglu1-mesa-dev libgtest-dev \
libspdlog-dev libboost-all-dev libncurses5-dev libgdbm-dev libssl-dev \
libreadline-dev libffi-dev libsqlite3-dev libbz2-dev qtbase5-dev qtchooser \
qt5-qmake qtbase5-dev-tools libqt5websockets5 libqt5websockets5-dev \
qtdeclarative5-dev golang-go python3.10 python3.10-dev mingw-w64 nasm
# Build the team server
make ts-build
# Build the client
make client-build
Objectives
- Author a Yaotl profile defining team server, operators, and a listener
- Launch the Havoc team server and connect with the client
- Create an HTTP(S) listener
- Generate an evasive Demon agent (EXE / shellcode) with sleep obfuscation
- Interact with the Demon and run post-exploitation commands
- Execute .NET assemblies and BOFs in-memory
- Pivot through the beachhead via SOCKS and port forwarding
MITRE ATT&CK Mapping
| ID | Technique | Use in this skill |
|---|---|---|
| T1071.001 | Application Layer Protocol: Web Protocols | The Demon's HTTP(S) listener carries C2 over web protocols to blend with normal traffic |
Related techniques exercised by the workflow:
| ID | Technique |
|---|---|
| T1027.007 | Obfuscated Files or Information: Dynamic API Resolution (indirect syscalls) |
| T1620 | Reflective Code Loading (in-memory .NET / BOF) |
| T1055 | Process Injection |
| T1090.001 | Internal Proxy (SOCKS pivot) |
Workflow
Step 1: Write a Yaotl profile
Create profiles/engagement.yaotl defining the team server, an operator, and an HTTP listener. Yaotl is HCL-style:
Teamserver {
Host = "0.0.0.0"
Port = 40056
Build {
Compiler64 = "/usr/bin/x86_64-w64-mingw32-gcc"
Nasm = "/usr/bin/nasm"
}
}
Operators {
user "operator1" {
Password = "ChangeMe_Str0ng!"
}
}
Listeners {
Http {
Name = "https-listener"
Hosts = ["c2.example.com"]
HostBind = "0.0.0.0"
PortBind = 443
…
Câu hỏi thường gặp
Máy chủ C2 là gì?
Đây là máy chủ do bạn kiểm soát để gửi lệnh tới các agent (chương trình) đã được cài trên máy tính khác. Nó hoạt động như một trung tâm điều khiển.
“Evasive agent” nghĩa là gì?
Nghĩa là agent được thiết kế để khó bị phần mềm diệt virus hoặc bảo mật phát hiện, bằng cách dùng các kỹ thuật ngụy trang.
“Indirect syscalls” và “sleep obfuscation” là gì?
Đây là các kỹ thuật nâng cao để agent ẩn mình trong bộ nhớ máy tính và tránh bị phát hiện. “Indirect syscalls” gọi các lệnh hệ thống theo cách ngụy trang, còn “sleep obfuscation” xáo trộn mã của agent khi nó đang “ngủ”.
Chi tiết
Mô tả gốc của tác giả
Deploy a Havoc C2 team server with Yaotl malleable profiles, generate evasive Demon agents using indirect syscalls and sleep obfuscation, and run post-exploitation and pivoting operations. Use during authorized, rules-of-engagement-bound red-team engagements for adversary emulation requiring a full C2 lifecycle (server setup, evasive implant generation, tasking, and lateral pivoting).
Độ phổ biến
- Sao GitHub
- 35k
- Vị trí xếp hạng
- #7674
- Giấy phép
- Apache-2.0
- Cập nhật
- 31/8/2026
Bình luận
- …
Thêm skill từ kho mã này
abusing-dpapi-for-credential-access
35kCung cấp cho agent AI của bạn hướng dẫn có sẵn cho một tác vụ cụ thể, giúp nó làm việc tốt hơn và nhanh hơn.
abusing-shadow-credentials-for-privesc
35kDạy agent AI của bạn viết văn bản rõ ràng và có cấu trúc tốt.
achieving-cmmc-level-2-compliance
35kGiúp agent của bạn chuẩn bị môi trường để tuân thủ CMMC Level 2. Triển khai các yêu cầu bảo mật và quản lý tài liệu cần thiết.
acquiring-disk-image-with-dd-and-dcfldd
35kGiúp agent của bạn tạo bản sao chính xác của ổ đĩa. Cách này đảm bảo không mất hay thay đổi thông tin trong quá trình điều tra.
Skill tương tự
openclaw-update
394kGiúp agent của bạn cập nhật OpenClaw Gateway đang có, chọn cách cập nhật phù hợp với cách cài đặt và giữ phiên làm việc của bạn hoạt động.
diagnose-gateway
394kGiúp agent của bạn tìm hiểu vì sao OpenClaw Gateway bị lỗi bằng cách kiểm tra cài đặt, kênh và cổng mà không thay đổi gì.
crabbox-apps
394kGiúp agent của bạn mở và chạy một app trên máy đám mây tạm thời, rồi hiển thị giao diện của nó trong thanh bên của chat.