Searched refs:caplen (Results 1 - 25 of 84) sorted by relevance

1234

/freebsd-13-stable/contrib/tcpdump/
H A Dprint-802_15_4.c68 u_int caplen = h->caplen; local
74 if (caplen < 3) {
76 return caplen;
84 caplen -= 3;
112 if (caplen < 2) {
118 caplen -= 2;
120 if (caplen < 2) {
127 caplen -= 2;
131 if (caplen <
[all...]
H A Dprint-sunatm.c62 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
69 u_int caplen = h->caplen; local
75 if (caplen < PKT_BEGIN_POS) {
77 return (caplen);
103 caplen -= PKT_BEGIN_POS;
105 atm_print(ndo, vpi, vci, traftype, p, length, caplen);
H A Dprint-bt.c38 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
45 u_int caplen = h->caplen; local
48 if (caplen < BT_HDRLEN) {
52 caplen -= BT_HDRLEN;
59 ND_DEFAULTPRINT(p, caplen);
H A Dprint-ppi.c58 u_int caplen = h->caplen; local
65 if (caplen < sizeof(ppi_header_t)) {
67 return (caplen);
73 if (caplen < len) {
79 return (caplen);
92 caplen -= len;
97 nhdr.caplen = caplen;
105 ND_DEFAULTPRINT(p, caplen);
[all...]
H A Dprint-symantec.c71 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
78 u_int caplen = h->caplen; local
82 if (caplen < sizeof (struct symantec_header)) {
84 return caplen;
91 caplen -= sizeof (struct symantec_header);
103 ND_DEFAULTPRINT(p, caplen);
104 } else if (ethertype_print(ndo, ether_type, p, length, caplen, NULL, NULL) == 0) {
110 ND_DEFAULTPRINT(p, caplen);
H A Dprint-cip.c56 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
62 u_int caplen = h->caplen; local
68 if (cmplen > caplen)
69 cmplen = caplen;
84 llc_hdrlen = llc_print(ndo, p, length, caplen, NULL, NULL);
88 ND_DEFAULTPRINT(p, caplen);
H A Dprint-arcnet.c105 u_int length, u_int caplen);
171 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
177 u_int caplen = h->caplen; local
185 if (caplen < ARC_HDRLEN || length < ARC_HDRLEN) {
187 return (caplen);
206 if (caplen < ARC_HDRNEWLEN || length < ARC_HDRNEWLEN) {
209 return (caplen);
213 if (caplen < ARC_HDRNEWLEN_EXC || length < ARC_HDRNEWLEN_EXC) {
216 return (caplen);
265 u_int caplen = h->caplen; local
320 arcnet_encap_print(netdissect_options *ndo, u_char arctype, const u_char *p, u_int length, u_int caplen) argument
[all...]
H A Dprint-llc.c150 llc_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen, argument
158 if (caplen < 3) {
160 ND_DEFAULTPRINT((const u_char *)p, caplen);
161 return (caplen);
165 ND_DEFAULTPRINT((const u_char *)p, caplen);
190 if (caplen < 4) {
192 ND_DEFAULTPRINT((const u_char *)p, caplen);
193 return (caplen);
197 ND_DEFAULTPRINT((const u_char *)p, caplen);
256 caplen
420 snap_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen, const struct lladdr_info *src, const struct lladdr_info *dst, u_int bridge_pad) argument
[all...]
H A Dprint-ipfc.c92 ipfc_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen) argument
99 if (caplen < IPFC_HDRLEN) {
101 return (caplen);
119 caplen -= IPFC_HDRLEN;
122 llc_hdrlen = llc_print(ndo, p, length, caplen, &src, &dst);
129 ND_DEFAULTPRINT(p, caplen);
138 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
144 return (ipfc_print(ndo, p, h->len, h->caplen));
H A Dprint-sll.c192 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
198 u_int caplen = h->caplen; local
206 if (caplen < SLL_HDR_LEN) {
213 return (caplen);
225 caplen -= SLL_HDR_LEN;
237 return (SLL_HDR_LEN + ieee802_11_radio_print(ndo, p, length, caplen));
264 llc_hdrlen = llc_print(ndo, p, length, caplen, NULL, NULL);
276 ND_DEFAULTPRINT(p, caplen);
284 if (caplen <
[all...]
H A Dprint-nflog.c77 u_int caplen = h->caplen; local
80 if (caplen < (int) sizeof(nflog_hdr_t) || length < (int) sizeof(nflog_hdr_t)) {
95 caplen -= sizeof(nflog_hdr_t);
99 if (caplen < sizeof(nflog_tlv_t) || length < sizeof(nflog_tlv_t)) {
118 if (caplen < size || length < size) {
133 caplen -= sizeof(nflog_tlv_t);
140 caplen -= size;
161 ND_DEFAULTPRINT(p, caplen);
H A Dprint-lane.c78 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
84 lane_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen) argument
88 if (caplen < sizeof(struct lane_controlhdr)) {
108 caplen -= 2;
115 ether_print(ndo, p, length, caplen, lane_hdr_print, p - 2);
121 lane_print(ndo, p, h->len, h->caplen);
H A Dprint-null.c72 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
79 u_int caplen = h->caplen; local
82 if (caplen < NULL_HDRLEN) {
104 caplen -= NULL_HDRLEN;
136 ND_DEFAULTPRINT(p, caplen);
H A Dprint-ether.c130 * FIXME: caplen can and should be derived from ndo->ndo_snapend and p.
134 const u_char *p, u_int length, u_int caplen,
144 if (caplen < ETHER_HDRLEN) {
146 return (caplen);
161 caplen -= ETHER_HDRLEN;
178 llc_hdrlen = llc_print(ndo, p, length, caplen, &src, &dst);
182 ND_DEFAULTPRINT(p, caplen);
194 if (caplen < 4) {
196 return (hdrlen + caplen);
213 caplen
133 ether_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen, void (*print_encap_header)(netdissect_options *ndo, const u_char *), const u_char *encap_header_arg) argument
325 ethertype_print(netdissect_options *ndo, u_short ether_type, const u_char *p, u_int length, u_int caplen, const struct lladdr_info *src, const struct lladdr_info *dst) argument
[all...]
H A Dprint-ap1394.c85 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
92 u_int caplen = h->caplen; local
97 if (caplen < FIREWIRE_HDRLEN) {
106 caplen -= FIREWIRE_HDRLEN;
115 if (ethertype_print(ndo, ether_type, p, length, caplen, &src, &dst) == 0) {
121 ND_DEFAULTPRINT(p, caplen);
H A Dprint-pktap.c95 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
103 u_int caplen = h->caplen; local
109 if (caplen < sizeof(pktap_header_t) || length < sizeof(pktap_header_t)) {
127 if (caplen < hdrlen || length < hdrlen) {
136 caplen -= hdrlen;
149 nhdr.caplen = caplen;
158 ND_DEFAULTPRINT(p, caplen);
H A Dprint-enc.c93 register u_int caplen = h->caplen; local
97 if (caplen < ENC_HDRLEN) {
114 caplen -= ENC_HDRLEN;
H A Dprint-pflog.c117 u_int caplen = h->caplen; local
122 if (caplen < sizeof(uint8_t)) {
124 return (caplen);
135 if (caplen < hdrlen) {
148 caplen -= hdrlen;
175 ND_DEFAULTPRINT(p, caplen);
H A Dprint-ipnet.c65 ipnet_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen) argument
69 if (caplen < sizeof(ipnet_hdr_t))
76 caplen -= sizeof(ipnet_hdr_t);
97 ND_DEFAULTPRINT(p, caplen);
108 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
115 ipnet_print(ndo, p, h->len, h->caplen);
H A Dprint-medsa.c89 u_int caplen)
134 ND_DEFAULTPRINT((const u_char *)medsa, caplen);
141 const u_char *bp, u_int length, u_int caplen,
154 medsa_print_full(ndo, medsa, caplen);
158 caplen -= 8;
163 if (llc_print(ndo, bp, length, caplen, src, dst) < 0) {
166 ND_DEFAULTPRINT(bp, caplen);
174 if (ethertype_print(ndo, ether_type, bp, length, caplen, src, dst) == 0) {
183 ND_DEFAULTPRINT(bp, caplen);
87 medsa_print_full(netdissect_options *ndo, const struct medsa_pkthdr *medsa, u_int caplen) argument
140 medsa_print(netdissect_options *ndo, const u_char *bp, u_int length, u_int caplen, const struct lladdr_info *src, const struct lladdr_info *dst) argument
H A Dprint-atm.c221 const u_char *p, int length, int caplen)
225 llc_hdrlen = llc_print(ndo, p, length, caplen, NULL, NULL);
229 ND_DEFAULTPRINT(p, caplen);
244 * 'h->len' is the length of the packet off the wire, and 'h->caplen'
251 u_int caplen = h->caplen; local
256 if (caplen < 1 || length < 1) {
258 return (caplen);
273 if (caplen < 3 || length < 3) {
275 return (caplen);
220 atm_llc_print(netdissect_options *ndo, const u_char *p, int length, int caplen) argument
385 atm_print(netdissect_options *ndo, u_int vpi, u_int vci, u_int traftype, const u_char *p, u_int length, u_int caplen) argument
[all...]
H A Dprint-sl.c62 register u_int caplen = h->caplen; local
66 if (caplen < SLIP_HDRLEN || length < SLIP_HDRLEN) {
68 return (caplen);
71 caplen -= SLIP_HDRLEN;
79 return (caplen + SLIP_HDRLEN);
82 if (caplen < 1 || length < 1) {
84 return (caplen + SLIP_HDRLEN);
105 register u_int caplen = h->caplen; local
[all...]
H A Dprint.c330 ndo->ndo_snapend = sp + h->caplen;
338 ndo->ndo_snapend = sp + h->caplen;
347 hex_and_ascii_print(ndo, "\n\t", sp, h->caplen);
354 if (h->caplen > hdrlen)
356 h->caplen - hdrlen);
366 hex_print(ndo, "\n\t", sp, h->caplen);
373 if (h->caplen > hdrlen)
375 h->caplen - hdrlen);
385 ascii_print(ndo, sp, h->caplen);
392 if (h->caplen > hdrle
[all...]
/freebsd-13-stable/contrib/libpcap/
H A Dpcap-common.c1315 u_int caplen = hdr->caplen; local
1321 if (caplen < (u_int) sizeof(struct sll_header) ||
1335 if (caplen < (u_int) sizeof(struct sll_header) + sizeof(chdr->can_id) ||
1370 if (hdr->caplen < offset)
1377 if (hdr->caplen < offset)
1384 if (hdr->caplen < offset)
1389 if (hdr->caplen < offset)
1394 if (hdr->caplen < offset)
1399 if (hdr->caplen < offse
1508 u_int caplen = hdr->caplen; local
[all...]
H A Dpcap-enet.c57 register int cc, caplen; local
76 caplen = ph->tap.th_wirelen > snaplen ? snaplen : ph->tap
79 ph->tap.th_wirelen, caplen)) {
84 ph->tap.th_wirelen, caplen);
91 caplen = cc > snaplen ? snaplen : cc ;
92 if (bpf_filter(fcode, buf.hdr.packet, cc, caplen)) {
95 (*printit)(buf.hdr.packet, &tv, cc, caplen);

Completed in 279 milliseconds

1234