Support for NSH with VXLAN-GPE encapsulation
authorsjha3 <sjha3@ncsu.edu>
Sat, 2 Jul 2016 23:09:50 +0000 (19:09 -0400)
committerMichael Mann <mmann78@netscape.net>
Sun, 3 Jul 2016 01:42:55 +0000 (01:42 +0000)
Bug: 12271
Change-Id: I8481c4ab69c4432985acc79bff7818e6857fa1cb
Reviewed-on: https://code.wireshark.org/review/16251
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
epan/dissectors/packet-nsh.c

index 23642cb81334e4c74dece409c5653143fe740a07..49415bb3436cdbdb111036ebc38ba69b469d0973 100644 (file)
@@ -3,6 +3,8 @@
  *Author: Chidambaram Arunachalam <carunach@cisco.com>
  *Copyright 2016, ciscoSystems Inc.
  *
+ *(c) Copyright 2016, Sumit Kumar Jha <sjha3@ncsu.edu>
+ * Support for VXLAN GPE encapsulation
  *
  *Wireshark - Network traffic analyzer
  *By Gerald Combs <gerald@wireshark.org>
@@ -32,6 +34,7 @@
 #include <epan/ipproto.h>
 #include <epan/decode_as.h>
 
+#define VXLAN_NSH 4
 #define MD_TYPE_1 1
 #define MD_TYPE_2 2
 
@@ -360,6 +363,7 @@ proto_reg_handoff_nsh(void)
 
        nsh_handle = create_dissector_handle(dissect_nsh, proto_nsh);
        dissector_add_uint("gre.proto", ETHERTYPE_NSH, nsh_handle);
+       dissector_add_uint("vxlan.next_proto", VXLAN_NSH, nsh_handle);
 
        dissector_ip = find_dissector_add_dependency("ip", proto_nsh);
        dissector_ipv6 = find_dissector_add_dependency("ipv6", proto_nsh);