summaryrefslogtreecommitdiff
path: root/source3/passdb
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2002-04-05 22:37:55 +0000
committerJeremy Allison <jra@samba.org>2002-04-05 22:37:55 +0000
commit2a3a68bf45749544623c8f7cd03c0f059d4745ab (patch)
treed09c5a3e5e34570512754b785a5df1de696f1d10 /source3/passdb
parent3fcb31db922f911a713c89bb2ee626042e41df46 (diff)
downloadsamba-2a3a68bf45749544623c8f7cd03c0f059d4745ab.tar.gz
samba-2a3a68bf45749544623c8f7cd03c0f059d4745ab.tar.bz2
samba-2a3a68bf45749544623c8f7cd03c0f059d4745ab.zip
Fixed up admin user / guest user lookup.
Jeremy. (This used to be commit 28ef07424f19652fdfa4ee79f1c69e0004fa39fe)
Diffstat (limited to 'source3/passdb')
-rw-r--r--source3/passdb/passdb.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/source3/passdb/passdb.c b/source3/passdb/passdb.c
index 9b1bd3d211..7eecbfd2cd 100644
--- a/source3/passdb/passdb.c
+++ b/source3/passdb/passdb.c
@@ -525,14 +525,17 @@ BOOL local_lookup_sid(DOM_SID *sid, char *name, enum SID_NAME_USE *psid_name_use
if(is_user) {
if(rid == DOMAIN_USER_RID_ADMIN) {
- pstring admin_users;
- char *p = admin_users;
+ char **admin_list = lp_admin_users(-1);
*psid_name_use = SID_NAME_USER;
- if(!next_token(&p, name, NULL, sizeof(fstring)))
+ if (admin_list) {
+ char *p = *admin_list;
+ if(!next_token(&p, name, NULL, sizeof(fstring)))
+ fstrcpy(name, "Administrator");
+ } else {
fstrcpy(name, "Administrator");
+ }
} else if (rid == DOMAIN_USER_RID_GUEST) {
- pstring guest_users;
- char *p = guest_users;
+ char *p = lp_guestaccount();
*psid_name_use = SID_NAME_USER;
if(!next_token(&p, name, NULL, sizeof(fstring)))
fstrcpy(name, "Guest");