From a2bddb20ed078c3e1b9cb60a7420b3d107898f52 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 6 May 1998 01:34:51 +0000 Subject: Fixes for the %U and %G problems people have reported. Essentially, multiple session_setup_and_X's may be done to an smbd. As there is only one global variable containing the requested connection name (sessionsetup_user), then any subsequent sessionsetups overwrite this name (causing %U and %G to get the wrong name). This is particularly common when an NT client does a null session setup to get a browse list after the user has connected, but before a share has been mounted. These changes store the requested_name in the vuid structure (so this only really works for user level and above security) and copies this name back into the global variable before the standard_sub call. Jeremy. (This used to be commit b5187ad6a3b3af9fbbeee8bced0ab16b41e9825b) --- source3/include/smb.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source3/include/smb.h') diff --git a/source3/include/smb.h b/source3/include/smb.h index 589a70879c..8b7ad6ea92 100644 --- a/source3/include/smb.h +++ b/source3/include/smb.h @@ -485,7 +485,8 @@ typedef struct int uid; /* uid of a validated user */ int gid; /* gid of a validated user */ - fstring name; /* name of a validated user */ + fstring requested_name; /* user name from the client */ + fstring name; /* unix user name of a validated user */ fstring real_name; /* to store real name from password file - simeon */ BOOL guest; -- cgit