• Home
  • Raw
  • Download

Lines Matching +full:print +full:- +full:flags +full:. +full:pcap

3  *	The Regents of the University of California.  All rights reserved.
13 * Lawrence Berkeley Laboratory and its contributors.'' Neither the name of
16 * written permission.
19 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
24 "@(#) $Header: /tcpdump/master/tcpdump/print-sl.c,v 1.65 2005/04/06 21:32:42 mcr Exp $ (LBL)";
28 #include "config.h"
31 #include <tcpdump-stdinc.h>
33 #include <pcap.h>
34 #include <stdio.h>
36 #include "interface.h"
37 #include "addrtoname.h"
38 #include "extract.h" /* must come after interface.h */
40 #include "ip.h"
41 #include "tcp.h"
42 #include "slip.h"
43 #include "slcompress.h"
54 register u_int caplen = h->caplen; in sl_if_print()
55 register u_int length = h->len; in sl_if_print()
63 length -= SLIP_HDRLEN; in sl_if_print()
89 register u_int caplen = h->caplen; in sl_bsdos_if_print()
90 register u_int length = h->len; in sl_bsdos_if_print()
98 length -= SLIP_HDRLEN; in sl_bsdos_if_print()
127 for (i = SLX_CHDR; i < SLX_CHDR + CHDR_LEN - 1; ++i) in sliplink_print()
128 printf("%02x.", p[i]); in sliplink_print()
129 printf("%02x: ", p[SLX_CHDR + CHDR_LEN - 1]); in sliplink_print()
140 * The connection id is stored in the IP protocol field. in sliplink_print()
142 * has restored the IP header copy to IPPROTO_TCP. in sliplink_print()
144 lastconn = ((struct ip *)&p[SLX_CHDR])->ip_p; in sliplink_print()
147 lastlen[dir][lastconn] = length - (hlen << 2); in sliplink_print()
157 printf("slip-%d!: ", p[SLX_CHDR]); in sliplink_print()
195 register u_int flags, hlen; in compressed_sl_print() local
197 flags = *cp++; in compressed_sl_print()
198 if (flags & NEW_C) { in compressed_sl_print()
207 switch (flags & SPECIALS_MASK) { in compressed_sl_print()
217 if (flags & NEW_U) in compressed_sl_print()
219 if (flags & NEW_W) in compressed_sl_print()
221 if (flags & NEW_A) in compressed_sl_print()
223 if (flags & NEW_S) in compressed_sl_print()
227 if (flags & NEW_I) in compressed_sl_print()
231 * 'hlen' is the length of the uncompressed TCP/IP header (in words). in compressed_sl_print()
232 * 'cp - chdr' is the length of the compressed header. in compressed_sl_print()
233 * 'length - hlen' is the amount of data in the packet. in compressed_sl_print()
237 lastlen[dir][lastconn] = length - (hlen << 2); in compressed_sl_print()
238 printf(" %d (%ld)", lastlen[dir][lastconn], (long)(cp - chdr)); in compressed_sl_print()