Fix credentials short-circuits
This commit is contained in:
parent
be2b7edc4c
commit
8f00ffb6b8
@ -57,12 +57,18 @@ get_from_flags()
|
||||
pass=$3
|
||||
sfa=$4
|
||||
|
||||
[ $user = yes ] && sekrit has services/"$service"/user ||
|
||||
err "Service \"$service\" has no user."
|
||||
[ $pass = yes ] && sekrit has services/"$service"/pass ||
|
||||
err "Service \"$service\" has no pass."
|
||||
[ $sfa = yes ] && sekrit has services/"$service"/2fa ||
|
||||
err "Service \"$service\" has no 2fa."
|
||||
if [ $user = yes ]; then
|
||||
sekrit has services/"$service"/user ||
|
||||
err "Service \"$service\" has no user."
|
||||
fi
|
||||
if [ $pass = yes ]; then
|
||||
sekrit has services/"$service"/pass ||
|
||||
err "Service \"$service\" has no pass."
|
||||
fi
|
||||
if [ $sfa = yes ]; then
|
||||
sekrit has services/"$service"/2fa ||
|
||||
err "Service \"$service\" has no 2fa."
|
||||
fi
|
||||
|
||||
[ $user = yes ] && get_user "$service"
|
||||
[ $pass = yes ] && get_pass "$service"
|
||||
|
Loading…
Reference in New Issue
Block a user