Commit 34f41f05413f38874e25bb8a7148e1151f655efd
1 parent
2a355725
Exists in
master
fix encoding
Showing
1 changed file
with
2 additions
and
1 deletions
Show diff stats
wscserver/view/restfulview.py
... | ... | @@ -35,9 +35,10 @@ class CustomRESTfulView(RESTfulView): |
35 | 35 | classes = {} |
36 | 36 | |
37 | 37 | # Gera um hash para o id_computador |
38 | + salt = str('salthere').encode('utf-8') | |
38 | 39 | id_reg = str(computador).encode('utf-8') |
39 | 40 | id_reg = hashlib.sha512(id_reg) |
40 | - id_reg.update('salthere') | |
41 | + id_reg.update(salt) | |
41 | 42 | id_reg = id_reg.hexdigest() |
42 | 43 | classes['id_reg'] = id_reg |
43 | 44 | ... | ... |