Revolutionizing The Job Market - NxtWave - PDF (Kali Commands)
Revolutionizing The Job Market - NxtWave - PDF (Kali Commands)
To print the current working directory(folder) you are in, use pwd command.
1 pwd
To view the files present in a directory (also called contents of a directory), use ls command.
1 ls
Syntax:
cd <directory path>
1 cd /home/kali/Desktop/
1 cd ..
To find the manual on how to use a particular command/tool, use man command.
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 1/7
2/25/24, 11:39 PM Revolutionizing the Job Market | NxtWave
Syntax:
man <command name>
1 man ls
Note: Press
q to Quit
Users
To shift from normal user to the root(admin) user, use sudo command.
1 sudo su
To see the current user logged into the system, use whoami command.
1 whoami
To find out user and group information (such as names and numeric IDs (UID or group ID) of the current user or any other user in the system, use id command.
1 id
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 2/7
2/25/24, 11:39 PM Revolutionizing the Job Market | NxtWave
Syntax:
mkdir <directory name>
1 mkdir testdirectory
To copy the contents of a file to another file or to copy the file into a directory, use cp command.
Syntax:
cp source_file destination_file
1 cp /usr/share/wordlists/fastrack.txt mylist.txt
2 cp /usr/share/metasploit-framework/data/wordlists/unix_users.txt users.txt
Syntax:
cp src_file src_file2 dest_directory
Syntax:
mv src_file dest_file
1 mv mylist.txt newlist.txt
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 3/7
2/25/24, 11:39 PM Revolutionizing the Job Market | NxtWave
y
Syntax:
mv src_file dest_directory
1 mv users.txt testdirectory/
Syntax:
rm <filename>
1 rm testdirectory/users.txt
Syntax:
locate <filename>
1 locate wordlists
To find files and directories and perform subsequent operations on them, use find command.
Syntax:
find [directory to search] -name <filename>
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 4/7
2/25/24, 11:39 PM Revolutionizing the Job Market | NxtWave
Syntax:
cat <filename>
1 cat newlist.txt
To make small changes to an existing file or to write to a new text file, use nano command.
Syntax:
nano <filename>
1 nano newlist.txt
Note: Press
CTRL + X to exit and then press Y to Save and N to Not Save.
To search a file for a particular pattern of characters, and displays all lines that contain that pattern, use grep command.
Syntax:
grep 'pattern' <filename>
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 5/7
2/25/24, 11:39 PM Revolutionizing the Job Market | NxtWave
Stopping a Command
1 Press CTRL + C
Web
Downloading Files
www.whatismyipaddress.com
To download the files from the web via command line(from web servers using HTTP, HTTPS and FTP protocols), use wget command.
Syntax:
wget <link to the file>
1 wget https://download.virtualbox.org/virtualbox/6.1.18/Oracle_VM_VirtualBox_Extension_Pack-6.1.18.vbox-extpack
Syntax:
curl <link to the file> --output <specify filename>
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 6/7
2/25/24, 11:39 PM Revolutionizing the Job Market | NxtWave
Network
To display current network configuration information such as IP Address, MAC Address, use ifconfig command.
1 ifconfig
To check the network connectivity between host and server/host, use the ping command.
Syntax:
ping <IP address or URL>
https://learning.ccbp.in/course?c_id=8185622d-17a1-4f7a-9439-c3004f499db2&t_id=39ede1f3-cb3e-4b99-aa03-6e45557443ef&s_id=0b974725-d453-4583-880b-3d7815b9e9a1 7/7