9 lines
158 B
Plaintext
9 lines
158 B
Plaintext
|
#!/bin/sh
|
||
|
|
||
|
if [ -z "$1" ] || [ -z "$2" ]; then
|
||
|
echo "Usage: $0 <username> <password>"
|
||
|
exit 1
|
||
|
fi
|
||
|
HASHED=$(openssl passwd -apr1 "$2")
|
||
|
echo "$1:$HASHED"
|