aboutsip / pkts

Pure java based pcap library capable of reading and writing to/from pcaps.
Other
198 stars 92 forks source link

Fix IPv4Framer's treatment of truncated packet captures #61

Closed epall closed 7 years ago

epall commented 7 years ago

I'm working with .pcap packet captures that have a snaplen < 1500, so the frames in the file are truncated with respect to the length in the IP header. This is currently throwing an IndexOutOfBoundsException in the framer, causing it to not parse the IP header. It would be better to go ahead and parse the IP header.

jonbo372 commented 7 years ago

Agreed. Nice catch and thanks for the contribution. Merging this one and currently I have no other items in the works so let me know if you want me to build a 3.0.1 release right away or if you want to continue on your project a little longer in case you find more issues.

epall commented 7 years ago

Thanks! I'm working from source, so I'm happy to wait and see for a bit if I catch anything else.

jonbo372 commented 7 years ago

Sounds good. Just ping me when you want me to release it... Feel free to ping me on my personal email.