Skip to content
This repository has been archived by the owner on Sep 17, 2019. It is now read-only.

Commit

Permalink
Merge a267763 into 6c11693
Browse files Browse the repository at this point in the history
  • Loading branch information
HugoDelval committed Oct 27, 2017
2 parents 6c11693 + a267763 commit b1e55db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion reputation/db/mongo.py
Expand Up @@ -200,7 +200,7 @@ def _build_file_document(input_dict):
:return: A dictionary ready to be pushed into the file collection
"""
current_ts = int(time.time() * 100)
raw_hash = hashlib.sha256(input_dict['raw']).hexdigest()
raw_hash = hashlib.sha256(input_dict['raw'].encode()).hexdigest()
rnd_val = random.randint(10000, 99999)

filename = '{}-{}-{}'.format(current_ts, raw_hash, rnd_val)
Expand Down

0 comments on commit b1e55db

Please sign in to comment.