0

A couple years ago I locked away some important images/documents. I used this solution to hiding/locking them.

I made a text file and input the following text, and then renamed the file to "locker.bat" so that I could hide and unhide the folder by entering my password via the bat file.

cls
@ECHO OFF
title Folder Private
if EXIST "HTG Locker" goto UNLOCK
if NOT EXIST Private goto MDLOCKER
:CONFIRM
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 Private "HTG Locker"
attrib +h +s "HTG Locker"
echo Folder locked
goto End
:UNLOCK
echo Enter password to unlock folder
set/p "pass=>"
if NOT %pass%== PASSWORD_GOES_HERE goto FAIL
attrib -h -s "HTG Locker"
ren "HTG Locker" Private
echo Folder Unlocked successfully
goto End
:FAIL
echo Invalid password
goto end
:MDLOCKER
md Private
echo Private created successfully
goto End
:End 

Everything was fine until my PC started to cark it, and I've since backed everything up and built a new PC. However, now when I open the folder, all of the files are still there, It's taking up the same amount of space, but all of the images and files have a lock on it (as seen in the files attached.)

Is there any way at all of accessing these again? I assume this is an issue with encryption and permissions. I no longer have the old PC, but I just thought because it was a backup, that my new account would be able to access it too.

I've tried setting permissions and copying the files out of the folder onto another computer but it says i do not have permissions. I have tried sharing them but it will not allow me to do it.

Any help would be much appreciated! Have been dealing with this for a long time now.

EDIT: All "Authenticated Users", "SYSTEM", "Administrators", and "Users" have full control. Also, when trying to take ownership of a specific file that is locked, it says that the file could not be decrypted.

locked files image

6
  • If none of the answers on the duplicate help then please edit your question to say what you did and what happened then let me know this needs to be reopened.
    – Mokubai
    May 8, 2018 at 14:20
  • @Mokubai none of the answers on the duplicate are relevant. They do not provide a solution to my problem.
    – Hentendo
    May 8, 2018 at 14:29
  • Then edit your question detailing what happened. I've reopened it, but without you telling us what you did and why the solutions on that question did not work there is nothing to stop someone else marking it as a duplicate again.
    – Mokubai
    May 8, 2018 at 14:51
  • @Hentendo - I would need the Access Control information on one of the files to determine the best method to reverse the process. Please edit your question to include this information.
    – Ramhound
    May 8, 2018 at 15:10
  • @Ramhound thanks for commenting. How do i get that for you?
    – Hentendo
    May 8, 2018 at 15:12

1 Answer 1

0

Is there any way at all of accessing these again?

Your files are encrypted, by a certificate that only exists within user profile's certificate store, on your old installation. Unless you exported this certificate the files cannot be recovered.

I assume this is an issue with encryption and permissions. I no longer have the old PC, but I just thought because it was a backup, that my new account would be able to access it too.

The script you used does not encrypt the files. The password you configured does absolutely nothing to protect the files, it only is used within the script, which does nothing but hides and unhides the files within the directory.

It's taking up the same amount of space, but all of the images and files have a lock on it (as seen in the files attached.)

The files were encrypted by a feature called Encrypted File System when this was done, a certificate was generated. If you don't have the certificate, then your files, cannot be recovered.

I made a text file and input the following text, and then renamed the file to "locker.bat" so that I could hide and unhide the folder by entering my password via the bat file.

I feel like I need to clarify something. The script in question does absolutely nothing significant. Changing the attributes of a file and folder is trivial to reverse. The existence of said folder would be obvious to any experienced Windows user who had physical access to your machine. If you want to protect your data you should be using VeraCrypt or BitLocker. If you are going to be use encryption, you need to make sure, your backup plan includes the information to decrypt the files.

If you did not backup the certificate, then the certificate can't be exported, in its current state. This means the files cannot be decrypted.

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .