Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 29 Dec 2015 16:26:10 -0600
From:      Juan Herrera <mybsdmailing@gmail.com>
To:        freebsd-net@freebsd.org
Subject:   BPF Berkeley Packet Filter
Message-ID:  <CAAN2wCD6Bdzzy=sHSww5QLR94bi52R=cDvq-sk%2Bmo3sViFGjUQ@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hello,

I have a question regarding Berkeley Packet filter, which is Can I read an
incoming packet length with BPF, I am working on a project that requires to
filter the receiving packets in the kernel before they get to userspace,
but I need to be able to read the packet length when applying BPF because I
(previously) encapsulated the packet with my own metadata before sending it
to the machine with BPF so I want to read packet length to decapsulate as I
know the value for the metadata at the end of the packet?


Thank you in advance!



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAAN2wCD6Bdzzy=sHSww5QLR94bi52R=cDvq-sk%2Bmo3sViFGjUQ>