Environment Enum
Basic commands
whoami- what user are we running asid- what groups does our user belong to?hostname- what is the server named. can we gather anything from the naming convention?ifconfigorip -a- what subnet did we land in, does the host have additional NICs in other subnets?sudo -l- can our user run anything with sudo (as another user as root) without needing a password? This can sometimes be the easiest win and we can do something likesudo suand drop right into a root shell.
Tools
ToolsOperating System and Version
cat /etc/os-release
NAME="Ubuntu"
VERSION="20.04.4 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.4 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focalCurrent user's PATH
Path AbuseEnvironment variables
Kernel version
Kernel ExploitsCPU type/version
Shell availables
Defense in place
Some things to look for include:
Drives and shares
Printers attached
Mounted drives
Routing tables
route or netstat -rn
Internal DNS
/etc/resolv.conf
ARP Table
Existing Users
Hashes/etc/passwd & /etc/shadowExisting Groups
Members of interesting group
Home
Look for .bash_history, ssk keys, config files, etc.
Credentials HuntingMounted File Systems
Unmounted File Systems
All Hidden Files
All Hidden Directories
Temporary Files
Last updated