mirror of
https://github.com/lgandx/Responder.git
synced 2025-07-06 04:51:23 -07:00
Fixed minor parsing issue in FindIP
This commit is contained in:
parent
fa2b8dd5fd
commit
398a1fce31
1 changed files with 3 additions and 2 deletions
|
@ -240,8 +240,9 @@ def ParseSrcDSTAddr(data):
|
|||
|
||||
def FindIP(data):
|
||||
IPPos = data.find(b"\x32\x04") + 2
|
||||
if IPPos == -1 or IPPos + 4 >= len(data):
|
||||
return None
|
||||
if IPPos == -1 or IPPos + 4 >= len(data) or IPPos == 1:
|
||||
#Probably not present in the DHCP options we received, let's grab it from the IP header instead
|
||||
return data[12:16]
|
||||
else:
|
||||
IP = data[IPPos:IPPos+4]
|
||||
return IP
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue