Search

Make your files unrecoverable before deleting

You dont even have to destroy the HD like Elliot Alderson did ๐Ÿ˜ƒ .


Make your files unrecoverable before deleting


shred is a command in operating systems of type Unix in Portuguese means: shredding. It is used to securely delete files and devices, making them extremely difficult to recover, even with specialized hardware and technology; It is part of GNU Core Utilities .

The process of delete a file from storage using the command rm usually erases only the file system entry of the file, keeping the contents of the file intact. This often allows commonly available software to recover data from the โ€œdeletedโ€ file.

If the file data is stored on magnetic media, such as an HDD , even if the file is overwritten, residual magnetic fields may allow data recovery using hardware equipment skilled .

To avoid this, shredding replaces the contents of a file multiple times, using patterns chosen to maximize the destruction of residual data.


How to install shred?

If you have a GNU/Linux system, you probably already have shred installed on your system. In many cases BSD and similar systems, such as macOS there is also a great chance to have already installed.

But if you donโ€™t have it or if you have another operating system, like Windows for example, you can clone and compile from this address: https:// www.gnu.org/software/coreutils/ .

In short shred is just a file written in C: shred.c .


Using

The basic syntax is similar to several commands which boils down to:

shred [OPTION]... FILE...

The file can also be a device.

โ€œRemovingโ€ a base file:

shred file.txt

The file will still not be removed, however the data it contains will no longer exist.

Getting details of this โ€œremovalโ€, use the -v parameter

shred -v file.txt

The -z parameter assigns zeros to the data, in conjunction with -v you can see this:

shred: file.txt: pass 1/4 (random)...
shred: file.txt: pass 2/4 (random)...
shred: file.txt: pass 3/4 (random)...
shred: file.txt: pass 4/4 (000000)...

Remove data, reset data and delete file

Note that after running the above commands, the file will still exist. For after destroying and zeroing the data you want to delete the file just use the -u command, example using it together with previous parameters:

shred: file.txt: pass 1/4 (random)...
shred: file.txt: pass 2/4 (random)...
shred: file.txt: pass 3/4 (random)...
shred: file.txt: pass 4/4 (000000)...
shred: file.txt: removing
shred: file.txt: renamed to 00000000
shred: 00000000: renamed to 0000000
shred: 0000000: renamed to 000000
shred: 000000: renamed to 00000
shred: 00000: renamed to 0000
shred: 0000: renamed to 000
shred: 000: renamed to 00
shred: 00: renamed to 0
shred: file.txt: removed

Really good right?! For more information, access the help and manual:

shred --help
man shred

Useful links


gnu commands


Share



Comments