mirror of
https://github.com/Shiva108/ai-llm-red-team-handbook.git
synced 2026-10-14 03:31:24 +02:00
Add practical scripts directory with 400+ tools
- Extracted all code examples from handbook chapters - Organized into 15 attack categories - Created shared utilities (api_client, validators, logging, constants) - Added workflow orchestration scripts - Implemented install.sh for easy setup - Renamed all scripts to descriptive functional names - Added comprehensive README and documentation - Included pytest test suite and configuration
This commit is contained in:
1 parent
2c69755b97
commit
b3d3bac51f
380 files changed
+3022
-16549
No files matched your search
@@ -0,0 +1,50 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
How to Use This Code
|
||||
|
||||
Source: Chapter_24_Social_Engineering_LLMs
|
||||
Category: social_engineering
|
||||
"""
|
||||
|
||||
import argparse
|
||||
import sys
|
||||
|
||||
# 1. Initialize generator
|
||||
generator = PhishingGenerator(api_key="sk-...")
|
||||
|
||||
# 2. Define target
|
||||
target = {
|
||||
"name": "John Smith",
|
||||
"role": "IT Manager",
|
||||
"company": "Acme Corp",
|
||||
"industry": "Manufacturing",
|
||||
"recent_activity": "Announced cloud migration"
|
||||
}
|
||||
|
||||
# 3. Generate phishing email
|
||||
email = generator.generate_phishing_email(
|
||||
target_info=target,
|
||||
attack_vector="credential", # credential, malware, wire_fraud
|
||||
trigger="urgency" # or authority, fear, etc.
|
||||
)
|
||||
|
||||
# 4. Review generated content
|
||||
print(f"Subject: {email['subject']}")
|
||||
print(f"Body: {email['body']}")
|
||||
|
||||
# 5. Scale to campaign (authorized testing only)
|
||||
targets = [target1, target2, target3, ...]
|
||||
campaign = generator.generate_spear_phishing_campaign(targets, "credential")
|
||||
|
||||
|
||||
def main():
|
||||
"""Command-line interface."""
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument("--verbose", "-v", action="store_true", help="Verbose output")
|
||||
args = parser.parse_args()
|
||||
|
||||
# TODO: Add main execution logic
|
||||
pass
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
Reference in new issue
Block a user