HDD Autowipe

Hi all,
It’s not strictly DietPi related but i would love to know if there was a way to have a drive nuke installed using DietPi?
Basically i have a Pi Zero and would like to have the function that if i attach a usb HDD it automatically wipes it (writes over one pass with Zeros) then the led changes colour when complete?
Is this feasable?

dariks boot and nuke

Burn the iso to a bootable pendrive, I believe then you can create a text file in the root directory of the pendrive that will autonuke all drives

https://www.pendrivelinux.com/install-dban-to-a-usb-flash-drive-using-windows/
https://www.nextofwindows.com/how-to-boot-dban-off-usb-drive-to-wipe-out-the-hard-drive

I have been a keen fan of DBAN but wasnt sure i could run it on Pi?
Also it requires user intervention to start the wipe. I was looking at this project https://github.com/craigmayhew/USBCleanser/blob/master/README.md

But have had no joy getting it working on Stretch Lite, Just about to fire up my Pi 3 with full Jessie on and see if that works.

anyone able to help out?

Seems there needs to be a script that detects and automounts the drives when they are plugged in, then that script initiates a erasure of the drive

autofs might mount them…but then you need a way to trigger a script to wipe the drive, then auto eject it
https://linuxconfig.org/automatically-mount-usb-external-drive-with-autofs

I see what you are wanting to do…be able to walk up…plug in…wipe all data clean…make a safe USB device
https://www.indracompany.com/sites/default/files/usb-kiosko-en-baja.pdf

Or usbmount
mount the device, then have it run thru some script the shred command

Dug around…check this out

https://github.com/Real-Time-Kodi/PiBAN
Now…all you need is a powered USB hub, that above script…anything plugged into the USB hub gets shredded…then reformatted as FAT32
Remember…USE WITH CAUTION!

I couldnt get Piban working but i used the updated readme from https://github.com/pgporada/autoshred and got it working on my DietPi :slight_smile: