I would like to find a solution (FOSS & GUI) to shred files on an Android smartphone and overwrite the device’s free space from a Linux PC,
then, in a second phase, a solution for recovering deleted data from this smartphone (to check the effectiveness of the shredding)
I use on the one hand Linux Debian and on the other hand, a non-rooted Android smartphone,
As I’m familiar with the adb program, I’ve tried to use it with Bleachbit and Testdisk, but these programs don’t detect the smartphone…
At least, I’d like to know if it’s possible to access the /data part of a non-rooted smartphone from adb?
(In this case, the “–user 0” command doesn’t work…)
Overwriting data is pretty pointless on modern storage. The only effective way to destruct data is to get rid of the decryption keys, which in android is a default on factory reset. If you cannot rely on that you should, with caution, physically destroy the device, after reset, through propper means aka actual shredding.
It’s only really useful if you have HDD drives. On ssd you are just wasting your durability. NAND (ssd/flash) typically do not use the same physical location on each write given by the flash translation layer. I believe the term is wear leveling should you want to get more info online.
If you dont write on the same physical location it is still possible to recover data.
Just want to clarify that its HDDs with physical spinning discs you should be doing this for, which are typically SATA based, but SATA based SSDs exist in both 2.5 inch and M.2 form factors
So running a 7-pass secure erase on a USB stick will not do anything other than ruin it? How would you go about making data forensically unobtainable on a USB stick that already had unencrypted data on it?
Filling a drive with junk data is useful regardless of medium.
It can still dramatically reduce the lifetime of data on flash disks and largely eliminate it on mechanical disks.
If you want to be sure you should be combining both data filling and built-in erasure methods (ATA secure erase or nvme sanitize or nvme block erase).
For Android specifically there is far too much spare area in the system and firmware partitions to make filling that useful, but it can still have some benefit.
For luks, please note your header can be backed up at anytime, so if your drive doesn’t really discard it could later be combined to restore data even if you thought it was fine. Hence combining is good.
And finally physical destruction when it really matters is the only option.