Be more careful when checking passwords, make sure that the password file exists and is not empty.
This commit is contained in:
parent
2573838f1b
commit
32706e97c7
1 changed files with 1 additions and 1 deletions
|
|
@ -68,7 +68,7 @@ fn auth_user {
|
||||||
status=('Auth: missing user name or pass: '^$"user_name^' / '^$"user_password)
|
status=('Auth: missing user name or pass: '^$"user_name^' / '^$"user_password)
|
||||||
if not if(! test -f $pfile)
|
if not if(! test -f $pfile)
|
||||||
status=('Auth: cant find '^$pfile)
|
status=('Auth: cant find '^$pfile)
|
||||||
if not if(! ~ $user_password `{cat $pfile})
|
if not if(! test -s $pfile || ! ~ $user_password `{cat $pfile})
|
||||||
status=('Auth: Pass '$user_password' doesnt match '^`{cat $pfile})
|
status=('Auth: Pass '$user_password' doesnt match '^`{cat $pfile})
|
||||||
if not {
|
if not {
|
||||||
logged_user=$user_name
|
logged_user=$user_name
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue