-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dhcp.py: decode error "object has no attribute 'encode'" #1633
Comments
it seems the line 381 in
because the buffer is not bytes but bytearray. fixing this leads to the next error:
|
I also got this error, here is my code:
Could anyone take a look at it? |
As @emdete mentioned, this error can be solved by modifying the following condition to also include impacket/impacket/structure.py Line 384 in 3ce41be
The fix may cause some unwanted splash damage so further testing is required. Another option would be to fix the method responsible for calling structure.unpack with bytearray as an argument (instead of bytes). It was recently introduced by another PR: 3f64510. We could convert Line 181 in 3ce41be
Both alternatives fix the problem |
Configuration
impacket version: HEAD
Python version: 3.11
Target OS: Linux
Debug Output With Command String
PCAP
Additional context
The text was updated successfully, but these errors were encountered: