The problem: UDP packets are missing.
How could I capture every single UDP packet that is hitting the port?
I want to put received packet on the queue for preprocessing in the background and continue capturing new UDP packets without a single UDP packet loss?
public void Main()
{
Socket client = new(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp);
....
Console.WriteLine("Collecting data..");
while (true)
{
CaptureUDPPacket(client, _ep);
}
}
What is the best way to implement this feature?
Best regards!