diff options
author | Volker Lendecke <vlendec@samba.org> | 2006-08-02 08:53:22 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:38:29 -0500 |
commit | 280e3895b609f7b4fd880dabdc446529938a16f6 (patch) | |
tree | 2fc1e159196e2672cdee2cd08a6a2f832cd9462f /source3 | |
parent | d42a96b3ec3dec1e2aa958813ae56326e7b02789 (diff) | |
download | samba-280e3895b609f7b4fd880dabdc446529938a16f6.tar.gz samba-280e3895b609f7b4fd880dabdc446529938a16f6.tar.bz2 samba-280e3895b609f7b4fd880dabdc446529938a16f6.zip |
r17374: Get rid of a silly "System User" default for "description", also fetch the
sambaProfilePath.
Volker
(This used to be commit 61e7ed593b944fa14330729e585d1f790af93a7b)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/utils/net_rpc_samsync.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/source3/utils/net_rpc_samsync.c b/source3/utils/net_rpc_samsync.c index 298a7c7c43..4f7209cdb5 100644 --- a/source3/utils/net_rpc_samsync.c +++ b/source3/utils/net_rpc_samsync.c @@ -1534,7 +1534,7 @@ static NTSTATUS fetch_account_info_to_ldif(SAM_DELTA_CTR *delta, { fstring username, logonscript, homedrive, homepath = "", homedir = ""; fstring hex_nt_passwd, hex_lm_passwd; - fstring description, fullname, sambaSID; + fstring description, profilepath, fullname, sambaSID; uchar lm_passwd[16], nt_passwd[16]; char *flags, *user_rdn; const char *ou; @@ -1586,14 +1586,15 @@ static NTSTATUS fetch_account_info_to_ldif(SAM_DELTA_CTR *delta, /* Get the description */ unistr2_to_ascii(description, &(delta->account_info.uni_acct_desc), sizeof(description)-1); - if (!*description) { - pstr_sprintf(description, "System User"); - } /* Get the display name */ unistr2_to_ascii(fullname, &(delta->account_info.uni_full_name), sizeof(fullname)-1); + /* Get the profile path */ + unistr2_to_ascii(profilepath, &(delta->account_info.uni_profile), + sizeof(profilepath)-1); + /* Get lm and nt password data */ if (memcmp(delta->account_info.pass.buf_lm_pwd, zero_buf, 16) != 0) { sam_pwd_hash(delta->account_info.user_rid, @@ -1668,11 +1669,14 @@ static NTSTATUS fetch_account_info_to_ldif(SAM_DELTA_CTR *delta, ((delta->account_info.acb_info & ACB_NORMAL) ? "/bin/bash" : "/bin/false")); fprintf(add_fd, "gecos: System User\n"); - fprintf_attr(add_fd, "description", "%s", description); + if (*description) + fprintf_attr(add_fd, "description", "%s", description); fprintf(add_fd, "sambaSID: %s-%d\n", sid, rid); fprintf(add_fd, "sambaPrimaryGroupSID: %s\n", sambaSID); if(*fullname) fprintf_attr(add_fd, "displayName", "%s", fullname); + if(*profilepath) + fprintf_attr(add_fd, "sambaProfilePath", "%s", profilepath); if (strcmp(nopasswd, hex_lm_passwd) != 0) fprintf(add_fd, "sambaLMPassword: %s\n", hex_lm_passwd); if (strcmp(nopasswd, hex_nt_passwd) != 0) |