Hello?
When I try to parse udp packet like this:
Packet packet = Packet.ParsePacket( LinkLayers.Ethernet, raw_capture.Data ) ;
Debug.Assert( packet is EthernetPacket ) ; // OK.
Debug.Assert( packet.PayloadPacket is IPv4Packet ) ; // OK
Debug.Assert( packet.PayloadPacket.ParentPacket != null ) ; // Nop. it is always null.
In my thought, packet.PayloadPacket should be IPv4Packet, and packet.PayloadPacket.ParentPacket must be packet itself. Isn't it?
But, in my code, packet.PayloadPacket is IPv4Packet, but packet.PayloadPacket.ParentPacket is always null.
It is null even I try with ARP packet.
What should I do or check?
My PacketDotNet is downloaded from nuget.org and its version is v1.1.1.