Difference between revisions of "Linux Secure Delete"

From Hack Sphere Labs Wiki
Jump to: navigation, search
(Wipe Drive Erase)
(Wipe Drive Erase)
Line 9: Line 9:
  
 
=Wipe Drive Erase=
 
=Wipe Drive Erase=
dd command
+
*dd command
 
  dd if=/dev/zero of=/dev/sdX iflag=nocache oflag=direct bs=4096
 
  dd if=/dev/zero of=/dev/sdX iflag=nocache oflag=direct bs=4096
  
dd command repeat
+
*dd command repeat
  
 
<pre>
 
<pre>
 
while [ 1 ];
 
while [ 1 ];
 
do  
 
do  
   kill -USR1 $(pidof dd)
+
   dd if=/dev/zero of=/dev/sdX iflag=nocache oflag=direct bs=4096
 
   sleep 5;
 
   sleep 5;
 
done
 
done

Revision as of 10:40, 17 December 2013

sudo apt-get install secure-delete

This has four tools:

srm - securely delete an existing file
smem - securely delete traces of a file from ram
sfill - wipe all the space marked as empty on your hard drive
sswap - wipe all the data from you swap space.

Wipe Drive Erase

  • dd command
dd if=/dev/zero of=/dev/sdX iflag=nocache oflag=direct bs=4096
  • dd command repeat
while [ 1 ];
do 
  dd if=/dev/zero of=/dev/sdX iflag=nocache oflag=direct bs=4096
  sleep 5;
done
  • Progress of DD
while [ 1 ];
do 
  kill -USR1 $(pidof dd)
  sleep 5;
done


Notes