PCAP Dumper

pcapkit.dumpkit.pcap is the dumper for pcapkit implementation, specifically for PCAP format, which is alike those described in dictdumper.

class pcapkit.dumpkit.pcap.PCAPIO(fname, *, protocol, byteorder='little', nanosecond=False, **kwargs)[source]

Bases: DumperBase

PCAP file dumper.

Parameters:
  • fname (str) – output file name

  • protocol (LinkType | IntEnum | IntEnum | str | int) – data link type

  • byteorder (Literal['big', 'little']) – header byte order

  • nanosecond (bool) – nanosecond-resolution file flag

  • **kwargs (Any) – arbitrary keyword arguments

property kind: Literal['pcap']

File format of current dumper.