| Wireshark 4.7.3 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
pcap-common.h
Go to the documentation of this file.
1
13
14#ifndef __W_PCAP_COMMON_H__
15#define __W_PCAP_COMMON_H__
16
17#include "wtap.h"
18
25 extern unsigned wtap_max_snaplen_for_encap(int wtap_encap);
26
46 extern int pcap_process_pseudo_header(FILE_T fh, bool is_nokia,
47 int wtap_encap, unsigned packet_size, wtap_rec *rec,
48 int *err, char **err_info);
49
64 extern void pcap_read_post_process(bool is_nokia, int wtap_encap,
65 wtap_rec *rec, bool bytes_swapped, int fcs_len);
66
74 extern unsigned pcap_get_phdr_size(int encap,
75 const union wtap_pseudo_header *pseudo_header);
76
86 extern bool pcap_write_phdr(wtap_dumper *wdh, int wtap_encap,
87 const union wtap_pseudo_header *pseudo_header, int *err);
88
89#endif
pcap_read_post_process
void pcap_read_post_process(bool is_nokia, int wtap_encap, wtap_rec *rec, bool bytes_swapped, int fcs_len)
Performs post-read fixups on a pcap packet record.
Definition pcap-common.c:2617
pcap_get_phdr_size
unsigned pcap_get_phdr_size(int encap, const union wtap_pseudo_header *pseudo_header)
Retrieves the size of the pseudo-header for a given encapsulation type and pseudo-header.
Definition pcap-common.c:2737
pcap_process_pseudo_header
int pcap_process_pseudo_header(FILE_T fh, bool is_nokia, int wtap_encap, unsigned packet_size, wtap_rec *rec, int *err, char **err_info)
Reads and processes the pseudo-header for a pcap packet record.
Definition pcap-common.c:2317
wtap_max_snaplen_for_encap
unsigned wtap_max_snaplen_for_encap(int wtap_encap)
Get the maximum snapshot length for a given capture encapsulation type.
Definition pcap-common.c:795
pcap_write_phdr
bool pcap_write_phdr(wtap_dumper *wdh, int wtap_encap, const union wtap_pseudo_header *pseudo_header, int *err)
Writes a packet header to a dump file.
Definition pcap-common.c:2843
wtap_dumper
Wiretap dumper handle and associated state.
Definition wtap_module.h:163
wtap_rec
Represents a single capture record read from or written to a capture file, regardless of record type.
Definition wtap.h:1600
wtap_pseudo_header
Top-level union of all Wiretap pseudo-headers.
Definition wtap.h:1355
wtap.h