diff options
author | Swapnil Roy <swapnil.advent@gmail.com> | 2019-02-17 19:29:29 +0530 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2019-02-17 19:01:20 +0000 |
commit | 4b668430d1b1a0222684c8d70e897505b7685bbb (patch) | |
tree | be8d818bfedada0f18d787fede320164571af167 /epan/dissectors/packet-nas_5gs.c | |
parent | 9a76603ffdbc7cef368f28bf7aa82215eb39ae18 (diff) |
NAS 5Gs: Ignoring MM capability spare octets
Change-Id: Ib75baa07cefb054ceedb71f0d9d9961f22d66a5e
Reviewed-on: https://code.wireshark.org/review/32074
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-nas_5gs.c')
-rw-r--r-- | epan/dissectors/packet-nas_5gs.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/epan/dissectors/packet-nas_5gs.c b/epan/dissectors/packet-nas_5gs.c index 6fd5738c85..4d78c28e04 100644 --- a/epan/dissectors/packet-nas_5gs.c +++ b/epan/dissectors/packet-nas_5gs.c @@ -434,9 +434,11 @@ get_ext_ambr_unit(guint32 unit, const char **unit_str) */ static guint16 de_nas_5gs_mm_5gmm_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, - guint32 offset, guint len _U_, + guint32 offset, guint len, gchar *add_string _U_, int string_len _U_) { + guint32 curr_offset; + static const int * flags[] = { &hf_nas_5gs_spare_b7, &hf_nas_5gs_spare_b6, @@ -449,9 +451,13 @@ de_nas_5gs_mm_5gmm_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, NULL }; - proto_tree_add_bitmask_list(tree, tvb, offset, 1, flags, ENC_BIG_ENDIAN); + curr_offset = offset; + proto_tree_add_bitmask_list(tree, tvb, curr_offset, 1, flags, ENC_BIG_ENDIAN); + curr_offset++; - return 1; + EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_nas_5gs_extraneous_data); + + return (curr_offset - offset); } /* |