all repos — dotfiles @ 0a55cd8663268a0bdb1d9044c28733921ab87885

linux dotfiles

bin/misc/split_and_encrypt/genhash.sh

1 2 3 4 5 6 7 8 9 10 11
#!/usr/bin/bash

# generate random md5 hashes using /dev/urandom

for value in $(seq 0 $(expr $1 - 1))
do
    md5sum=$(dd status=none if=/dev/urandom bs=16 count=2 | md5sum |\
        cut -d ' ' -f 1 )
    # just using 16 chars of the hash
    echo ${md5sum::16}
done