PCAP read/writer

OONI probe needs to be able to read and write pcap data.

We need a way to read all the data that is sent and received by a certain test. This can be achieved with one of three ways:

  1. The writer of a test specifies the BPF filter [1] that packets generated by it's test will adhere to
  2. The packets generated by the test are marked in a way that it is then possible to retrieve them from the midst of other packets.
  3. We create a tun/tap device specific for ooni probe or one for each test and route the traffic of the test through it.

For pcap support in python there is pypcap: http://code.google.com/p/pypcap/

[1] http://biot.com/capstats/bpf.html

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information