SSH 22
Checklist
Check for SSH version vulnerabilities
User enumeration possibilities
Verify if host keys match other systems
Test if password login is enabled (prompts for a password)
nmap -sV --script=ssh-hostkey -p22 10.10.10.10
Bruteforce if necessary with CeWL, Hydra, Patator, Crowbar
Commands and Tools
Banner Grabbing:
Nmap SSH Scripts:
Key Scanning:
Brute Forcing
Hydra Brute Force:
Good password lists:
NCRACK:
Private Keys
Using Found Private Keys:
Generate Private Keys:
System Administration
Check SSH Status:
Start/Stop/Restart SSH Server:
Verify SSH Process and Ports:
Metasploit Modules
Enumerate Users:
Exploitation
SSH Log Poisoning (Requires RCE Vulnerability):
Log injection:
Injected URL:
Remote Code Execution (RCE) via Username:
Escape Restricted Shell (Rbash):
Vulnerable Versions
OpenSSH < 7.7 (CVE-2018-15473):
Enumerate usernames:
Additional Notes
Forcing Specific Authentication Method:
Analyze Debug Output:
Last updated