Convert Log file to pcap file in C#

1.1k Views Asked by At

I have captured UDP packet log files which contains payload data only, i need to convert these UDP packets from log files to.pcap using C#. I dont have any idea how to convert log files to .pcap files.

1

There are 1 best solutions below

2
brickner On

You can create Packets using Pcap.Net by following the tutorial. https://github.com/PcapDotNet/Pcap.Net/wiki/Pcap.Net-Tutorial-Sending-Packets

Then you can dump the packets into a .pcap file by following the tutorial. https://github.com/PcapDotNet/Pcap.Net/wiki/Pcap.Net-Tutorial-Handling-offline-dump-files#saving-packets-to-a-dump-file