1. First checks

  1. The driver is optional: it is part of the engine only if it was built with the CMake option INCLUDE_SNIFFER. It needs the capture library at run time — Npcap on Windows (installer shipped with the sources: npcap-1.84.exe), libpcap on Linux (sudo apt install libpcap0.8).
  2. Start the engine and read the start-up report. The driver prints SnifferDriverDriver: Stream '<name>' Adapters list followed by one line per capture adapter (its exact name, then the description and IPv4 addresses). The "adapter" value must be one of those names, character for character — for example \\Device\\NPF_{GUID} (backslashes doubled in JSON) or \\Device\\NPF_Loopback for traffic between programs on the same PC.
  3. Check the line SnifferDriverDriver: Stream '<name>' Open with '<type>' adapter type (for example EN10MB = Ethernet). If it is missing, the adapter was not opened — look for Failed to open adapter.
  4. Check the block counters of the input block in DIPanel or System Layout: msgCounter rising = packets match and are decoded; errCounter rising = size / header mismatch (section 3).
  5. Start with open settings to prove the capture works: localIP / remoteIP empty, localPort / remotePort 0, source and destination "both" (the defaults). Then narrow down (section 4).
  6. Set input blocks to "framePerMS": -1 (see the note on framePerMS).

2. Message reference

The messages of this driver begin with SnifferDriverDriver: (this spelling is the one in the code). <name> is the stream name.

MessageCauseWhat to do
SnifferDriverDriver: Stream '<name>' Adapters list + lines <adapter name> <description> IPv4: <ip> (info)Printed once when the driver is created: all adapters that the capture library can open.Copy the adapter name into "adapter". If the list is empty or only a few adapters appear, Npcap is installed without the needed support, or the process has no right to list adapters (section 5).
pcap_findalldevs failed: <text> (exception at driver creation)The capture library could not list the adapters — the Npcap driver / service is not running, or libpcap has no permission.Install or repair Npcap, check that the "Npcap Packet Driver (NPF)" service is running (sc query npcap); on Linux run with CAP_NET_RAW or as root.
SnifferDriverDriver: Stream '<name>' Failed to open adapter
  <library text> (error)
The adapter name does not exist, the adapter is gone, or the process has no right to capture. The second line is the text of the capture library.Use the exact name from the list. On Windows run once as administrator, or reinstall Npcap without the "restrict to administrators" option. Linux: run as root or give the binary sudo setcap cap_net_raw,cap_net_admin=eip.
SnifferDriverDriver: Stream '<name>' Open with '<type>' adapter type (info)The adapter was opened (promiscuous mode, 65536 byte snap length, non-blocking). <type> is the link type, e.g. EN10MB (Ethernet) or NULL (loopback).Normal.
SnifferDriverDriver: Stream '<name>' capture with filter + '<filter>' (info)The capture filter text built from filter, the IP / port fields and source / destination compiled correctly.Read the printed filter to see what the driver built from your fields.
SnifferDriverDriver: Stream '<name>' invalid filter '<filter>' + library text (error)The text in filter is not valid pcap filter syntax (or a combination with the IP / port fields that is invalid).Fix the syntax (pcap-filter), e.g. udp, udp port 3021, host 10.0.0.5 and not port 22. Test the same text in Wireshark's capture-filter box.
SnifferDriverDriver: Stream '<name>' adapter not openedThe filter was compiled before the adapter was opened.Fix the Failed to open adapter error first.
SnifferDriverDriver: Stream '<name>' invalid source: can be only 'local' / 'remote' / 'both' or nothing (default both). using default 'both'
... invalid destination: ...
The value of source / destination is not one of the three words (case does not matter).Use "local", "remote" or "both".
Packet: <src ip>:<port> -> <dst ip>:<port> protocol=<n> (info)Printed for every UDP packet that the adapter delivers to the driver, before the IP / port / direction match is applied.Useful for finding the real addresses. On a busy network it floods the report window and costs CPU; use a narrow filter or capture on a quiet link.
SnifferDriverDriver: Stream '<name>' Adapter not open (error, on receive or send)A read or write was done while the adapter handle is not open.Fix the open error; restart the engine.
SnifferDriverDriver: Stream '<name>' Send failed + library text (error)Sending a raw frame with an output block failed (frame too large, adapter down, adapter does not allow injection).An output block of this driver must contain a complete Ethernet frame (destination MAC, source MAC, type, payload), up to the MTU. Check the size and the adapter state.
Streams: '<name>' block '<block>' header '<hex>' size <N> mismatched with received <M> (UDP payload)
Streams: '<name>' Unknown header ..., Streams: '<name>' message size mismatched ... Unknown header '<hex>' length <N>
The payload of the captured packet does not fit the block definitions. The same messages as in the UDP / TCP stream, because the sniffer feeds payloads to the same code.See section 3 and the socket drivers page.

The status shown for the driver is Driver not initialized when the adapter handle is not open.

3. Payload size mismatch

The driver strips the Ethernet / IP / UDP-or-TCP headers and gives only the payload to the block logic. The block must describe the payload, not the frame: the first block byte is the first byte after the UDP / TCP header. UDP payloads are matched against the block sizes and headerMarkers (one packet = one message); TCP payloads are cut into blocks like a byte stream. See the socket drivers page for the exact behaviour of the messages.

CauseHow to recognize itFix
Block described with the Ethernet / IP header included.The mismatch is always off by 42 (Ethernet + IP + UDP) or 54 (with TCP) bytes, and the printed header is the sender's real data.Describe only the application payload.
Packets bigger than the 10240-byte read buffer: the driver reads a packet into a 10 KB buffer and copies the part that fits.Only large packets mismatch. On Windows, packets sent by this same PC can be captured as one big segment (up to 64 KB) because of checksum / large-send offload.Capture the receiving side instead, or disable large-send offload on the NIC (Disable-NetAdapterLso).
TCP segments out of order, retransmitted or duplicated (packet loss on the sniffed link)."Unknown header" from the TCP logic with small varying N.The sniffer does not re-assemble TCP; it sees segments in capture order. Fix the link loss; use a mirror port / tap that does not drop frames.
Packets dropped by the capture itself (the engine reads too slowly).Random mismatches or missing messages, worse at high packet rates.One packet is taken per read of the stream, so keep "framePerMS": -1 and a fast minor frame, and reduce the traffic with a narrow filter, IPs and ports.
Wrong or missing headerMarker / block size (same as for the socket drivers).Unknown header, constant N.Compare with a Wireshark capture of the same packet.
Several input blocks in the stream.Counters rise faster than the packets (the sniffer code calls the upload once per input block for every packet).If counters look multiplied by the number of blocks, use a single input block with a headerMarker per message layout as a work-around, and report it.

4. Filtering: filter, IP / port, source and destination

5. Other problems

SymptomCauseFix
Engine does not start / wpcap.dll or Packet.dll missing (Windows), libpcap not found (Linux)The capture runtime is not installed (the engine was built with INCLUDE_SNIFFER).Install Npcap (tick the WinPcap-API-compatible mode if the installer offers it) or libpcap; reboot if the installer asks.
The driver name SnifferDriver is unknownThe engine was built without INCLUDE_SNIFFER (the option is OFF by default).Rebuild with -DINCLUDE_SNIFFER=ON.
Adapters list is empty or lacks the loopback adapterNpcap is not installed, installed in "administrator only" mode, or without loopback support.Reinstall Npcap; the loopback adapter appears as \Device\NPF_Loopback. Run the engine as administrator for the test.
Nothing is captured, though Wireshark on the same PC shows the packetsAdapter name differs (several adapters), or the IP / port / direction fields do not match (see section 4), or the packets are not UDP / TCP.Clear all IP / port fields and use both / both to see what arrives, then narrow.
Traffic between two other devices is not seenOn a switched network a NIC only receives traffic addressed to it (and broadcasts).Use a mirror / SPAN port or a network tap, or put the PC in the path (bridge). Promiscuous mode alone is not enough on a switch. Wi-Fi adapters usually do not deliver other devices' frames.
Traffic between two programs on this PC is not seen on the Ethernet adapterLocal traffic does not leave through the NIC.Capture on the loopback adapter (\Device\NPF_Loopback on Windows, lo on Linux).
The sniffer sees the packets but the UDP / TCP stream of the engine does notThe capture library sees the frame before the Windows firewall filters it, so a blocked port is invisible to the sniffer and still blocked for the program.Add the inbound firewall rule — see the socket drivers page.
Report window is flooded with Packet: ... protocol=17The line is printed for every UDP packet on the adapter.Capture on a quiet adapter / use a mirror port that carries only the link of interest.
High CPU loadPromiscuous capture of a busy link, and every packet is parsed.Capture on a dedicated NIC with only the target traffic.
Capture stops after the adapter is unplugged or disabledThe capture handle becomes invalid; a read error is not reported by a message.Reset the engine after the adapter is back.
Messages in the VLAN-tagged or tunnelled (VPN, VXLAN) traffic do not decodeThe IP layer is behind an extra header, or the adapter is a virtual one with another link type (see the Open with '<type>' adapter type line).Capture on the physical adapter, or on the one that carries the plain IP packet.
Message counters and error counters of every block are visible live in System Layout. Use the receive hooks to validate messages without losing data. For direct UDP / TCP connections see the socket drivers page.