diff options
author | Andreas Gruenbacher <andreas.gruenbacher@gmail.com> | 2017-02-02 19:40:15 +0100 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-02-02 21:18:52 +0000 |
commit | 844cf1ac9063553b08444c0d56b96ddf09fcc558 (patch) | |
tree | d5d1c894dfda34633b7df1ffb0aefc5b31431945 /epan/dissectors | |
parent | 0da95c129e0d10486ca6badce657db20e8dc02e0 (diff) |
NFSv4.2 mode_umask support
Add support for the NFSV4.2 mode_umask attribute which will be initially
supported by Linux v4.10.
Change-Id: Id98e20cd0ed93bf7ad9b2246e9e05299f3d7a9fc
Reviewed-on: https://code.wireshark.org/review/19921
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors')
-rw-r--r-- | epan/dissectors/packet-nfs.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/epan/dissectors/packet-nfs.c b/epan/dissectors/packet-nfs.c index 6d1dd3b095..5f2ce42125 100644 --- a/epan/dissectors/packet-nfs.c +++ b/epan/dissectors/packet-nfs.c @@ -420,6 +420,7 @@ static int hf_nfs4_fattr_layout_blksize = -1; static int hf_nfs4_fattr_security_label_lfs = -1; static int hf_nfs4_fattr_security_label_pi = -1; static int hf_nfs4_fattr_security_label_context = -1; +static int hf_nfs4_fattr_umask_mask = -1; static int hf_nfs4_who = -1; static int hf_nfs4_server = -1; static int hf_nfs4_fslocation = -1; @@ -6133,6 +6134,8 @@ static const value_string fattr4_names[] = { { FATTR4_CHANGE_ATTR_TYPE, "Change_Attr_Type" }, #define FATTR4_SECURITY_LABEL 80 { FATTR4_SECURITY_LABEL, "Security_Label" }, +#define FATTR4_MODE_UMASK 81 + { FATTR4_MODE_UMASK, "Mode_Umask" }, { 0, NULL } }; static value_string_ext fattr4_names_ext = VALUE_STRING_EXT_INIT(fattr4_names); @@ -6717,6 +6720,14 @@ dissect_nfs4_security_label(tvbuff_t *tvb, proto_tree *tree, int offset) return offset; } +static int +dissect_nfs4_mode_umask(tvbuff_t *tvb, proto_tree *tree, int offset) +{ + offset = dissect_nfs4_mode(tvb, offset, tree); + offset = dissect_rpc_uint32(tvb, tree, hf_nfs4_fattr_umask_mask, offset); + return offset; +} + #define FATTR4_BITMAP_ONLY 0 #define FATTR4_DISSECT_VALUES 1 @@ -7119,6 +7130,10 @@ dissect_nfs4_fattrs(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *t offset = dissect_nfs4_security_label(tvb, attr_tree, offset); break; + case FATTR4_MODE_UMASK: + offset = dissect_nfs4_mode_umask(tvb, attr_tree, offset); + break; + default: break; } @@ -12509,6 +12524,10 @@ proto_register_nfs(void) "label_format", "nfs.fattr4.security_label.lfs", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }}, + { &hf_nfs4_fattr_umask_mask, { + "umask", "nfs.fattr4.umask", FT_UINT32, BASE_OCT, + NULL, 0, NULL, HFILL }}, + { &hf_nfs4_fattr_security_label_pi, { "policy_id", "nfs.fattr4.security_label.pi", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }}, |