Some Linux commands frequently used in Capture The Flag (CTF) competitions and Linux:
ls: Lists directory contents. Competitors use this command to access important information on servers or file systems.
cd: Allows you to navigate between directories.
pwd: Shows which directory you are currently in.
mkdir: Creates new directories.
rm: Deletes files or directories.
cp: Copies files or directories.
mv: Moves or renames files or directories.
touch: Creates new files or updates file timestamps.
cat: Displays or concatenates the contents of files. Used to open hidden flags or ciphertexts.
grep: Searches for a specific text or pattern in text files. Flags or clues can be found this way.
nano or vi: Text editors help you edit text files.
chmod: Changes permissions of files and directories.
chown: Changes owners and groups of files and directories.
ps: Lists running processes.
kill: Kills a process.
ifconfig or ip: Views or sets the network configuration.
ping: Checks network connectivity by sending packets to a remote server.
ssh: Allows you to connect securely to remote servers. Used in CTFs to access confidential information.
scp: Copies files to or retrieves files from remote servers.
tar: Used to compress or extract files and directories. It is important for examining compressed files and accessing their contents.
df: Displays disk usage.
free: Displays memory usage.
top or htop: Monitors system resources live.
find: Searches for files or directories. It is mainly used to find hidden or compressed files.
history: Displays the history of commands used.
sudo: Runs commands with root (administrator) privileges.
man: Displays help pages about commands.
date: Displays or sets the system time and date.
netcat (nc): Used to establish network connections and exchange data. It is frequently used in CTFs to establish connections over ports.
ncat: It is a strengthened version of netcat and offers more features.
wget or curl: Used to download files over the Internet. It is often used to retrieve data from web pages or servers.
base64: Used to decode or encode Base64. It is frequently used to decrypt texts or files.
hexdump or xxd: Used to display data in hexadecimal format. It is important for analyzing encrypted data.
file: Used to determine the file type. It is especially useful for identifying unknown file types.
strings: Shows the readable texts in the file. It is used to find hidden messages or passwords.
zip and unzip: Compresses and extracts files. Used to access compressed file formats frequently used in CTFs.
They are used to perform tasks frequently encountered in CTF competitions. However, in CTFs, each mission can be different and require different commands or skills. Therefore, it can be useful to learn various Linux commands and tools.
