diff options
author | Jeff Layton <jlayton@redhat.com> | 2010-08-03 10:19:50 -0400 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2010-08-05 17:17:50 +0000 |
commit | ba5dadbf4e7b531bd7ccecffb4d3935c80a3372e (patch) | |
tree | 48b8f683464c147a2ac11c3fedda73fb66e9ef52 /fs | |
parent | 5acfec2502cf60a91dc1959e476b588ecb3a1b8a (diff) | |
download | lwn-ba5dadbf4e7b531bd7ccecffb4d3935c80a3372e.tar.gz lwn-ba5dadbf4e7b531bd7ccecffb4d3935c80a3372e.zip |
cifs: account for new creduid=0x%x parameter in spnego upcall string
The commit that added the creduid=0x%x parameter failed to increase the
buffer allocation to account for it.
Reported-by: J. Bruce Fields <bfields@fieldses.org>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/cifs/cifs_spnego.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/cifs/cifs_spnego.c b/fs/cifs/cifs_spnego.c index 6effccff85a5..87044906cd1f 100644 --- a/fs/cifs/cifs_spnego.c +++ b/fs/cifs/cifs_spnego.c @@ -84,6 +84,9 @@ struct key_type cifs_spnego_key_type = { /* strlen of ";uid=0x" */ #define UID_KEY_LEN 7 +/* strlen of ";creduid=0x" */ +#define CREDUID_KEY_LEN 11 + /* strlen of ";user=" */ #define USER_KEY_LEN 6 @@ -107,6 +110,7 @@ cifs_get_spnego_key(struct cifsSesInfo *sesInfo) IP_KEY_LEN + INET6_ADDRSTRLEN + MAX_MECH_STR_LEN + UID_KEY_LEN + (sizeof(uid_t) * 2) + + CREDUID_KEY_LEN + (sizeof(uid_t) * 2) + USER_KEY_LEN + strlen(sesInfo->userName) + PID_KEY_LEN + (sizeof(pid_t) * 2) + 1; |