mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
git-auth: deny login if no password has been set
After creating a new account, users need to verify their email address and set an initial password. Without setting a password, users cannot use their account on the web interface. However, when logging in via SSH, we did not check whether the account is verified. Fix this by only allowing SSH access once a password is set. Reported-by: Pat Hogan <pathtofile@gmail.com> Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
This commit is contained in:
parent
e3ca3c96e5
commit
dd11321fa3
1 changed files with 2 additions and 1 deletions
|
@ -39,7 +39,8 @@ def main():
|
|||
|
||||
cur = conn.execute("SELECT Users.Username, Users.AccountTypeID FROM Users "
|
||||
"INNER JOIN SSHPubKeys ON SSHPubKeys.UserID = Users.ID "
|
||||
"WHERE SSHPubKeys.PubKey = ? AND Users.Suspended = 0",
|
||||
"WHERE SSHPubKeys.PubKey = ? AND Users.Suspended = 0 "
|
||||
"AND NOT Users.Passwd = ''",
|
||||
(keytype + " " + keytext,))
|
||||
|
||||
row = cur.fetchone()
|
||||
|
|
Loading…
Add table
Reference in a new issue