How iamarit/hunter works
Project type and purpose
• Type: Standalone command‐line utility (open‐source tool)
• Purpose: Automate password brute‐forcing over FTP and SSH
File structure
• Top level:
• hunter.py – the main script containing all logic
• requirements.txt – external dependencies (e.g., paramiko for SSH)
• README.md, LICENSE
• No subdirectories: all functionality lives in hunter.py but can be logically broken out
Key insights from README
• Uses Python3 with minimal dependencies
• Accepts command‐line args (argparse) for service type, host, user, port, wordlist
• Supports two protocols: FTP and SSH
• Cross‐platform, lightweight
Main components
a. Command‑Line Interface (CLI) Layer
• Argument Parser (argparse)
• Help/Usage Display
b. Input Processing
• Validation of host, port, protocol, wordlist path
c. Brute‑Force Engine
• Wordlist Loader (reads file, streams or batches passwords)
• Connector Factory
• FTP Connector (wraps ftplib)
• SSH Connector (wraps paramiko or native SSH library)
• Attempt Loop
• For each password → call connector.attempt_login()
• Handles timeouts, exceptions, success/failure responses
d. Output & Logging
• Console Logger (prints progress, successes, failures)
• Optional File Logger (if extended)
e. External Service
• Target Host running FTP or SSH service
Relationships & interactions
• CLI → Input Processor → Brute‑Force Engine
• Engine → Wordlist Loader → yields passwords → Connector → Target Service
• Connector ←→ Target Service (network roundtrip)
• Engine → Logger → Console (and file if enabled)
Architectural patterns & principles
• Modular pipeline: separate parsing → engine → connecting → logging
• Factory pattern for protocol connectors
• Extensibility: easy to add new protocols by adding new Connector
Technologies & libraries
• Python 3.x
• argparse (CLI parsing)
• ftplib or socket (FTP)
• paramiko (SSH)
• logging or print statements
Essential elements
• Optional notes next to connectors: “uses paramiko,” “uses ftplib”