New and improved password hashing script
This commit is contained in:
parent
1750872280
commit
f656866e7d
3 changed files with 14 additions and 4 deletions
13
diodemail-hash
Executable file
13
diodemail-hash
Executable file
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
|
||||
USERNAME="$1"
|
||||
if [ "$USERNAME" == "" ]; then
|
||||
printf "Username: "
|
||||
read USERNAME
|
||||
fi
|
||||
printf "Password: "
|
||||
stty -echo
|
||||
read PASSWORD
|
||||
stty echo
|
||||
printf "\n"
|
||||
printf "\0$USERNAME\0$PASSWORD" | base64 | tr -d '\n' | sha256sum
|
Loading…
Add table
Add a link
Reference in a new issue