Perm File Deletion

dapanther

Member
Joined
Dec 30, 2004
Messages
10
Hi Everyone,
I just wanted to know if anyone had a snip or two of code to handle file deletion. Now before you give me a object.delete() call or something, I am referring to a more perm delete something along the lines of DOD specs.

I was thinking that if I created a random number generator function and use that to generate the data to fill the file and then a function to read the file and populate it with the garbage data. Then rename the file using the same number generator so that the filename changes.

Is this basically what I need to achieve so that the file would be alot harder to recover? Or is there more to it than this?

Another way I was thinking was to write something in assembler that would just change the memory location, but I thought that would in essence though still leave the remenants of the file out there.

Any ideas?

Dapanther...
 
The DoD standard for non TOP SECRET docs is to overwrite the file with a single char, the overwrite it again with that chars compliment then to overwrite it with random data. The best you can do with a file name is to change it a number of times. The standard is to replace all non .s in the name with As then Bs and so 26 times. e.g. foo.txt becomes AAA.AAA

This works great on FAT32 and normal files on NTFS, but if the NTFS file is compressed or encrypted then it will not work. When you overwrite a compressed or encrypted file new blocks are allocated and the old contents remain. SO... The only way to deal with compressed or encrypted files is to use the win32 defragmentation API function to get the clusters belonging to the file and have raw access to overwrite them.
 
Useful utility?

Im not sure about coding a secure file deletion class, but there are products that can do secure file deletion and other stuff for you.

My favorite text editor prior to Visual Studio IDE editor is UltraEdit. They have just announced a new product that you may be interested in. Text of their email announcement to me is shown below:

Dear Valued Customer,

This email is only being sent to those that registered with us
for product information regarding UltraEdit, UltraCompare and
other IDM products. To unsubscribe from this list please go to
the following link and unsubscribe under the "Mailing List"
topic:

http://www.ultraedit.com/index.php

IDM is pleased to announce the commercial release of the latest
addition to the "Ultra" family of software products.

UltraSentry v1.00

UltraSentry is a highly advanced military-grade disk registry
cleaner that has on-board, fully configurable security profiles
that can run on demand, as scheduled or upon event. UltraSentry
goes beyond the standard secure file deletion utilities to
provide flexibility, scheduling and much more.

As you would expect from IDM, UltraSentry is built for expansion,
is fully configurable and offers a robust initial feature set
with an emphasis on user friendliness and automation.

At the core of UltraSentry is a military-grade disk cleaner that
exceeds DoD standards for data eradication and offers fully
configurable security profiles that can run on demand, as
scheduled or upon event.

Set the native profiles (Total System Scrub, Log-off Clean up,
& Privacy Guard) to completely erase not only your browser
history, but the registry entries, swap file, and free disc
space that can point back to your recently used documents,
search history, and deleted email.

Click here for a Standard Feature review and profile description:

http://www.ultraedit.com/index.php?name=Content&pa=showpage&pid=71

Advanced Security Capabilities:

UltraSentry stops Software Recovery Tools that recover your
previously deleted items (Exceeds US DOD 5220.22 standards);
UltraSentry destroys Slack Files, Wipes Free Space, and more with
multiple easy-to-use custom-erase methods.

UltraSentry Removes traces of your Internet activity beyond
recovery (cookies, cache, history, email etc.). You can
specify files, folders etc. to erase your P2P shared files
folders content beyond recovery too! Destroy "locked"
Windows files (swap, page, index.dat, etc.) that contain
personal data.

UltraSentry even provides secure deletion upon demand via right
mouse click in explorer by default!

Click here to download our free trial:

http://www.ultraedit.com/index.php?name=Downloads&d_op=viewdownload&cid=12

Be sure not to miss out on the limited time introductory price of
UltraSentry! Save 15%

Special announcement for UltraEdit users: IDM is pleased to
announce the upcoming release of UltraEdit v11.00. Check
http://www.ultraedit.com/ in February to see what we consider to
be the next generation of the worlds best text and programmers
editor. We are certain you will be pleased!

UltraCompare v2.00 was released Oct 04. Click below to get your
free upgrade or learn more:

http://www.ultraedit.com/index.php?name=Content&pa=showpage&pid=34

Want to save 25% on our already value priced software? Checkout
our powerful shareware combinations in our newly released
shopping cart. Bundle savings are as much as 25%. To learn more.
http://www.ultraedit.com/store/customer/home.php

- Get the latest news from IDM: http://www.ultraedit.com/index.php?name=Topics

Thanks again for your continued support and feedback.
Sincerely,

Ian D. Mead
IDM Computer Solutions, Inc.
www.UltraEdit.com
 

Similar threads

T
Replies
0
Views
567
This_display_name_is_already_in_use_They_all_are
T
A
Replies
0
Views
784
ananda vardhana
A
F
Replies
0
Views
563
F_M_L
F
Back
Top