diff options
author | Andrew Bartlett <abartlet@samba.org> | 2002-08-22 17:05:35 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2002-08-22 17:05:35 +0000 |
commit | 68b9a4cebc04ba80fb1fb37940e013bc680b589e (patch) | |
tree | 3f636dd4d2ddeb9c024d9a808abc7c3fbf84b003 /source3/smbd | |
parent | f5a4487df573f8dfb2b6e18a492585220df1f5bb (diff) | |
download | samba-68b9a4cebc04ba80fb1fb37940e013bc680b589e.tar.gz samba-68b9a4cebc04ba80fb1fb37940e013bc680b589e.tar.bz2 samba-68b9a4cebc04ba80fb1fb37940e013bc680b589e.zip |
Ensure we don't change to a user that we can't get an NT_TOKEN for.
(This used to be commit 9416289b571b1c838239e5342bb6148041ab681b)
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/uid.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/smbd/uid.c b/source3/smbd/uid.c index 6f91065ceb..2bda26aa51 100644 --- a/source3/smbd/uid.c +++ b/source3/smbd/uid.c @@ -178,6 +178,10 @@ BOOL change_to_user(connection_struct *conn, uint16 vuid) is_guest = True; token = create_nt_token(uid, gid, current_user.ngroups, current_user.groups, is_guest); + if (!token) { + DEBUG(1, ("change_to_user: create_nt_token failed!\n")); + return False; + } must_free_token = True; } |