Skip to content
Snippets Groups Projects
Commit 1c918827 authored by Bob Mottram's avatar Bob Mottram
Browse files

Username

parent 5d9b8db7
No related branches found
No related tags found
No related merge requests found
......@@ -118,19 +118,19 @@ fi
if [ ${#CURR_PASSWORD} -eq 0 ]; then
# retrieve password
if [ ! -f ~/.passwords/$CURR_USER/$CURR_APP ]; then
if [ ! -f ~/.passwords/$CURR_USERNAME/$CURR_APP ]; then
echo ""
exit 4
else
gpg -dq --passphrase "$MASTER_PASSWORD" ~/.passwords/$CURR_USER/$CURR_APP
gpg -dq --passphrase "$MASTER_PASSWORD" ~/.passwords/$CURR_USERNAME/$CURR_APP
fi
else
# store password
if [ ! -d ~/.passwords/$CURR_USER ]; then
mkdir -p ~/.passwords/$CURR_USER
if [ ! -d ~/.passwords/$CURR_USERNAME ]; then
mkdir -p ~/.passwords/$CURR_USERNAME
fi
echo$CURR_PASSWORD” | gpg -ca --cipher-algo AES256 --passphrase "$MASTER_PASSWORD" > ~/.passwords/$CURR_USER/$CURR_APP
if [ ! -f ~/.passwords/$CURR_USER/$CURR_APP ]; then
echo$CURR_PASSWORD” | gpg -ca --cipher-algo AES256 --passphrase "$MASTER_PASSWORD" > ~/.passwords/$CURR_USERNAME/$CURR_APP
if [ ! -f ~/.passwords/$CURR_USERNAME/$CURR_APP ]; then
exit 5
fi
fi
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment