Password usage on computer devices has been a common trend for so long now. Many people consider this extra security measure vital. Whether you consider it sensitive information or you are just trying to keep people away from your personal files, password protecting your folders becomes necessary and is possible.
As much as your files are already safe on your PC, discarding malicious intent is never a bad thing. After all, every information in your computer belongs to you and some might not be for the viewing pleasure of other people. This article will introduce the Batch Method for securing data on Windows computers.
The way Windows works to protect files once you have a password to work with is by encrypting your files in a virtual vault kind of sense. While the method described here may seem for techy’s and programmers, it is actually for everyone. A direct following of the carefully laid out instructions will make you learn a very cool trick. A trick to make you feel really cool about yourself, if you can pull it off.
HOW TO USE THE BATCH FILE METHOD TO SECURE YOU DATA AND INFORMATION BY PASSWORD
- Navigate to the folder you intend on locking.
- Create a new folder within the window (To be used as a virtual drive) and name it Safe.
- Double-click on the Safe folder (This is the directory your .bat file will be created in to store your locked folder).
- Right-click on empty space within the Safe folder, go to New, select Text Document.
- Within the Text Document you have created, copy and paste the following code:
cls
@ECHO OFF
title Folder Locker
if EXIST "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" goto UNLOCK
if NOT EXIST Locker goto MDLOCKER
:CONFIRM
echo Are you sure u want to Lock the folder(Y/N)
set/p "cho=>"
if %cho%==Y goto LOCK
if %cho%==y goto LOCK
if %cho%==n goto END
if %cho%==N goto END
echo Invalid choice.
goto CONFIRM
:LOCK
ren Locker "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
attrib +h +s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
echo Folder locked
goto End
:UNLOCK
echo Enter password to Unlock folder
set/p "pass=>"
if NOT %pass%==your_password goto FAIL
attrib -h -s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
ren "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" Locker
echo Folder Unlocked successfully
goto End
:FAIL
echo Invalid password
goto end
:MDLOCKER
md Locker
echo Locker created successfully
goto End
:End
- Set your password by locating the
if NOT %pass%==your_password goto FAIL line of code.
- Change the “your_password” part to your desired password.
- After creating your password, go to File, select Save As within the Text Document.
- Rename the text document to locker and add a .bat extension to your file. E.g. locker.bat. Click Save.
- Close window.
Double-click the locker.bat file you just saved. At this point, you should have a folder with a file named locker.bat.
Put all the files you want to protect inside the folder.
Double-click the locker.bat file again.
A command prompt window will open to ask if you want to lock your folder.
Input Y from your keyboard and press the Enter key.
Your folder should disappear.
To access your files again, double-click the locker.bat file.
You will receive a prompt to enter the password you created.
If the password is correct, you should be able to see your files again.
Congratulations to the people that properly followed the instruction. For those new to this sphere of computing, I trust it seemed like magic? I promised you it will be cool. Enjoy your foray in data secerecy, hoping your dealings are mostly legal though.