LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 01-15-2005, 09:32 AM   #1
jonfa
Member
 
Registered: Mar 2001
Location: FL
Posts: 257

Rep: Reputation: 30
file wiper


Hi all,

I'm looking for a linux file wiper program to completely erase data from a harddrive. Anyone have any suggestions? Thanks
 
Old 01-15-2005, 10:49 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

Try shred, it's part of the coreutils so it should be on your box.

Hope this helps.
 
Old 01-15-2005, 10:56 AM   #3
jonfa
Member
 
Registered: Mar 2001
Location: FL
Posts: 257

Original Poster
Rep: Reputation: 30
Thanks for quick reply. I read the man pages on shred and it notes the following:

CAUTION: Note that shred relies on a very important assumption: that the filesystem overwrites data in place. This is the traditional way to do things, but many modern filesystem designs do not satisfy this assumption. The following are examples of filesystems on which shred is not effective:

* log-structured or journaled filesystems, such as those supplied with AIX and Solaris (and JFS, ReiserFS, XFS, Ext3, etc.)

* filesystems that write redundant data and carry on even if some writes fail, such as RAID-based filesystems

* filesystems that make snapshots, such as Network Appliance’s NFS server

* filesystems that cache in temporary locations, such as NFS version 3 clients

* compressed filesystems


I use a Ext3 filesystem on Fedora 3.

Last edited by jonfa; 01-15-2005 at 10:59 AM.
 
Old 01-15-2005, 11:19 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi again,

Reading the manpages is always a good thing

Almost posted the link for wipe, but this one also excludes ext3 (journaling) filesystems.

Maybe this one does work: http://sourceforge.net/projects/srm/

Did not see any warnings about journaling fs, but they could be in the manpage once you downloaded/installed it. Do be carefull.

Another thing:

Don't know why you need to do this and how often you have to do it. You might consider making (part of) your partitions encrypted and keep the data safe (well, 99,9% safe that is).
 
Old 01-15-2005, 12:27 PM   #5
Travers
Member
 
Registered: Jul 2004
Location: Des Moines
Distribution: Gentoo
Posts: 111

Rep: Reputation: 15
Well, if you're wiping the entire drive it dosen't matter if you are using a journaling file system, because the journal gets lambasted as well. If you are shreding specific files and not the entire drive with a journal, then you should be worried.

If the data on the drive is really sensitive, take the drive out, hit it with a sledgehammer and melt it. I'm serious. "Echos" of the data you once had on there still exists. Shred goes down 35 layers, so its genereally pretty secure. I think the FBI can go down 7 layers with special lab equipment. Play it safe and shred the hell out of it. Even shred cannot destroy bad sectors where data still resides. So, there is never 100% certainty that data is unrecoverable unless you heat that drive up past 1200 degrees farenheit for an extended period of time.
 
Old 01-15-2005, 12:49 PM   #6
jonfa
Member
 
Registered: Mar 2001
Location: FL
Posts: 257

Original Poster
Rep: Reputation: 30
I've downloaded srm and read through the man pages and it doesn't say anything about journaling filesystems. I don't want to destroy the harddrive, but simply be able to create a directory, which contains sensitive data, and destroy the directory if I need to. In Windows there is a proram called Ultrawipe that applies some DoD (Department of Defense) algorithm so the data is completely lost. I was looking for something similar for my linux box. Thanks for the help.
 
Old 01-15-2005, 02:48 PM   #7
tnandy
Member
 
Registered: Oct 2003
Location: Tennessee
Distribution: Devuan 3.0 (Beowulf)
Posts: 217

Rep: Reputation: 18
One of my favorite utilities is Darik's Boot and Nuke (http://dban.sourceforge.net/). It utterly destroys all data, partitions, whatever, on a hard drive, so if you want to be selective, DBAN is not applicable. You can set the number of random overwrites from 3 to 35. The best thing is, it fits on a bootable diskette. When it has finished cleaning the drive, it writes a report to the diskette.

When I rebuild a computer, I nuke the drives using the the (default) 3 times overwrite, which gives them a pretty thorough workout. I then test them using the manufacturer's software, generally available at the manufacturer's website. If they pass, I assume they are good as new.

I hope this helps.
 
Old 01-15-2005, 03:27 PM   #8
TJandE
LQ Newbie
 
Registered: Mar 2004
Location: Washington State, USA
Distribution: FreeBSD, RedHat, & AIX
Posts: 22

Rep: Reputation: 15
If you really just want a scratch directory to work on sensitive data only to wipe the contents out later, why not create a new partition that isn't ext3 and mount it specifically for this purpose?

Obviously there are better options (like making the partition encrypted), but this should do what you want.

Micah
 
Old 01-15-2005, 03:31 PM   #9
jonfa
Member
 
Registered: Mar 2001
Location: FL
Posts: 257

Original Poster
Rep: Reputation: 30
TJandE,

Good advice. Thank you. How do you make encrypted partitions and can this be done with the system already running or does this need to be done on a fresh install? Making and encrypted partition that is compatable with shred seems to be a good idea.
 
Old 01-15-2005, 03:49 PM   #10
TJandE
LQ Newbie
 
Registered: Mar 2004
Location: Washington State, USA
Distribution: FreeBSD, RedHat, & AIX
Posts: 22

Rep: Reputation: 15
I haven't personally needed an encrypted partition yet. http://encryptionhowto.sourceforge.net/ seems to have all the info for Linux distros. It appears to need a kernel patch or two, but that should be explained in the howto.

Micah
 
Old 01-16-2005, 03:18 AM   #11
drhonez
LQ Newbie
 
Registered: Sep 2004
Posts: 3

Rep: Reputation: 0
try BCWIPE you can wipe entire filesystems off devices with a 35-pass write of random data or you can specify the number of passes your self. The 7-pass option is what the Department of Defense says is standard for securely wiping info from a harddrive.
It's free and you can get it thru a google search. its like 24kb.

Hey, I like it, it rules!
like: bcwipe -md /dev/hd* or /dev/sd*

md is the 7pass DoD statndard or mg is peter Gutmanns 35-pass wipe.

check it out
 
Old 01-16-2005, 09:28 AM   #12
bgrundy
LQ Newbie
 
Registered: Jan 2005
Posts: 2

Rep: Reputation: 0
Quote:
Originally posted by Travers
If the data on the drive is really sensitive, take the drive out, hit it with a sledgehammer and melt it. I'm serious. "Echos" of the data you once had on there still exists. Shred goes down 35 layers, so its genereally pretty secure. I think the FBI can go down 7 layers with special lab equipment.
This may have been true a couple of years ago, but not any more. If the info is classified, then by all means, do a DoD spec wipe (although it won't declassify the drive). You really don't need to do DOD spec wipes on the drives you are giving away or retiring unless you are afraid a hostile government will get ahold of them AND they might suspect there is useful classified data on them AND they could afford to spend the time and money doing a microscopic magnetic recovery. If it's just credit card files / pr0n, or your companies IP, etc. Then no one will bother if the drives are simply zero'd.

If the FBI needed to "go down 7 layers", they would call the NSA who MIGHT be able to do this. But only for a *real* good reason, and if it was worth the months of man hours and millions of dollars. With the current density on newer disks, this sort of thing has become nearly impossible.

Read this paper. And be sure to pay attention to the Epilouge.

bg
 
Old 01-17-2005, 12:26 AM   #13
Travers
Member
 
Registered: Jul 2004
Location: Des Moines
Distribution: Gentoo
Posts: 111

Rep: Reputation: 15
Hey man, secuirty is about paranoia. The best network secuity guys have paranoid schizophrenia. When you think the coffee maker is out to get you, then you make sure the network is damned secure. =)
 
Old 01-17-2005, 07:54 AM   #14
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE Tumbleweed-KDE, Mint 21, MX-21, Manjaro
Posts: 4,629

Rep: Reputation: Disabled
There is an option for mount, something like "-nosync", which switches of buffering thus enforcing imediate writes to the hd. Might also be a good idea to use (possibly also in /etc/fstab) e.g. for the cases where your directory-(content) is smaller than the buffer...
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to read .chm file in fedora, can't mount ntfs file system ishti_du Linux - Newbie 12 03-06-2007 03:27 AM
forrtl: severe (47): write to READONLY file, unit 5, file /dev/pts/1 terrence Programming 1 10-01-2005 10:22 PM
gave wrong syntax for tar as tar -cvzf file file.tgz how to recover the file gautham Linux - General 4 04-13-2005 03:15 AM
Yum update complains missing file (broken dep), but file can be located. davidas Linux - Software 0 03-27-2004 09:11 PM
How to play a media file/ video file/mp3 file recorded in harddisk/cd-rom arindam Linux - Newbie 2 09-05-2003 10:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 06:33 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration