XBinder  Version 2.9.x
Functions
rtxPcapFile.h File Reference

Data structures and functions for processing PCAP files. More...

#include "rtxsrc/rtxContext.h"

Go to the source code of this file.

Functions

EXTERNRT int rtxDecPcapHdr (OSCTXT *pctxt, pcap_hdr_t *pPcapHdr, OSBOOL *pswapped)
 This function decodes a PCAP global header structure. More...
 
EXTERNRT int rtxDecPcapRecHdr (OSCTXT *pctxt, pcaprec_hdr_t *pPcapRecHdr, OSBOOL swapped)
 This function decodes a PCAP record header structure. More...
 
EXTERNRT int rtxDecEtherHdr (OSCTXT *pctxt, ether_header_t *pEtherHdr, OSBOOL swapped)
 This function decodes an Ethernet header structure. More...
 
EXTERNRT void rtxPrintPcapHdr (const pcap_hdr_t *pPcapHdr)
 This function prints the contents of a PCAP global header structure to stdout. More...
 
EXTERNRT void rtxPrintPcapRecHdr (const pcaprec_hdr_t *pPcapRecHdr)
 This function prints the contents of a PCAP record header structure to stdout. More...
 

Detailed Description

Data structures and functions for processing PCAP files.

Definition in file rtxPcapFile.h.

Function Documentation

◆ rtxDecEtherHdr()

EXTERNRT int rtxDecEtherHdr ( OSCTXT pctxt,
ether_header_t *  pEtherHdr,
OSBOOL  swapped 
)

This function decodes an Ethernet header structure.

Parameters
pctxtPointer to context holding message to decode.
pEtherHdrPointer to structure to receive decoded header. If pointer is NULL, header record will be skipped.
swappedBoolean indicating if byte swapping needs to be done when decoding integer values.
Returns
Status of decode operation: 0 = success, negative value = error

◆ rtxDecPcapHdr()

EXTERNRT int rtxDecPcapHdr ( OSCTXT pctxt,
pcap_hdr_t *  pPcapHdr,
OSBOOL *  pswapped 
)

This function decodes a PCAP global header structure.

Parameters
pctxtPointer to context holding message to decode.
pPcapHdrPointer to structure to receive decoded header. If pointer is NULL, header record will be skipped.
pswappedBoolean to receive results of magic number analysis to determine bytes need to be swapped when decoding integer values.
Returns
Status of decode operation: 0 = success, negative value = error

◆ rtxDecPcapRecHdr()

EXTERNRT int rtxDecPcapRecHdr ( OSCTXT pctxt,
pcaprec_hdr_t *  pPcapRecHdr,
OSBOOL  swapped 
)

This function decodes a PCAP record header structure.

Parameters
pctxtPointer to context holding message to decode.
pPcapRecHdrPointer to structure to receive decoded header. If pointer is NULL, header record will be skipped.
swappedBoolean indicating if byte swapping needs to be done when decoding integer values.
Returns
Status of decode operation: 0 = success, negative value = error

◆ rtxPrintPcapHdr()

EXTERNRT void rtxPrintPcapHdr ( const pcap_hdr_t *  pPcapHdr)

This function prints the contents of a PCAP global header structure to stdout.

Parameters
pPcapHdrPointer to structure to print.

◆ rtxPrintPcapRecHdr()

EXTERNRT void rtxPrintPcapRecHdr ( const pcaprec_hdr_t *  pPcapRecHdr)

This function prints the contents of a PCAP record header structure to stdout.

Parameters
pPcapRecHdrPointer to structure to print.