mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-28 18:28:23 -05:00
tests: Use int instead of long for python3 compatibility
This patch is made by using 2to3 command. $ find . -name *.py | xargs 2to3 -f long -w -n Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
This commit is contained in:
parent
e1bb41bfde
commit
e6b283f758
@ -6347,7 +6347,7 @@ def wsc_dh_init():
|
||||
return own_private, pk
|
||||
|
||||
def wsc_dh_kdf(peer_pk, own_private, mac_addr, e_nonce, r_nonce):
|
||||
peer_public = long(binascii.hexlify(peer_pk), 16)
|
||||
peer_public = int(binascii.hexlify(peer_pk), 16)
|
||||
if peer_public < 2 or peer_public >= group_5_prime:
|
||||
raise Exception("Invalid peer public key")
|
||||
if pow(peer_public, (group_5_prime - 1) / 2, group_5_prime) != 1:
|
||||
|
Loading…
Reference in New Issue
Block a user