use rs256

This commit is contained in:
Wolfgang Hottgenroth 2021-05-06 15:42:46 +02:00
parent 35a997774f
commit 49e8aa43b4
Signed by: wn
GPG Key ID: 6C1E5E531E0D5D7F

View File

@ -103,7 +103,7 @@ def generateToken(**args):
# print("DEBUG: generateToken: add claim {} -> {}".format(claim[0], claim[1]))
payload[claim[0]] = claim[1]
return jwt.encode(payload, JWT_SECRET)
return jwt.encode(payload, JWT_SECRET, algorithm='RS256')
except NoUserException:
print("ERROR: generateToken: no user found, login or application wrong")
raise werkzeug.exceptions.Unauthorized()