Skip to content

Instantly share code, notes, and snippets.

@MorbosVermin
Created August 12, 2014 20:08
Show Gist options
  • Save MorbosVermin/4753064de9951bcdd861 to your computer and use it in GitHub Desktop.
Save MorbosVermin/4753064de9951bcdd861 to your computer and use it in GitHub Desktop.
#!/bin/bash
rootpwd=$(cat /dev/urandom|tr -dc "a-zA-Z0-9-_\$\?"|fold -w 30|head -n 1)
passwd "root" <<EOF
$rootpwd
$rootpwd
EOF
logger -t root_scramble "Scrambled the eggs doOd!"
exit $?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment