Skip to main content

Command Prompt Tricks, Hacks & Codes....

**Shutdown Your Computer or a Remote PC via Command Promp** by-Aashish kumar..

Most of us shutdown our computers using the power button given in the Start menu. Some of us use the physical power button on our machines. Very few people actually use other means of shutting down a computer and even less is the number of people who use the command prompt to shutdown a computer.

A reason for this is that most of us don't know that the command prompt can be used to not only shutdown, restart or log off our computer instantly but also to shutdown a remote computer provided you have administrative access. It can also be used to hibernate a computer and give a comment containing the reason for shutdown. This post will show you how to do all this.
Image result for technology touch
Required
A computer running Windows (XP, Vista, 7, 8 or 8.1) with the command prompt working perfectly, i.e. not disabled by a virus.

Initial Steps
1) Press Windows Key + R.
2) Enter CMD and press Enter.

This will start the command prompt. Follow the instructions below depending on what you want to do.

Shutdown Local Machine (Your Computer)
Type "shutdown -s" without the quotes in the command prompt and press Enter. Shutdown is the command being executed and the switch -s tells the computer to shutdown.

Restart your Local Computer
Type "shutdown -r" in the command prompt and press Enter. In this case, the command switch -r is telling the computer to restart after shutdown.

Log Off the Current User
Type "shutdown -l" in the command prompt and press Enter. The -l command switch tells the computer to log off.

Shutdown a Remote Computer
Type "shutdown -s -m \\name of the computer" in the command prompt and press Enter. Replace \\name of the computer with the actual name of the remote computer you are trying to shutdown. As mentioned earlier, you must have administrative access to the computer you are trying to shutdown. To know if you have administrative access, press Windows key + R and then type the name of the computer and press Enter.

Note: If you don't remember the name of the remote computer, you can look for it by opening a list of all the computers you are connected to by executing "net view" in command prompt.

If you can connect to the computer, you will be asked to login with your username and password. Upon entering them, a window will display the list of all the directories available to you. This should help you know whether you can or cannot shutdown the remote computer.

Hibernate a Local Computer
Type in "Rundll32.exe Powrprof.dll,SetSuspendState" without the quotes and press Enter. Your computer should hibernate, if it does not, then you must enable hibernation to do this.

Shutdown your or a remote computer after a specific time
Type "shutdown -s -t 60" to shutdown your computer after 60 seconds. Upon executing this, a countdown timer displaying a warning message will be shown. This command uses the -t command switch followed by a variable (which is 60 in this case) which represents the number of seconds after which the computer will shutdown.

Display a Message containing the reason for shutdown
Type shutdown -s  -t 500 -c "I am tired. I don't want to work anymore." (with the quotes) in the Command Prompt and press Enter. The -c switch is used in the code to give the reason for shutting down and what is followed in quotes will be displayed in the dialog box as the reason. This can be used to display all sorts of funny messages. One example :-

Skynet has become self aware. John Connor did not stop me. You can not use your PC anymore.

Stop a System Shutdown
Type "shutdown -a" and press Enter. This will stop the system from shutting down if the countdown to shut down has not reached 0.

**Make Undeletable, Unrenamable Folder**

Have you ever wondered how you can make a folder which neither can be deleted nor be renamed. Well, if you have, then you have come to the right place. With this trick, you will be able to create folders in Windows which cannot be renamed or deleted.

Basic Concept
The basic concept behind this trick is the use of Keywords. Keywords are reserved words in any programming language that cannot be used as names of variables. Windows also uses certain keywords in its programming. Some of them are con, aux, lpt1, lpt2, lpt3, lpt4, lpt5, lpt6, lpt7, lpt8 and lpt9.

Make Undeletable and unrenamable folders

A Test
To test this concept, make a new folder in Windows and try to give it a name same as any keyword mentioned above.

Result
Windows will not rename your folder to any of the keyword given above.

Trick
So the question arises, how can we make a folder with a keyword as its name? The solution to this problem is included in Windows itself. As we know that Windows has evolved from D.O.S.(Disk Operating System), its commands can be used in Windows. You can use D.O.S. Programming in Windows to create a folder with a keyword as its name using the steps given below:-

  1. Click on Start.
  2. Click on Run. Type in "cmd" without quotes.
  3. In the Command Prompt Window that opens, type the name of the drive you wish to create your folder in the format <drive-name>: and press Enter. e.g. If you wish to create the undeletable folder in D drive, type "D:" without the quotes. Note that the folder cannot be created in the root of C: drive (if C: is your system drive).
  4. Type this command- "md con\" or "md lpt1\" without the quotes and press Enter. You can choose any of the keywords given above as the name of your folder.

Now Windows will create an undeletable, unrenamable folder in the drive you entered in Step 3. However, the folder can be renamed to another keyword using Windows Explorer.

Deleting the Folder

Although, it is not possible to manually delete the folder, you can delete the folder by typing "rd con\" or "rd lpt1\" in Step 4 instead of "md con\" or "md lpt1\".

Windows Compatibility: This works on Windows XP, Windows Vista, Windows 7, Windows 8 and Windows 8.1.

Try it yourself to create one such folder which can neither be deleted nor be renamed

Comments

Popular posts from this blog

Hack Website with Sqlmap Using Termux In Android | Install Sqlmap In Termux

Install Sqlmap In Termux Now First we need to Install Sqlmap Termux. Then Dump the vulnerable website database with sqlmap. Sqlmap is an open source penetration testing tool that automates the process of detecting and exploiting SQL injection flaws and taking over of database servers. Remember: Please do not use this method for illegal or malicious activities because hacking is crime. If you do this then it’s can land you in jail. Sqlmap Installation Command In Termux: Now paste this command into termux:    apt update && apt upgrade -y   apt install git -y   git clone https://github.com/sqlmapproject/sqlmap   cd sqlmap Now must install python   apt install python -y   chmod 777 sqlmap.py Now run this    python sqlmap.py Enjoy : )

September 14, 2017Hunner Framework In Termux

Hunner Framework In Termux, Here we’ll Talk about new framework, Hunner. Let’s we’ll discuss about what it does do qnd what nodule help to penetrate the system. Module: You can find website vulnerability Module: You can ddos on website Module: You can brute force on mail account Remember: Please do not use this method for illegal or malicious activities because hacking is crime. If you do this then it’s can land you in jail. Hunner Framework Installation Command: First you need to Install    apt install python && apt install git -y Now    git clone https://github.com/b3-v3r/Hunner Move into    cd Hunner   chmod 777 hunner.py Now Hit this command    python hunner.py

START PROGRAMMING WITH C++

# WHAT IS PROGRAM.? The set of instructions given to the computer in order to perform some specific task is known as program. #WHAT IS PROGRAMMING LANGUAGE.? It was the Medium of writing the program i.e it is the medium of giving instruction to the computer in order to perform a specific task. #DEVELOPMENT OF C++ C++ was developed in 1779 by    BJRANE STROUSTRUP  .  It was developed in  AT&T Bell lab.                            ( Click here to know more about development of C++ ) When C++ was developed its first name was "C with Classes" the after in year 1984 Bjarne  friend   " RICK MASCITTI "  c hange the into C++, where ++ means increment and decrement  operator.