This header can be used with Marvell switches to direct packets in/out
of a specific port in a tree of interconnected switches. The header
uses its own Ethertype of 0xdada.
By default, only brief output is printed, showing the switch device,
port, and vlan the packet is to/from. However if -e is given, to print
the link-level header, all fields are printed.
It's also used for WPA/WPA2, so it's a generic "protected by encryption"
flag. Update the name of the macro that checks it, and report it as
"Protected" rather than "WEP Encrypted".
Improve decoding of BSN vendor commands: update printing of commands
that set/get mirror port reporting flag, add decoding of shell exec
commands. Introduce decoding of vendor-specific actions with BSN as the
first such vendor and "mirror" as the first such BSN action.
Add a new test case based on a packet capture produced using Trema
controller and an Arista 7050SX-64 switch in Arista Networks' test lab.
Besides the structures above the capture contains the following items:
* OFPT_QUEUE_GET_CONFIG_REPLY with 0 queues (a valid edge case)
* OFPT_FEATURES_REPLY with ports 21 and 23 having bogus "config" field
(a violation of the protocol, which required temporary patching of the
controller to avoid the session shutdown)
* a set of IP mask manipulation BSN-specific commands
Allow an extra byte in the buffer for snprintf()'s null character,
otherwise it does not work as intended (issue spotted by Gisle Vanem on
Windows, where snprintf() behaviour seems to be different). Update the
tests.
When compiled with Capsicum, tcpdump -E 'file filename' fails to read
the secret from the file with the "Not permitted in capability mode"
error and exits with code 3. Skip respective tests until this logic is
handled in a better way.
Introduce a new function that tries to dispatch an OFPT_VENDOR message
to a vendor-specific printer function. Add such a function for Big
Switch Networks vendor with about as little decoding as necessary to
cover the existing 7050Q OF1.0 capture.
The new function goes into print-openflow.c as vendor name decoding is
the same in all versions of OpenFlow (although in 1.0 it is "vendor"
and in subsequent versions it is "experimenter"). The mapping is from:
https://rs.opennetworking.org/wiki/display/PUBLIC/ONF+Registry
Currently, TESTonce uses 'diff -w' so it ignores all white space.
We need a strict comparison, else there is no difference between, for example,
'Association Setup' and 'AssociationSetup' => removing the option '-w'
The value of the length field in a UDP header includes the length of the
header itself; the values in this capture didn't. The length fields in
the IP headers and the RADIUS headers were correct and consistent with
each other, and the length fields in the UDP headers are now correct and
consistent with both of them.
The sample capture was produced with two Linux hosts (aoetools version
36, kernel module version 85, vblade version 21). One of the hosts
exported a 1MB block device containing a freshly created filesystem and
the other mounted it, wrote a small file and then unmounted.