Recovering corrupt packet captures
Hi,
as I've been porting to Python and publishing my earlier work related to recovering IPv4 packets from binary files, I started wondering about the subject of recovering corrupt packet capture files. Not just the last packet captured in the file truncated, but conditions when Wireshark hit a format error and stops processing the capture file well before its end. Any interest from the community? In my own experience I had a few critical problems where the capture file was corrupt and no backup copies were available, so I wrote a couple utilities for recovering the files. Still, maybe it was just my luck?
The example with my script for recovering IPv4 is at https://www.linkedin.com/pulse/detect...
TIA
Vadim
Any interest from the community?
From the Help page:
How questions, answers and comments work
This site is for asking and answering questions, not for open-ended discussions. We encourage everyone to use “question” space for asking and “answer” for answering.
I don't believe this question fits the format of this site very well, and I would therefore suggest that you solicit feedback about this topic on the wireshark-dev and/or wireshark-user mailing lists instead.
Looking for simple yes/no answers from the user community actually: no point in developing the code of no practical interest. But probably you meant list wireshark-users instead?
Well, this is just one person's opinion, but I think anything that helps to improve the product is welcome, and I'd say this fits the bill. How exactly corrupt packets/files are recovered is another matter though. Or perhaps you somehow find a way to simply skip corrupted packets and move on to the next packet? Does that include corrupt pcap files only or corrupt pcapng files too? If pcapng files are corrupted and you're able to somehow "fix" them, then it would probably be a good idea to add packet comments so the user is aware that a packet was manipulated in some way. There are probably many more considerations to be made though, which is why I suggested bringing up the topic on a forum more suitable to discussions than this Q/A forum.
See also pcapfix.
Yes, with another corrupt packet trace I got for my analysis:
Utility pcapfix did work quite well.
Thank you, Guy.