Sunday, October 28, 2012

Create your own folder locker with right click option

You might have come across batch programming folder locker which is a old trick.... but here im using same concept modified it n extend its capabilities.....  you have to copy past everything in locker folder to hide files.... why dont there is a option. such that right click on any folder or file and send to locker..... you can make that too... all files are in a zip below if you dont want to mess with....



first open any text editor, notepad++ or notepad....
copy n past below code in it


cls
@ECHO OFF
title Folder locker
if EXIST "locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}" goto UNLOCK
if NOT EXIST lol goto MDLOCKER
:CONFIRM
echo.
echo.
echo ---------------------------------------------------------
echo              FOLDER LOCKER BY AKASH
echo ---------------------------------------------------------
echo.
echo      Are you sure you 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 lol "locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
attrib +h +s "locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
echo Folder locked
goto End
:UNLOCK
echo.
echo.
echo ---------------------------------------------------------
echo              FOLDER LOCKER BY AKASH
echo ---------------------------------------------------------
echo.
echo      Enter password to unlock folder
echo.
set/p "pass="
if NOT %pass%==password goto FAIL
attrib -h -s "locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
ren "locker.{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


change password with your own password...... save it as anything.bat see other post for how to save as bat file.... if you are such a noob....  just run bat it will create locker folder... Dont change anything else even folder name....

now the trick part, by meee :)
make another bat file with following code.... save it as mvlock.bat  and put it in the same folder where locker bat ids located


@echo off
attrib -h -s "C:\#\locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
ren "C:\#\locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}" locker
move %1 C:\#\locker
ren "C:\#\locker" locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}
attrib +h +s "C:\#\locker.{21EC2020-3AEA-1069-A2DD-08002B30309D}"


Change # with your file path where locker bat file is present.....

now goto start search "regedit.exe" open it.... MAKE A BACKUP IN CASE IN FILE> EXPORT....
open HKEY_CLASSES-ROOT > * > shell > (right click on shell new > key )
rename key as you wish.... it will be displayed on right clcik...  like "send to Locker".... right click on it new > key rename it as "command"... openimg same command folder... on the right side you will see "(Default)"
open it, you will see edit string... past below code in value data..

"C:\#\mvlock.bat" "%1"

again change # with your path..... click ok.... Done....



you will see on right  send to locker option for all files.....
to make this for folders edit  HKEY_CLASSES-ROOT > Directory > shell > in same way....


all filess in a zip.... just need to "edit mvlock" file path n registry.... follow regedit steps....



You are done.... :) bookmark,share,like this blog, for other cool stuffs from mee...
comment here if you have any doubts......






2 comments:

  1. Hello Mr.Akash Hiremath The batch file we have created can be viewed by right click --> Edit option and our stored password can be viewed by anyone is there any secured way to keep our code and password safe???

    ReplyDelete
    Replies
    1. you can convert your batch(.bat) file in to an executable (.exe) file by batch to exe converter.

      Delete