diff options
author | Andrew Bartlett <abartlet@samba.org> | 2002-03-01 22:45:23 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2002-03-01 22:45:23 +0000 |
commit | 0242d0e17827b05d8cd270f675d2595fa67fd5b9 (patch) | |
tree | 866fd30acf88f04f9949f8c02331917849cba42c /source/rpc_server/srv_netlog_nt.c | |
parent | 04965086711e9f794f0a0bcbfa0fd230e20b0cbe (diff) | |
download | samba-0242d0e17827b05d8cd270f675d2595fa67fd5b9.tar.gz samba-0242d0e17827b05d8cd270f675d2595fa67fd5b9.tar.xz samba-0242d0e17827b05d8cd270f675d2595fa67fd5b9.zip |
SECURITY FIXES:
Remove a stray 'unbecome_root()' in the ntdomain an auth failure case.
Only allow trust accounts to request a challange in srv_netlogon_nt.c.
Currently any user can be the 'machine' for the domain logon. MERGE for 2.2.
Andrew Bartlett
Diffstat (limited to 'source/rpc_server/srv_netlog_nt.c')
-rw-r--r-- | source/rpc_server/srv_netlog_nt.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/source/rpc_server/srv_netlog_nt.c b/source/rpc_server/srv_netlog_nt.c index d382f12fcfa..07f414e8fcf 100644 --- a/source/rpc_server/srv_netlog_nt.c +++ b/source/rpc_server/srv_netlog_nt.c @@ -169,6 +169,7 @@ static BOOL get_md4pw(char *md4pw, char *mach_acct) SAM_ACCOUNT *sampass = NULL; const uint8 *pass; BOOL ret; + uint32 acct_ctrl; #if 0 /* @@ -202,7 +203,12 @@ static BOOL get_md4pw(char *md4pw, char *mach_acct) return False; } - if (!(pdb_get_acct_ctrl(sampass) & ACB_DISABLED) && ((pass=pdb_get_nt_passwd(sampass)) != NULL)) { + acct_ctrl = pdb_get_acct_ctrl(sampass); + if (!(acct_ctrl & ACB_DISABLED) && + ((acct_ctrl & ACB_DOMTRUST) || + (acct_ctrl & ACB_WSTRUST) || + (acct_ctrl & ACB_SVRTRUST)) && + ((pass=pdb_get_nt_passwd(sampass)) != NULL)) { memcpy(md4pw, pass, 16); dump_data(5, md4pw, 16); pdb_free_sam(&sampass); |