Introduction: Simple Folder Locker

Picture of Simple Folder Locker

Hey everybody,

In this Instructable, we will be making a simple batch file to hide private files, folders, etc. and keep family, friends and co-workers away.

Note: This does not work if someone is skilled in programing, but I plan to publish a more secure one in the future, probably my next Instructable.

This is part one of my current project of simple batch protection, I plan on expanding this and having other projects in the future.

Step 1: Setting Stuff Up

Picture of Setting Stuff Up

If you don't want to know how this works, THEN WHY ARE YOU READING THIS?!?!

You only need this first step to have it all set up if you download the finished script, but in the rest, I'll show how to write this code.

You will need to set some stuff up for this code to work, this version doesn't create the stuff you need.

1.) Create a folder called Blocked

2.) Open CMD (look for it in applications)

3.) Open Notepad x2, one is where the code will go and the other is your login info.

In one of the Notepads, type in your username Ex: Beta, the save it as yourpassword.upi Ex: Testing.upi and save it in Blocked.

In the CMD, type in the port ex. f:, then type attrib Blocked +s +h, this will hide the folder. Now you can close the CMD and the notepad with your user.

Step 2: Setting the Structure

Picture of Setting the Structure

In this step, we'll e adding some information and setting up the general structure of the code.

@echo off: We are blocking part of the display, so it won't show the code and will give it a cleaner look

color: We set the text and background color with this command, using "a" to signal that the text is light green.

title: Just the name.

: start/:open : This sets the beginning of a loop, a reference point where you can go back to the beginning of a part of the code if you call it with goto.

Step 3: Adding the Login and Opening Your Hidden Folder

Picture of Adding the Login and Opening Your Hidden Folder

Here we write the code as to create a login with the information that you put in the .upi file in the first step.

cls: clears the screen every time it appears, so you don't have more than one login at a time

echo: makes text appear on the screen

set...: creates a variable, in this case "/p" means text and the following word is the name.

%user%: the value of a variable.

set...=<: extracts a variable from a file.

if...: sets code to run only under certain conditions

ping localhost -n 2 > nul: a pause, it can last more or less if you change the number's value.

START : opens a file or folder.

exit: closes the system

Step 4: Save, Test and Grow

This is the easiest part, just save the code under .bat, and open it again to test it out.

If it doesn't work, double-check and leave a comment if it still doesn't work.

This is only a basic project, if you want to edit it, right-click and select edit.

From a part of the planet, enjoy,

Hackabot

Comments

Swansong (author)2017-08-16

Thanks for sharing :)

Hackabot (author)Swansong2017-08-25

My pleasure, there's more coming

About This Instructable

39views

0favorites

License:

More by Hackabot:Simple Folder Locker
Add instructable to: