mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
Merged JF's fixes into HEAD. These are for string parsing and SAMR fixes.
Jeremy.
This commit is contained in:
parent
e61899f490
commit
c3a1904564
@ -356,8 +356,8 @@ static void ldap_get_sam_passwd(LDAP *ldap_struct, LDAPMessage *entry,
|
||||
user->logon_divs = 168; /* hours per week */
|
||||
user->hours_len = 21; /* 21 times 8 bits = 168 */
|
||||
memset(user->hours, 0xff, user->hours_len); /* available at all hours */
|
||||
user->unknown_5 = 0x00020000; /* don't know */
|
||||
user->unknown_5 = 0x000004ec; /* don't know */
|
||||
user->unknown_5 = 0x00000000; /* don't know */
|
||||
user->unknown_6 = 0x000004ec; /* don't know */
|
||||
|
||||
if (user->acct_ctrl & (ACB_DOMTRUST|ACB_WSTRUST|ACB_SVRTRUST) )
|
||||
{
|
||||
|
@ -353,7 +353,7 @@ static BOOL make_sam_from_nisp_object(struct sam_passwd *pw_buf, nis_object *obj
|
||||
pw_buf->logon_divs = 168; /* hours per week */
|
||||
pw_buf->hours_len = 21; /* 21 times 8 bits = 168 */
|
||||
memset(pw_buf->hours, 0xff, pw_buf->hours_len); /* available at all hours */
|
||||
pw_buf->unknown_5 = 0x00020000; /* don't know */
|
||||
pw_buf->unknown_5 = 0x00000000; /* don't know */
|
||||
pw_buf->unknown_6 = 0x000004ec; /* don't know */
|
||||
|
||||
return True;
|
||||
|
@ -116,9 +116,8 @@ void pdb_init_sam(SAM_ACCOUNT *user)
|
||||
user->logon_divs = 168; /* hours per week */
|
||||
user->hours_len = 21; /* 21 times 8 bits = 168 */
|
||||
memset(user->hours, 0xff, user->hours_len); /* available at all hours */
|
||||
user->unknown_5 = 0x00020000; /* don't know */
|
||||
user->unknown_5 = 0x000004ec; /* don't know */
|
||||
|
||||
user->unknown_5 = 0x00000000; /* don't know */
|
||||
user->unknown_6 = 0x000004ec; /* don't know */
|
||||
}
|
||||
|
||||
/************************************************************
|
||||
|
@ -673,16 +673,16 @@ BOOL prs_unistr2(BOOL charmode, char *name, prs_struct *ps, int depth, UNISTR2 *
|
||||
if (q == NULL)
|
||||
return False;
|
||||
|
||||
/* If the string is empty, we don't have anything to stream */
|
||||
if (str->uni_str_len==0)
|
||||
return True;
|
||||
|
||||
if (UNMARSHALLING(ps)) {
|
||||
str->buffer = (uint16 *)prs_alloc_mem(ps,str->uni_max_len * sizeof(uint16));
|
||||
if (str->buffer == NULL)
|
||||
return False;
|
||||
}
|
||||
|
||||
/* If the string is empty, we don't have anything to stream */
|
||||
if (str->uni_str_len==0)
|
||||
return True;
|
||||
|
||||
p = (char *)str->buffer;
|
||||
|
||||
/* If we're using big-endian, reverse to get little-endian. */
|
||||
|
Loading…
Reference in New Issue
Block a user