tcpdump mailing list archives

[PATCH] For Babel, recognise both UDP/6696 and UDP/6697.


From: Juliusz Chroboczek <jch () pps jussieu fr>
Date: Sat, 27 Aug 2011 16:36:10 +0200

IANA has reallocated the Babel port; it is now 6696.  This patch makes
tcpdump recognise both the old and the new Babel ports.
---
 print-udp.c |    2 +-
 udp.h       |    3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/print-udp.c b/print-udp.c
index da6cfd3..885d42e 100644
--- a/print-udp.c
+++ b/print-udp.c
@@ -609,7 +609,7 @@ udp_print(register const u_char *bp, u_int length,
                        ripng_print((const u_char *)(up + 1), length);
                else if (ISPORT(DHCP6_SERV_PORT) || ISPORT(DHCP6_CLI_PORT))
                        dhcp6_print((const u_char *)(up + 1), length);
-               else if (ISPORT(BABEL_PORT))
+               else if (ISPORT(BABEL_PORT) || ISPORT(BABEL_PORT_OLD))
                        babel_print((const u_char *)(up + 1), length);
 #endif /*INET6*/
                /*
diff --git a/udp.h b/udp.h
index 0dc5227..ad1d850 100644
--- a/udp.h
+++ b/udp.h
@@ -90,5 +90,6 @@ struct udphdr {
 #define RIPNG_PORT 521         /*XXX*/
 #define DHCP6_SERV_PORT 546    /*XXX*/
 #define DHCP6_CLI_PORT 547     /*XXX*/
-#define BABEL_PORT 6697
+#define BABEL_PORT 6696
+#define BABEL_PORT_OLD 6697
 #endif
-- 
1.7.5.4

-
This is the tcpdump-workers list.
Visit https://cod.sandelman.ca/ to unsubscribe.


Current thread: