[maemo-users] Wipe files

From: Dongi maemo at la.mine.nu
Date: Mon Aug 6 15:18:28 EEST 2007
On 6 August 2007, Eero Tamminen <eero.tamminen at nokia.com> wrote:
> > On Aug 5, 2007, at 1:39 PM, "n800 at massone.name" <n800 at massone.name>
> > wrote:
> >> I would like to know if somebody knows about an application to
> >> permanently delete files for Nokia N800.
> Because flash wears out (eventually), getting things physically
> overwritten can take a lot of time, or it might never happen because
> JFFS2 does wear-leveling and just garbage collects overwritten blocks
> and writes the new content elsewhere.

All flash based file systems employ some kind of wear leveling scheme.
This means you have no control of the physical address of your writes.
If you just delete a file without overwriting the same flash pages
afterwards one can always desolder the flash chip and read it in a
programmer to dump the whole space and reconstruct the file. There 
are companies who make a living from recovering digital photos for
people this way.

The easiest way to wipe your data is to do a 'cat /dev/zero > file'
after you've rm the sensitive files and wait until the filesystem 
is full. If it's and ext2 filesystem make sure you do this as root
since some blocks are reserved only for the superuser.

By filling the whole space with zero's you make sure that every free
block is wiped out. For flash memories you don't have the same problem
as for hard-drives where the information can still be recovered after 
up to 5 times of overwriting. In a flash memory the difference between
a 1 and a 0 consists in roughly 200 electrons for today's densities.
Add to this the fact that lots of flash memories have now multi level
cells (MLC) which means more bits are stored on the same cell using 4 or
more different voltages. So it is virtually impossible to scan the
charge from the floating gates as analog values to build the 'previous'
pattern. The noise level from scanning (using a proximity scanning
capacitance microscope after delayering the flash chip) will be 
above the natural variation in charge.

If your level of paranoia is above average ;-) contact me by email and
I'll send you a little program (for Nokia N800) which fills the flash
space with pseudo-random data at high speeds.
It will still take some 15 minutes to fill a 2G partition with pseudo
random data.
dd if=/dev/urandom of=file is much to slow for this purpose.

Marx on sex: From each according to his virility, to each according to her need.

More information about the maemo-users mailing list