Jump to content

Secure deletition

Featured Replies

Hello forum, I'm trying to create a program that will securily delete a file, as you know, even if you delete a file (be it manually or through a program with the remove() function) the file always stays there until its deleted by something written over it.

 

My question is, anyone has any idea of how could you securely delete a file?

 

I have thought of for example first using <fstream> to overwrite the file (suppose a .txt file, change all whats written on it converted to 0's) and then finally using remove()

 

Is this method secure enough? What could I use?

 

Thanks for the help

What you're suggesting should be quite safe. One way that people who want to erase their whole hard drives does it is overwrite the whole thing with ones, then with zeros (simply put), which totally wipes out everything on it. From what I read back then though, there is still traces of magnetism that makes it possible to find out what's been on it. EVEN if you've overwritten it with something else. Then there's also problems with write caches etc. On the site of Eraser, they describe all of these problems. Since I can't really help more than that, I suggest you look at the source code of it, see how they did it.

 

http://eraser.svn.sourceforge.net/viewvc/eraser/

 

AFAIK when you overwrite a track the read/write head is never exactly in alignment as it was previously written so there is always a trace that can be forensically read with the right equipment. With this in mind a track has to be overwritten at least 8 or 10 times to cover the desired area before forensic services (using them as the benchmark) in normal cases will give up but I have read if they really wanted any information that badly they can still get it. HD destruction is the only foolproof secure deletion technique.

Edited by StringJunky

There are software called Wipers, those software write over unused data in a harddisk, sometimes multiple passes for security

Archived

This topic is now archived and is closed to further replies.

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.