Page 1 of 1
Napalm v.7 Alpha
Posted: Mon Sep 01, 2008 12:10 am
by chezzestix
I may seem a little ADD starting this project only a couple days after starting hungry dots but it has some signifigance I swear.
Napalm:
This program is for when your HDD or FDD needs a REALLY good cleaning because nothing cleans better than Napalm. Not a single trace of any data will be left on your media when this program gets through with it.
What it does:
It may not be the most efficient way to clean a drive but what the program does is literally goes through and fills the whole disk with 00s ignoring any special formatting. Wiping every single bit clean of any trace of data.
The Reason:
I was asked if I could and its giving me valuable practice with FDD and HDD I/O which I'm going to need for Hungry dots. That and this program I have broken the 512 barrier.
What needs to get done before v1.0:
+HDD wiping (Don't try to choose a fixed disk, I'm yet to program that part of it but you can clean a disk)
+Progress Bar
+Possibly an ASCII art spash
+possibly support for other FDD than 3.25" 1.44 MB
Known Bugs:
VirtualBox reports wrong number of fixed disks (I dont much care though since it works fine on my hardware)
Re: Napalm v.45 Alpha
Posted: Mon Sep 01, 2008 1:54 am
by AJ
FYI, an interesting (GPL'd / LGPL'd) opensource project that does very similar is
Darik's Boot and Nuke (interesting that you have gone down a similar line with the project naming!).
Unfortunately I can't test yours at the moment because I don't have an appropriate target machine (could do it on an emu, but that won't tell you more than you already know). If I get access to one, I'll give it a go!
Cheers,
Adam
Re: Napalm v.45 Alpha
Posted: Mon Sep 01, 2008 10:46 am
by 01000101
one wipe of 0's won't completely erase all data from ever being recovered. IIRC the govt standard is seven passes with alternating data and that is deemed unrecoverable by data forensics.
Re: Napalm v.4 Alpha
Posted: Mon Sep 01, 2008 11:02 am
by chezzestix
Huh good to know, I will have to add a prompt as to whether they want a single pass or an unrecoverable wipe.
BTW:
Does anyone know how standard
INT 13/AH=25h is? IBM officially lists it as optional but it would make identifying drives a TON easier and safer for the user.
Re: Napalm v.45 Alpha
Posted: Mon Sep 01, 2008 11:30 am
by Combuster
Since it gives you the output of the ATA identify command, I would expect that it'd only work for ATA harddisks (and thus not for SCSI drives)
But of course you can try to call it and see whether it returns a success value.
Re: Napalm v.45 Alpha
Posted: Mon Sep 01, 2008 7:13 pm
by chezzestix
The command works fine on my hardware. I have provided provisions if it fails so whether or not it works the user will still be able to use napalm.
My first weirdness:
When I try to write on the second head it gives me a status code of 80h... whats going on here. Int 13/ah=01h says 80h=timeout but If I write the second head first it still screws up.
Re: Napalm v.5 Alpha
Posted: Thu Oct 02, 2008 5:41 pm
by chezzestix
Long time no post, I got caught up in my commitment to another hobby and school. Anyhow single 0 wipe over floppies has been implemented so next I tried to tackle HDDs. I thought what better way to identify the HDDs than by model? So I print out a list of HDD models when the program starts. However Its a tad... weird (ignore the dashes they are just there to keep spacing)
Test drive 1: WD2000JB-00DUA3
Output 1:---- DW CDW0200BJ0-D0AU 3
My fix:- WDC WD2000JB-00DUA3
Test Drive 2: AC36400-00LC
Output 2:---- DW CCA6304L0
My fix:- WDC AC36400L
I studied these for awhile and I found a pattern. If you filp every two letters you get the my fix which corrects it. HDD2 has some extra issue of its own but thats no fault of my code. They are both Western Digital Caviar HDDs so that explains the WDC prefix.
So then my question is, WTF? I'll post my code just in case there is something wrong with it I can't see but what is going on here?
Re: Napalm v.45 Alpha
Posted: Thu Oct 02, 2008 9:55 pm
by 01000101
seems like you have a bit of
endianness confusion.
Re: Napalm v.6 Alpha
Posted: Fri Oct 03, 2008 12:52 am
by chezzestix
WHAT COULD BE THE POSSIBLE REASONS FOR USING MIDDLE ENDIAN!?!
What ever... I changed the model output code to match middle Endian.
Code updated in first post
Napalm .60 A additions:
+HDD Model bugfix
+HDD Wiping
-Although massively buggy (possibly middle endian crap....)
+ASCII art splash
+Foundation laid for DoD and uber sani methods on FDDs
Re: Napalm v.60 Alpha
Posted: Fri Oct 03, 2008 11:21 am
by JamesM
chezzestix wrote:WHAT COULD BE THE POSSIBLE REASONS FOR USING MIDDLE ENDIAN!?!
What ever... I changed the model output code to match middle Endian.
Code updated in first post
Napalm .60 A additions:
+HDD Model bugfix
+HDD Wiping
-Although massively buggy (possibly middle endian crap....)
+ASCII art splash
+Foundation laid for DoD and uber sani methods on FDDs
You're still confused. The ATA IDENTIFY command returns 256
little endian 16-bit integers. So if you want a coherent string from them, you will have to byteswap each 16-bit integer. I have no idea where you got that it was using middle endian from...
Re: Napalm v.60
Posted: Sat Oct 04, 2008 12:07 am
by geppy
For future,if you are serious about this:
You should read
Secure Deletion of Data from Magnetic and Solid-State Memory by Peter Gutmann. His method may even be better than 7 pass US standard that 01000101 mentioned. And any of the 2 methods shouldn't work for flash memory. Keep in mind that some hard drives may have special commands for secure data erase.
or better yet get a device that fries hard drive (something has to do with magnetism). Enough for data being deleted but not enough for hard drive to be damaged. Few second job + time to take the drive out of the case. However, such a hard drive might not be seeing by BIOS anymore.
Re: Napalm v.6
Posted: Sat Oct 04, 2008 5:21 am
by chezzestix
@JamesN
Pulled from the table of addresses that Int 13/ah=25h save to and that I am using:
36h 40 BYTEs model number in ASCII
That is what I am printing. I'm not sure where you are getting your assumptions... Your probably assuming I'm using a smarter more stable method I am yet to find. HA! Jokes on you.
As far as my middle endian conclusion:
1) 01000101 mentioned endianess
2) I looked at the article and middle endian matched the crazyness that was going on with the models
@geppy
lol. I'm not in trouble with the government for any reason so device fryers would be a tad extreme but I will give the paper a read. I have seen secure data erase functions lying around but as you said thats a bit of a future thing.
Re: Napalm v.7 Alpha
Posted: Thu Oct 09, 2008 9:35 pm
by chezzestix
New version in first post!
Added:
+DoD wipe for floppies
+"Uberwipe" for floppies
+Replace progress bar with spinny magig
Still to do:
-HDD wiping
Re: Napalm v.45 Alpha
Posted: Tue Oct 14, 2008 10:33 am
by mystran
01000101 wrote:one wipe of 0's won't completely erase all data from ever being recovered. IIRC the govt standard is seven passes with alternating data and that is deemed unrecoverable by data forensics.
If I'm not mistaken, the best plan is to run around 7 passes of cryptographically strong random numbers. The idea being that by using random numbers, statistical analysis on the traces left on the disk become considerably harder.