DEV Community

loading...

Discussion on: 9 Evil Bash Commands Explained

Collapse
thojest profile image
thojest

4) on steroids (much much faster than dev/urandom):

WARNING: THIS COMMAND WILL DELETE YOUR ENTIRE HARD DRIVE

openssl enc -aes-256-ctr -pass pass:"$(dd if=/dev/urandom bs=128 count=1 2>/dev/null | base64)" -nosalt </dev/zero > /dev/sda1

we are using AES cipher of openssl in parallel mode to encrypt a stream of plain zeros with some random pw. this will look like random data. then we write to sda