summaryrefslogtreecommitdiffstats
path: root/usr.sbin/tcpdump/print-ip.c
diff options
context:
space:
mode:
authordlg <dlg@openbsd.org>2019-09-19 23:23:58 +0000
committerdlg <dlg@openbsd.org>2019-09-19 23:23:58 +0000
commit1e14b8a65fc56eddf941b689db9239153f8a81be (patch)
treedda8374e371b362a77fbef2428768961be041968 /usr.sbin/tcpdump/print-ip.c
parentAdd RK3328 GMAC clocks. (diff)
downloadwireguard-openbsd-1e14b8a65fc56eddf941b689db9239153f8a81be.tar.xz
wireguard-openbsd-1e14b8a65fc56eddf941b689db9239153f8a81be.zip
print the IPs on ESP packets.
this was lost when tcpdump learnt to look inside udpencap. found by, and ok markus@
Diffstat (limited to 'usr.sbin/tcpdump/print-ip.c')
-rw-r--r--usr.sbin/tcpdump/print-ip.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/usr.sbin/tcpdump/print-ip.c b/usr.sbin/tcpdump/print-ip.c
index 5d6d8735110..b4e17f29b97 100644
--- a/usr.sbin/tcpdump/print-ip.c
+++ b/usr.sbin/tcpdump/print-ip.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: print-ip.c,v 1.51 2018/10/22 16:12:45 kn Exp $ */
+/* $OpenBSD: print-ip.c,v 1.52 2019/09/19 23:23:58 dlg Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997
@@ -472,6 +472,9 @@ ip_print(const u_char *bp, u_int length)
#define IPPROTO_ESP 50
#endif
case IPPROTO_ESP:
+ (void)printf("%s > %s: ",
+ ipaddr_string(&ip->ip_src),
+ ipaddr_string(&ip->ip_dst));
esp_print(cp, len, (const u_char *)ip);
break;