Skip to content

Commit

Permalink
Update user.py
Browse files Browse the repository at this point in the history
  • Loading branch information
elg committed Sep 10, 2019
1 parent b143c77 commit c0a9dc5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions passhportd/app/models_mod/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ def show_sshkeyhash(self):
if self.sshkeyhash:
return self.sshkeyhash

app.loggerwarning("WARN: This user sshkey hash is not stored: " + self.name,
app.logger.warning("WARN: This user sshkey hash is not stored: " + self.name,
file=sys.stderr)
return self.hash(self.sshkey)

Expand Down Expand Up @@ -243,7 +243,7 @@ def hash(sshkey):
m.update(base64.b64decode(key[1]))
hashkey= base64.b64encode(m.digest()).decode('utf-8')
except:
app.loggererror("ERROR: wrong sshkey format: " + sshkey, file=sys.stderr)
app.logger.error("ERROR: wrong sshkey format: " + sshkey, file=sys.stderr)
return("Wrong ssh key format")

return hashkey
Expand Down

0 comments on commit c0a9dc5

Please sign in to comment.