Quote:
Originally Posted by Syphilis
If you have the file overwritten, it can't be recovered, and nothing will show up if you search for undeleted files, because it doesn't exist, and it's been overwritten by random data.
|
I used DiskDigger to search my hard drive after testing my batch script on a text file. I just typed a Hello World message in the text file, deleted it using the script, and tried to recover it with this software. The file is there, but the data is gone. It has been replaced with some meaningless random numbers.
If you want to try this yourself I can post my batch script on here. Try it with several recovery programs. I haven't found a single program that has been able to recover the original data.
The batch script for overwriting and deleting a file is:
Code:
echo off
echo %random%%random%%random%%random%%random% > %1%
del %1%
All you have to do is open command prompt, navigate to where you have this batch script saved at and type
mybatch.bat
filename
Press ENTER and it is gone. Try to recover it with any software you want. Oh and by the way, this simple script will not accept wildcard characters.
This is because the script uses the same filename to create a new file, and if you used a wildcard like *.txt, it will try to create *.txt which is obviously not valid.
But I hope to improve this script so it can delete multiple files on a wildcard parameter. The only way I can think of for this to be possible is if the batch uses the dir operation, stores the filename list in a textfile, and overwrites/deletes every file in the list from top to bottom, then overwrites/deletes the temporary file list.