I\'m trying to parse a previously-captured trace for HTTP headers using the dpkt module:
import dpkt
import sys
f=file(sys.argv[1],\"rb\")
pcap=dpkt.pcap.R
-
I have encountered the same problem while working with HTTP Requests and dpkt.
The problem is that the dpkt's HTTP headers parser uses wrong logic. This exception is raised when the HTTP doesn't end with \r\n\r\n
. (And as you say, there are a lot of good packets with no \r\n\r\n
at the end.)
Here is the bug report to your problem.
- 热议问题