Whamcloud - gitweb
LU-8795 gss: Prevent callout truncation with non-root users 00/23600/2
authorJeremy Filizetti <jeremy.filizetti@gmail.com>
Sat, 5 Nov 2016 23:09:05 +0000 (19:09 -0400)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 7 Nov 2016 15:46:16 +0000 (15:46 +0000)
The SK changes included an additional svc_type field in the callout
which was initialized to the '0'.  Since the defaulted value is
not changed prior to callout for non-root users this breaks those
kerberos users.  SK is not affected because all users share the same
key context which is limited to the root user.

Signed-off-by: Jeremy Filizetti <jeremy.filizetti@gmail.com>
Change-Id: I2c906714ee6ad6a0091ac922298aee7b63b9e856
Reviewed-on: http://review.whamcloud.com/23600
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>

index bafe53b..2ebaeca 100644 (file)
@@ -724,7 +724,7 @@ struct ptlrpc_cli_ctx * gss_sec_lookup_ctx_kr(struct ptlrpc_sec *sec,
         char                    *coinfo;
         int                      coinfo_size;
        const char              *sec_part_flags = "";
-       char                     svc_flag = '\0';
+       char                     svc_flag = '-';
         LASSERT(imp != NULL);