summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2006-05-06 19:24:35 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:16:52 -0500
commitdc9f30b8b0ace8d6e2c8c0cbed537fde68d1556a (patch)
tree32acdb2e8bde99fa8fe26c81219e5fde5be0caaf /source3/smbd
parent83e4ea7e852e4ae9a4ba6fd187787c76f2d54ef6 (diff)
downloadsamba-dc9f30b8b0ace8d6e2c8c0cbed537fde68d1556a.tar.gz
samba-dc9f30b8b0ace8d6e2c8c0cbed537fde68d1556a.tar.bz2
samba-dc9f30b8b0ace8d6e2c8c0cbed537fde68d1556a.zip
r15475: Ugly and disgusting patch to fix the username map problem I created by
changing the token generation. I *hate* this code! Jerry, you have been looking at this as well, can you double-check that I did not screw it up? Thanks, Volker (This used to be commit 2765c4ff8d44c970db3e075b0a2412662f1936c6)
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/sesssetup.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c
index b13042074a..b086090bd9 100644
--- a/source3/smbd/sesssetup.c
+++ b/source3/smbd/sesssetup.c
@@ -176,6 +176,7 @@ static int reply_spnego_kerberos(connection_struct *conn,
DATA_BLOB nullblob = data_blob(NULL, 0);
fstring real_username;
BOOL map_domainuser_to_guest = False;
+ BOOL username_was_mapped;
PAC_LOGON_INFO *logon_info = NULL;
ZERO_STRUCT(ticket);
@@ -288,7 +289,7 @@ static int reply_spnego_kerberos(connection_struct *conn,
/* lookup the passwd struct, create a new user if necessary */
- map_username( user );
+ username_was_mapped = map_username( user );
pw = smb_getpwnam( mem_ctx, user, real_username, True );
if (!pw) {
@@ -355,6 +356,8 @@ static int reply_spnego_kerberos(connection_struct *conn,
pdb_set_domain(server_info->sam_account, domain, PDB_SET);
}
}
+
+ server_info->was_mapped |= username_was_mapped;
/* we need to build the token for the user. make_server_info_guest()
already does this */