diff options
author | Tim Potter <tpot@samba.org> | 2001-06-02 06:14:42 +0000 |
---|---|---|
committer | Tim Potter <tpot@samba.org> | 2001-06-02 06:14:42 +0000 |
commit | 94186f645d3586fb1deffb9891d5db3808395ea4 (patch) | |
tree | f4c477109e8e8aabc522dddf1654159a5929f459 /source3/rpc_server | |
parent | 3bc291f55d202f9ba6b2efe7358db8a939447fd4 (diff) | |
download | samba-94186f645d3586fb1deffb9891d5db3808395ea4.tar.gz samba-94186f645d3586fb1deffb9891d5db3808395ea4.tar.bz2 samba-94186f645d3586fb1deffb9891d5db3808395ea4.zip |
Merge of i18n domain name fix for lsa_query_info_policy() from appliance
branch.
(This used to be commit e7a4dd7612d79bb24be68c601eccc987aba6b497)
Diffstat (limited to 'source3/rpc_server')
-rw-r--r-- | source3/rpc_server/srv_lsa_nt.c | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/source3/rpc_server/srv_lsa_nt.c b/source3/rpc_server/srv_lsa_nt.c index 58a7d8dde9..5ccb5a665b 100644 --- a/source3/rpc_server/srv_lsa_nt.c +++ b/source3/rpc_server/srv_lsa_nt.c @@ -332,6 +332,7 @@ uint32 _lsa_query_info(pipes_struct *p, LSA_Q_QUERY_INFO *q_u, LSA_R_QUERY_INFO { LSA_INFO_UNION *info = &r_u->dom; DOM_SID domain_sid; + fstring dos_domain; char *name = NULL; DOM_SID *sid = NULL; @@ -340,6 +341,9 @@ uint32 _lsa_query_info(pipes_struct *p, LSA_Q_QUERY_INFO *q_u, LSA_R_QUERY_INFO if (!find_policy_by_hnd(p, &q_u->pol, NULL)) return NT_STATUS_INVALID_HANDLE; + fstrcpy(dos_domain, global_myworkgroup); + unix_to_dos(dos_domain, True); + switch (q_u->info_class) { case 0x02: { @@ -359,20 +363,20 @@ uint32 _lsa_query_info(pipes_struct *p, LSA_Q_QUERY_INFO *q_u, LSA_R_QUERY_INFO switch (lp_server_role()) { case ROLE_DOMAIN_PDC: case ROLE_DOMAIN_BDC: - name = global_myworkgroup; + name = dos_domain; sid = &global_sam_sid; break; case ROLE_DOMAIN_MEMBER: - name = global_myworkgroup; + name = dos_domain; /* We need to return the Domain SID here. */ - if (secrets_fetch_domain_sid(global_myworkgroup, - &domain_sid)) - sid = &domain_sid; + if (secrets_fetch_domain_sid(dos_domain, + &domain_sid)) + sid = &domain_sid; else return NT_STATUS_CANT_ACCESS_DOMAIN_INFO; break; case ROLE_STANDALONE: - name = global_myname; + name = dos_domain; sid = NULL; /* Tell it we're not in a domain. */ break; default: @@ -385,15 +389,15 @@ uint32 _lsa_query_info(pipes_struct *p, LSA_Q_QUERY_INFO *q_u, LSA_R_QUERY_INFO switch (lp_server_role()) { case ROLE_DOMAIN_PDC: case ROLE_DOMAIN_BDC: - name = global_myworkgroup; + name = dos_domain; sid = &global_sam_sid; break; case ROLE_DOMAIN_MEMBER: - name = global_myname; + name = dos_domain; sid = &global_sam_sid; break; case ROLE_STANDALONE: - name = global_myname; + name = dos_domain; sid = &global_sam_sid; break; default: |