exploiting-aws-with-pacu
यह क्या करती है
यह टूल AWS cloud accounts की सुरक्षा जाँचने में मदद करता है। यह देखता है कि ज़्यादा permissions पाने (privilege escalation) के रास्ते हैं या नहीं, और यह आपके लिए ऐसे छिपे access points भी बना सकता है जिनसे आप बाद में वापस आ सकें (persistence)।
कब इस्तेमाल करें
- ✓जब किसी AWS account पर अधिकृत सुरक्षा जाँच कर रहे हों।
- ✓यह देखने के लिए कि चुराए गए credential से हमलावर क्या कर सकता है।
- ✓यह दिखाने के लिए कि accounts को अनधिकृत पहुँच से बेहतर कैसे बचाया जाए।
Skill का लिंक
https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/exploiting-aws-with-pacu/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“मेरे AWS account की पूरी सुरक्षा जाँच करो और बताओ कि कहीं कोई कमज़ोरी है या नहीं।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
टूल आपके credentials से AWS account से जुड़ता है और सभी permissions जाँचता है। यह ज़्यादा access पाने के ज्ञात रास्ते ढूंढता है और access बनाए रखने के लिए नई access keys या permissions बना सकता है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
Exploiting AWS with Pacu
Legal Notice: This skill is for authorized penetration testing and educational purposes only. Pacu performs active enumeration, privilege escalation, persistence, and backdooring against live AWS accounts. Run it ONLY against accounts you own or have explicit written authorization (scope/Rules of Engagement) to test. Many modules create durable changes (new IAM users, access keys, policies); track and remove everything. Unauthorized use is illegal under the CFAA and equivalent laws.
Overview
Pacu is the open-source AWS exploitation framework from Rhino Security Labs. It is the cloud-pentest analogue of Metasploit: a modular Python console that manages target sessions, enumerates an AWS account, identifies privilege-escalation paths, and executes persistence/backdooring/exfiltration modules — all backed by a local SQLite database that records every enumerated resource so modules can chain off one another's findings.
A Pacu engagement follows a consistent arc. You create a named session, load AWS keys (with set_keys or by importing from ~/.aws/credentials), confirm the identity with whoami, then enumerate IAM and the rest of the account. The flagship workflow is iam__enum_permissions followed by iam__privesc_scan, which checks the compromised principal against ~20 known AWS IAM privilege-escalation primitives (e.g. iam:CreatePolicyVersion, iam:AttachUserPolicy, iam:PassRole + lambda:CreateFunction, sts:AssumeRole) and can auto-exploit them. Persistence modules such as iam__backdoor_users_keys mint a second access key on an existing user, and iam__backdoor_assume_role adds a trust to a role so the attacker can assume it later.
This skill covers installing Pacu, session and credential management, IAM enumeration, automated privilege-escalation scanning and exploitation, persistence/backdooring, and data access — every command and module name verified against the Rhino Security Labs project. Source: github.com/RhinoSecurityLabs/pacu.
When to Use
- Conducting an authorized AWS cloud penetration test or red-team engagement
- Assessing the blast radius of a single compromised IAM credential (privesc scanning)
- Demonstrating persistence/backdoor techniques to drive remediation
- Generating realistic attacker telemetry to test cloud detections (purple team)
- Mapping an unfamiliar AWS account's IAM, EC2, S3, and Lambda exposure
Prerequisites
- Pacu installed:
python3 -m pip install -U pip python3 -m pip install -U pacu # then run: pacu # or, preferred on Kali, with pipx: pipx install git+https://github.com/RhinoSecurityLabs/pacu.git # or Docker: docker run -it rhinosecuritylabs/pacu:latest - AWS access key/secret (and optional session token) for the in-scope target principal
- A signed authorization / Rules of Engagement document defining scope
- Python 3.9+ and outbound HTTPS to AWS API endpoints
- AWS CLI installed for verification (
aws sts get-caller-identity)
Objectives
- Install Pacu and create an isolated engagement session
- Load and validate target AWS credentials
- Enumerate IAM permissions for the compromised principal
- Identify and (where authorized) exploit privilege-escalation paths
- Establish persistence via backdoor access keys and role trusts
- Enumerate and access data in EC2, S3, and Secrets Manager
- Export findings for reporting and ensure all artifacts are removed
MITRE ATT&CK Mapping
| ID | Name | Use in this skill |
|---|---|---|
| T1078.004 | Valid Accounts: Cloud Accounts | Pacu operates as a valid AWS principal and abuses its permissions |
| T1098.001 | Account Manipulation: Additional Cloud Credentials | iam__backdoor_users_keys mints a second access key |
| T1098.003 | Account Manipulation: Additional Cloud Roles | iam__backdoor_assume_role / privesc via role policy changes |
| T1580 | Cloud Infrastructure Discovery | ec2__enum, iam__enum_users_roles_policies_groups |
| T1530 | Data from Cloud Storage | s3__download_bucket retrieves S3 objects |
| T1552.005 | Unsecured Credentials: Cloud Instance Metadata API | EC2 IMDS credential abuse |
Workflow
1. Launch Pacu and create a session
pacu
# In the Pacu console:
Pacu> set_keys
# key alias : engagement-target
# access key : AKIA...
# secret key : ...
# session tok: (optional)
2. Confirm the identity you are operating as
Pacu> whoami
…
अक्सर पूछे जाने वाले सवाल
क्या इस टूल को इस्तेमाल करने के लिए अनुमति चाहिए?
हाँ, इसे सिर्फ़ उन्हीं AWS accounts पर इस्तेमाल करें जो आपके अपने हैं या जिनकी जाँच के लिए आपके पास लिखित अनुमति है। बिना अनुमति इस्तेमाल करना गैरकानूनी है।
'privilege escalation' क्या है?
जब सीमित access वाला यूज़र या प्रोग्राम ऐसी permissions हासिल कर लेता है जो उसे नहीं मिलनी चाहिए थीं, जैसे कोई साधारण कर्मचारी डायरेक्टर की फ़ाइलों तक पहुँच जाए।
इस संदर्भ में 'persistence' का क्या मतलब है?
इसका मतलब है AWS account तक पहुँच बनाए रखने का रास्ता बनाना, ताकि मूल credential पकड़े जाने या रद्द होने के बाद भी access बना रहे, जैसे कोई 'बैकडोर' खुला छोड़ देना।
जानकारी
लेखक का मूल विवरण
Runs the Pacu AWS exploitation framework end-to-end — session and credential setup, IAM enumeration, automated privilege-escalation scanning via iam__privesc_scan, and persistence/backdooring modules like iam__backdoor_users_keys. Use for authorized AWS penetration tests or red-team engagements, assessing blast radius from a compromised IAM credential, or generating attacker telemetry for purple-t
लोकप्रियता
- GitHub स्टार
- 35k
- रैंकिंग में स्थान
- #7839
- लाइसेंस
- Apache-2.0
- अपडेट की गई
- 31/8/2026
कमेंट
- …
इस repository की और skills
abusing-dpapi-for-credential-access
35kआपके AI एजेंट को किसी खास काम के लिए तैयार instructions देता है, ताकि वह उसे बेहतर और तेज़ी से कर सके।
abusing-shadow-credentials-for-privesc
35kआपके AI एजेंट को साफ़ और अच्छी तरह से व्यवस्थित लिखना सिखाता है।
achieving-cmmc-level-2-compliance
35kयह आपके एजेंट को CMMC Level 2 compliance के लिए environment तैयार करने में मदद करता है। यह security requirements लागू करता है और ज़रूरी documentation संभालता है।
acquiring-disk-image-with-dd-and-dcfldd
35kआपके एजेंट को hard drives की exact copies बनाने में मदद करता है। जाँच के दौरान किसी भी जानकारी के खोने या बदलने से बचाने के लिए यह उपयोगी है।
मिलती-जुलती skills
diffs
394kयह आपके एजेंट को बदलावों का असली diff बनाने देती है, जिसे व्यूअर लिंक या इमेज फ़ाइल के रूप में साझा किया जा सकता है, हाथ से लिखे सारांश के बजाय।
coding-agent
394kयह आपके एजेंट को बड़े कोडिंग काम Codex, Claude Code या OpenCode को बैकग्राउंड वर्कर के रूप में सौंपने, फिर उसकी प्रगति जांचने में मदद करती है।
gh-issues
394kयह आपके एजेंट को GitHub issues खोजने, उनमें से काम करने लायक चुनने, और सुधार के साथ pull requests खोलने में मदद करती है, जिसमें समीक्षा टिप्पणियों का फ़ॉलो-अप भी शामिल है।