Thursday, October 2, 2008

Folder Lock

This is a simple hand written prog ,, you can use to hide your data quite efficiently(in windows ,,except vista)

Copy the following program :

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
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%== 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
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>





now go for following few steps

* copy above program into notepad.
* the text which is written in bold letters delete it & type your password there.
* save that file by extension .bat ( name is Your choice)
* now on Your screen there is a bat file appear.
* Copy the file where you want to save your data.
* double click on that file.
* you will see the locker folder.
* save the files in that folder(e.g. Copy paste files into it).
* double click on .bat file & lock that folder
* after locking that folder it will become hidden.
* to open that folder double click on that bat file.
* type your password & open that folder..


Explanation of this prog is simple.
This prog changes the attribute of locker folder by 'h' and 's' switches of attrib command
(type attrib /? in cmd)
+h will add hidden attribute ,, but that's not all ,, it will add the +s attribute to make it a system file and most important rename it as "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" ,, 21EC2020-3AEA-1069-A2DD-08002B30309D is system ID of control panel ,, so even if someone is very smart and trying to access that hidden locker folder ,, it will be redirected to control panel :)
( these ID's can be found under the [HKEY_CLASSES_ROOT\CLSID] key ,, if you know what regedit.exe is)



some drawbacks

1. As file is editable ,, anybody can change ,, so convert it into executable by any software available on net.
2. Folder can still be copied ,, deleted bt cannot be accessed


Any further suggestion (+ve or -ve) are welcome