sec_vt_header: dissect drep
[wireshark-wip.git] / wiretap / pcap-common.h
blob734d81856fa34faaf0d99344eedee67e58a83da7
1 /* pcap-common.h
2 * Declarations for code common to libpcap and pcap-NG file formats
4 * $Id$
6 * Wiretap Library
7 * Copyright (c) 1998 by Gilbert Ramirez <gram@alumni.rice.edu>
9 * File format support for pcap-ng file format
10 * Copyright (c) 2007 by Ulf Lamping <ulf.lamping@web.de>
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
27 #ifndef __W_PCAP_COMMON_H__
28 #define __W_PCAP_COMMON_H__
30 #include <glib.h>
31 #include <wtap.h>
32 #include "ws_symbol_export.h"
34 extern int pcap_process_pseudo_header(FILE_T fh, int file_type, int wtap_encap,
35 guint packet_size, gboolean check_packet_size,
36 struct wtap_pkthdr *phdr, int *err, gchar **err_info);
38 extern void pcap_read_post_process(int file_type, int wtap_encap,
39 union wtap_pseudo_header *pseudo_header,
40 guint8 *pd, guint packet_size, gboolean bytes_swapped, int fcs_len);
42 extern int pcap_get_phdr_size(int encap,
43 const union wtap_pseudo_header *pseudo_header);
45 extern gboolean pcap_write_phdr(wtap_dumper *wdh, int wtap_encap,
46 const union wtap_pseudo_header *pseudo_header, int *err);
48 #endif