Update the output of some tests accordingly.
ndo->ndo_protocol = "arcnet_if";
if (caplen < ARC_HDRLEN || length < ARC_HDRLEN) {
- ND_PRINT("[|arcnet]");
+ nd_print_trunc(ndo);
return (caplen);
}
ndo->ndo_protocol = "arcnet_linux_if";
if (caplen < ARC_LINUX_HDRLEN || length < ARC_LINUX_HDRLEN) {
- ND_PRINT("[|arcnet]");
+ nd_print_trunc(ndo);
return (caplen);
}
default:
archdrlen = ARC_LINUX_HDRNEWLEN;
if (caplen < ARC_LINUX_HDRNEWLEN || length < ARC_LINUX_HDRNEWLEN) {
- ND_PRINT("[|arcnet]");
+ nd_print_trunc(ndo);
return (caplen);
}
break;
return (length);
}
if (!ND_TTEST_LEN(bp, sizeof(*lp))) {
- ND_PRINT(" [|llap]");
+ nd_print_trunc(ndo);
return (0); /* cut short by the snapshot length */
}
lp = (const struct LAP *)bp;
ap = (const struct aarp *)bp;
if (!ND_TTEST_SIZE(ap)) {
/* Just bail if we don't have the whole chunk. */
- ND_PRINT(" [|aarp]");
+ nd_print_trunc(ndo);
return;
}
if (length < sizeof(*ap)) {
ndo->ndo_protocol = "ether";
if (caplen < ETHER_HDRLEN) {
- ND_PRINT("[|ether]");
+ nd_print_trunc(ndo);
return (caplen);
}
if (length < ETHER_HDRLEN) {
- ND_PRINT("[|ether]");
+ nd_print_trunc(ndo);
return (length);
}
*/
ndo->ndo_protocol = "netanalyzer_if";
if (h->len < 4 || h->caplen < 4) {
- ND_PRINT("[|netanalyzer]");
+ nd_print_trunc(ndo);
return (h->caplen);
}
*/
ndo->ndo_protocol = "netanalyzer_transparent_if";
if (h->len < 12 || h->caplen < 12) {
- ND_PRINT("[|netanalyzer-transparent]");
+ nd_print_trunc(ndo);
return (h->caplen);
}
return cp;
trunc:
- ND_PRINT(" [|isakmp]");
+ nd_print_trunc(ndo);
return NULL;
}
return cp;
trunc:
- ND_PRINT(" [|isakmp]");
+ nd_print_trunc(ndo);
return NULL;
}
ep = ndo->ndo_snapend;
if ((const struct isakmp *)ep < p + 1) {
- ND_PRINT("[|isakmp]");
+ nd_print_trunc(ndo);
return;
}
}
trunc:
- ND_PRINT("[|isakmp]");
+ nd_print_trunc(ndo);
return;
}
trunc:
ndo->ndo_snapend = se;
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
}
handle_ppp(ndo, proto, p, length);
return (hdr_len);
trunc:
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
return (0);
}
ndo->ndo_protocol = "ppp_if";
if (caplen < PPP_HDRLEN) {
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
return (caplen);
}
ndo->ndo_protocol = "ppp_hdlc_if";
if (caplen < 2) {
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
return (caplen);
}
case PPP_ADDRESS:
if (caplen < 4 || length < 4) {
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
return (caplen);
}
default:
if (caplen < 4) {
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
return (caplen);
}
ndo->ndo_protocol = "ppp_bsdos_if";
if (caplen < PPP_BSDI_HDRLEN) {
- ND_PRINT("[|ppp]");
+ nd_print_trunc(ndo);
return (caplen);
}
* adds this many bytes of header to every packet in a
* cooked socket capture.
*/
- ND_PRINT("[|sll]");
+ nd_print_trunc(ndo);
return (caplen);
}
-IP 48.48.48.48.4500 > 48.48.48.48.12336: [|isakmp]
+IP 48.48.48.48.4500 > 48.48.48.48.12336: [|isakmp_rfc3948]
30:30:30:30:30:30 > 30:30:30:30:30:30, ethertype Unknown (0x3030), length 262144:
0x0000: 3030 3030 3030 3030 3030 3030 3030 3030 0000000000000000
0x0010: 3030 3030 3030 3030 3030 3030 000000000000
-IP 48.48.48.48.4500 > 48.48.48.48.12336: [|isakmp]
+IP 48.48.48.48.4500 > 48.48.48.48.12336: [|isakmp_rfc3948]
127.0.0.229.12416 > 127.236.0.1.1701: l2tp:[TL](560/2056) ACCM(AVP too short) [|l2tp]
IP (tos 0x30, ttl 48, id 12336, offset 0, flags [none], proto UDP (17), length 12336, bad cksum 1f51 (->ab5d)!)
127.0.0.0.0 > 0.0.0.0.2048: UDP, bad length 17704 > 12308
-[|ether]
+ [|ether]
IP (tos 0x30, ttl 48, id 12336, offset 0, flags [none], proto UDP (17), length 12336, bad cksum 1f51 (->2a8b)!)
127.0.0.229.12416 > 127.236.0.1.1701: l2tp:[TL](560/2056) AVP-#48() [|l2tp]
IP (tos 0x30, ttl 48, id 12331, offset 0, flags [none], proto UDP (17), length 8752, bad cksum 1f51 (->3890)!)
127.0.0.229.12416 > 127.236.0.1.1701: l2tp:[TL](560/2056) ACCM(AVP too short) [|l2tp]
IP (tos 0x30, ttl 48, id 12336, offset 0, flags [none], proto UDP (17), length 12336, bad cksum 1f51 (->ab5d)!)
127.0.0.0.0 > 0.0.0.0.2048: UDP, bad length 17704 > 12308
-[|ether]
+ [|ether]
IP (tos 0x30, ttl 48, id 12336, offset 0, flags [none], proto UDP (17), length 12336, bad cksum 1f51 (->2a8b)!)
127.0.0.229.12416 > 127.236.0.1.1701: l2tp:[TL](560/2056) AVP-#48() [|l2tp]
IP (tos 0x30, ttl 48, id 12331, offset 0, flags [none], proto UDP (17), length 8752, bad cksum 1f51 (->3890)!)
IP 192.168.0.24.40896 > 192.168.0.134.47808: UDP, length 30
IP 192.168.0.24.47808 > 192.168.0.255.47808: UDP, length 20
IP 192.168.0.9.37123 > 97.34.1.224.8472: OTV, flags [I] (0x9d), overlay 12124160, instance 4587520
-[|ether]
+ [|ether]
[|pktap_if]
-[|ppp]
+ [|ppp_hdlc_if]