Skip to content

Commit

Permalink
Fixed typing error
Browse files Browse the repository at this point in the history
Concatenating a slice with a single index can cause type errors.
Replaced the single index with a slice of lenth 1 so that the type is consistent.
  • Loading branch information
cccs-jh committed Nov 26, 2020
1 parent f22cb87 commit e0d156d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion deobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@ def simple_xor_function(self, text):
else:
option_a.append((f, x, k, None))
# try by shifting the key by 1
res = self.xor_with_key(binascii.a2b_hex(x), k[1:] + k[0])
res = self.xor_with_key(binascii.a2b_hex(x), k[1:] + k[0:1])
if self.printable_ratio(res) == 1:
option_b.append((f, x, k, res))
# print 'B:',f,x,k, res
Expand Down

0 comments on commit e0d156d

Please sign in to comment.