Closed nitrescov closed 2 years ago
Unfortunately, I don't have an rzusbstick to specifically test this, but after mocking the function to confirm the change you suggested I have added it to PR #252 - Thanks for finding and solving this one!
Thank you for adding the fix. I made several tests with the RZUSB stick and can confirm that sending packets will work again with this simple change. I just didn't have time to make a pull request yet ;)
Thank you again for your help!
Hey all, I want to share a small issue I've noticed when using a RZ USB stick with killerbee.
General information
Issue
With Python 2, scapy packets could be passed as str(pkt) to the killerbee inject method, which worked fine.
With Python 3, on the other hand, it doesn't matter whether you pass the packet as a string or bytes. Killerbee always tries to concatenate both data types.
Traceback 1: injecting bytes
Here the problem is clear.
Traceback 2: injecting string
In this case it seems to be the other way round. Apparently struct.pack() returns bytes which cannot be concatenated with the packet string.
This can also be confirmed with killerbee internal tools that use the inject function (e.g. zbstumbler).
Has anyone else noticed this problem so far?
Edit: Unless I'm completely wrong, shouldn't this be solved by making the "\x00\x00" in line 523 a b"\x00\x00"?