summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorMatthieu Patou <mat@matws.net>2009-09-08 12:21:09 +0400
committerAndrew Bartlett <abartlet@samba.org>2009-09-08 22:44:50 +1000
commita915575158485debaa0d417d5566c46a0dd77004 (patch)
treefe7779e1d80e58a35f9863d05eb4a77d57bc7329 /source4
parent29040344105988cb9674c0f450ef9e739e9ece2a (diff)
downloadsamba-a915575158485debaa0d417d5566c46a0dd77004.tar.gz
samba-a915575158485debaa0d417d5566c46a0dd77004.tar.bz2
samba-a915575158485debaa0d417d5566c46a0dd77004.zip
Return a correct value for Supported Encryption Type
Vista and upper version use this value to check wether they should ask the DC to change the msDS-SupportedEncryptionTypes attribute or not. Declare the different value as a bitmap in Netlogon idl
Diffstat (limited to 'source4')
-rw-r--r--source4/rpc_server/netlogon/dcerpc_netlogon.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c b/source4/rpc_server/netlogon/dcerpc_netlogon.c
index d597ca6886..e349df00db 100644
--- a/source4/rpc_server/netlogon/dcerpc_netlogon.c
+++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c
@@ -1130,6 +1130,8 @@ static NTSTATUS dcesrv_netr_LogonGetDomainInfo(struct dcesrv_call_state *dce_cal
struct netr_LsaPolicyInformation *lsa_policy_info;
struct netr_OsVersionInfoEx *os_version;
int ret1, ret2, i;
+ uint32_t client_supported_enc;
+ uint32_t default_supported_enc = ENC_CRC32|ENC_RSA_MD5|ENC_RC4_HMAC_MD5;
NTSTATUS status;
status = dcesrv_netr_creds_server_step_check(dce_call,
@@ -1176,6 +1178,9 @@ static NTSTATUS dcesrv_netr_LogonGetDomainInfo(struct dcesrv_call_state *dce_cal
"dNSHostName",
NULL);
+ client_supported_enc = samdb_search_int64(sam_ctx, mem_ctx, default_supported_enc,
+ workstation_dn, "msDS-SupportedEncryptionTypes",
+ NULL);
/* Gets host informations and put them in our directory */
new_msg = ldb_msg_new(mem_ctx);
NT_STATUS_HAVE_NO_MEMORY(new_msg);
@@ -1321,7 +1326,7 @@ static NTSTATUS dcesrv_netr_LogonGetDomainInfo(struct dcesrv_call_state *dce_cal
domain_info->dns_hostname.string = old_dns_hostname;
domain_info->workstation_flags =
r->in.query->workstation_info->workstation_flags;
- domain_info->supported_enc_types = 0; /* w2008 gives this 0 */
+ domain_info->supported_enc_types = client_supported_enc;
r->out.info->domain_info = domain_info;
break;