diff options
author | Steve French <sfrench@us.ibm.com> | 2005-12-01 17:12:59 -0800 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2005-12-01 17:12:59 -0800 |
commit | 83451879ab213e152c6fe5c743f257ba58d7acd1 (patch) | |
tree | 8b50b75368d74607dfda6b7bc5647419ebfa015a /fs/cifs/misc.c | |
parent | 5666c0947ede0432ba5148570aa66ffb9febff5b (diff) | |
download | op-kernel-dev-83451879ab213e152c6fe5c743f257ba58d7acd1.zip op-kernel-dev-83451879ab213e152c6fe5c743f257ba58d7acd1.tar.gz |
[CIFS] Use fsuid (fsgid) more consistently instead of uid/gid in
assembling smb requests when setuids and Linux protocol extensions enabled
and in checking more matching sessions in multiuser mount mode.
Pointed out by Shaggy.
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/misc.c')
-rw-r--r-- | fs/cifs/misc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/cifs/misc.c b/fs/cifs/misc.c index 94baf6c..9af37f8 100644 --- a/fs/cifs/misc.c +++ b/fs/cifs/misc.c @@ -1,7 +1,7 @@ /* * fs/cifs/misc.c * - * Copyright (C) International Business Machines Corp., 2002,2004 + * Copyright (C) International Business Machines Corp., 2002,2005 * Author(s): Steve French (sfrench@us.ibm.com) * * This library is free software; you can redistribute it and/or modify @@ -348,12 +348,12 @@ header_assemble(struct smb_hdr *buffer, char smb_command /* command */ , /* BB Add support for establishing new tCon and SMB Session */ /* with userid/password pairs found on the smb session */ /* for other target tcp/ip addresses BB */ - if(current->uid != treeCon->ses->linux_uid) { - cFYI(1,("Multiuser mode and UID did not match tcon uid ")); + if(current->fsuid != treeCon->ses->linux_uid) { + cFYI(1,("Multiuser mode and UID did not match tcon uid")); read_lock(&GlobalSMBSeslock); list_for_each(temp_item, &GlobalSMBSessionList) { ses = list_entry(temp_item, struct cifsSesInfo, cifsSessionList); - if(ses->linux_uid == current->uid) { + if(ses->linux_uid == current->fsuid) { if(ses->server == treeCon->ses->server) { cFYI(1,("found matching uid substitute right smb_uid")); buffer->Uid = ses->Suid; |