- Advanced Infrastructure Penetration Testing
- Chiheb Chebbi
- 247字
- 2021-06-24 19:12:58
Linux commands
In this subsection, let's open the command line and execute some basic commands. In every Linux host, there are command-line interfaces named shells that interpret and execute typed commands and scripts. There are many shell environments, such as Bourne Again Shell (Bash, which is the most common shell), C shell (csh), Korn shell (ksh), and so on. To find the shells available for your environment, just open the command-line interface and type cat /etc/shells:

Now, let's get around some vital basic Linux commands from the shell:
- pwd: To know which directory you are in
- ls: To list files in a directory
- cd: To enter a directory
- mkdir: To create a new directory
- rmdir: To remove a directory
- touch: To create a new file
- cat: To read a file
- cp: To copy a file
- mv: To move a file
- man: To be shown how to use a command
Linux is case-sensitive (to give users many command option possibilities -T, - t, -a, - A, and so on), so you need to check how you are writing every command.
As a penetration tester, there are multiple important commands that you need to know in order to test the security posture of a Linux infrastructure:
- hostname: Information about the host
- cat /proc/version: Kernel information
- uname -r: Kernel release
- uname -a: More detailed information about the system
- cat /proc/cpuinfo: Reads information about the processor
- echo $PATH: Display information about the PATH variable
- history: Display command history
推薦閱讀
- 電腦組裝與系統安裝
- 從零開始寫Linux內核:一書學透核心原理與實現
- Linux從零開始學(視頻教學版)
- Persistence in PHP with the Doctrine ORM
- SharePoint 2013 WCM Advanced Cookbook
- Python基礎教程(第3版)
- 網絡操作系統教程:Windows Server 2016管理與配置
- 巧學活用Windows 7
- Linux內核設計的藝術:圖解Linux操作系統架構設計與實現原理
- VMware Horizon View Essentials
- Windows 8實戰從入門到精通(超值版)
- Kali Linux高級滲透測試(原書第3版)
- 從實踐中學習Windows滲透測試
- iOS 10快速開發:18天零基礎開發一個商業應用
- Raspberry Pi入門指南