Pcap (Packet Capturing Library)

Overview

This section describes types and facilities used when programming Pcap (Packet Capturing Library) More…

import "io_pcap.jncx"

// enums

bitflag enum io.PcapEvents;
enum io.PcapLinkType;

// structs

struct io.PcapAddress;
struct io.PcapDeviceDesc;

// classes

class io.Pcap;
class io.PcapFilter;

// global functions

io.PcapDeviceDesc const* io.createPcapDeviceDescList(size_t* count = null);

Detailed Documentation

This section describes types and facilities used when programming Pcap (Packet Capturing Library)

Global Functions

io.PcapDeviceDesc const* io.createPcapDeviceDescList(size_t* count = null)

Enumerates all available devices Pcap can start a live capture session on.

count argument can be used to obtain the total number of devices in the resulting list.

Returns a pointer to the very first io.PcapDeviceDesc in the resulting list. You can walk through the list by inspecting io.PcapDeviceDesc.m_next field:

io.PcapDeviceDesc const* deviceDesc = io.createPcapDeviceDescList();
for (; deviceDesc; deviceDesc = deviceDesc.m_next) {
    // add device to the combo box...
}