Enumeration

First Phase of any pen-testing involves enumeration.

Linux enumeration involves getting as much information as possible like hostname, linux version, release, user accounts, check the privilege of the user accounts, sudo permissions etc,

Command
Function

uname -a

Displays the kernel information and other information related to linux

hostname

Displays the hostname of the system

cat /etc/issue

Displays the linux issue version

cat /proc/version

Looking at /proc/version may give you information on the kernel version and additional data such as whether a compiler (e.g. GCC) is installed.

cat /etc/passwd

If the user has access then it will show the users present in the linux system.

sudo -l

The sudo -l command can be used to list all commands your user can run using sudo.

env

The env command will show environmental variables.

id

The id command will provide a general overview of the user’s privilege level and group memberships.

history

shows all the commands entered in the shell.

ifconfig or ip a

shows the ip add of the various interfaces

find / -perm -u=s -type f 2>/dev/null

shows the SUID files

If you have all this info then you are pretty much good to proceed to next page,

Last updated