Directory navigation and manipulation
In this section, you’ll learn the layout of the Linux filesystem directories, the purpose of common directories, and how to navigate your way around the system. By the end of this section, you should be comfortable with the location and design decisions of the filesystem and will be using common Bash commands to navigate it like a pro.
Filesystem design and hierarchy
At the heart of Bash file management is an understanding of the filesystem hierarchy. Here, we’ll review the various filesystem directories and their purpose. We’ll also review particular directories of interest to pentest. This will enable you to be confident as you navigate your filesystem.
Imagine the filesystem as a tree with branches spreading out from the trunk.
Using the tree
command, you can find a high-level overview of the filesystem, as shown in the following figure:
Figure 2.5 – An overview of the filesystem...