Skip to content

Commit

Permalink
Reduce cache filename length on rop.py (fix Gallopsled#1180)
Browse files Browse the repository at this point in the history
  • Loading branch information
xtrm0 committed Oct 5, 2018
1 parent c3c06a3 commit 819cda8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pwnlib/rop/rop.py
Expand Up @@ -1014,9 +1014,10 @@ def __get_cachefile_name(self, files):

hashes = []

sha256 = hashlib.sha256()
for elf in self.elfs:
sha256 = hashlib.sha256(elf.get_data()).hexdigest()
hashes.append(sha256)
sha256.update(elf.get_data())
hashes.append(sha256.hexdigest())

return os.path.join(cachedir, '_'.join(hashes))

Expand Down

0 comments on commit 819cda8

Please sign in to comment.