General

  • To find stuff in Windows and Linux

dir *flag*.* /s
Grep -rnw /path/to/look  -e /file/to/look
find / 2>/dev/null | grep user.txt
find / -group admin -type f 2>/dev/null

grep -ri "password" /path/to/folder
findstr /s /i /n "password" *.*
  • find which programs have SUID of at least 4000

find / -perm /4000 -print 2>/dev/null
find / -perm /4000 -exec ls -l {} \; 2>/dev/null
find / -perm -u=s -type f 2>/dev/null
find / -type f -perm -04000 -ls 2>/dev/null
  • Upgrade shell

# Spawn a TTY shell
python3 -c 'import pty; pty.spawn("/bin/bash")'

# Suspend shell (Ctrl+Z), then on your local machine:
stty raw -echo; fg

# Back in remote shell:
export TERM=xterm

# Adjust to your terminal size
stty rows <rows> cols <cols>
  • To give bin/bash shell

  • C/C++ code for the shell (Linux)

  • for installing anything in python env

  • custom wordlist

  • Download on Windows if wget is not working

  • Ping sweep

  • Port scan

  • network

  • Whatweb

  • Banner Grabbing / Web Server Headers

  • krb5.conf template

  • Set default_realm to the one you're targeting (e.g., MIRAGE.HTB)

  • Use the correct FQDN (dc01.mirage.htb) as KDC and admin_server

  • WAF check

Last updated