Closed dkg closed 6 years ago
Hi ! This bug is fixed on the official scapy repo (secdev/scapy), which now supports Python 3. I recommend you to have a look https://github.com/secdev/scapy
Good day
@GhostOfGoes To avoid "confuse emojis", I'll provide the proof.
Here's current secdev/scapy implementation of the getmacbyip6
function:
https://github.com/secdev/scapy/blob/0aeb049606bee9335e62afea58479915bd6e2344/scapy/layers/inet6.py#L116-L155
res = neighsol(ip6, a, iff, chainCC=chainCC)
if res is not None:
if ICMPv6NDOptDstLLAddr in res:
mac = res[ICMPv6NDOptDstLLAddr].lladdr
else:
mac = res.src
conf.netcache.in6_neighbor[ip6] = mac
return mac
return None
What I'm saying is only the truth: this has INDEED been fixed on the main branch. Now please either contribute to scapy3k, or let me point out to users how outdated this fork is.
Thanks for clearing that up, and the link to the fix is appreciated. 😄
I just wasn't sure if the specific issues raised here were fixed in mainline scapy, due to the same message being used across issues.
Thanks for clarifying :)
Issue fixed in the latest commit.
@phaethon Good luck
in
scapy/layers/inet6.py
, the functiongetmacbyip6()
ends with the following:This doesn't make sense. in the stanza following
if
statement,mac
is set but never used (andNone
is returned). In theelse
stanza -- whereres
must beNone
-- it references a subfield ofres
, which is guaranteed to fail.