uint16_t validation_level;
union netr_Validation *validation = NULL;
bool interactive = false;
+ bool for_netlogon = false;
/*
* Make sure we start with authoritative=true,
return NT_STATUS_REQUEST_NOT_ACCEPTED;
}
+ if (r->in.internal_flags & WB_SAMLOGON_FOR_NETLOGON) {
+ for_netlogon = true;
+ }
+
switch (r->in.logon_level) {
case NetlogonInteractiveInformation:
case NetlogonServiceInformation:
}
status = winbind_dual_SamLogon(domain, p->mem_ctx,
+ for_netlogon,
interactive,
identity_info->parameter_control,
identity_info->account_name.string,
NTSTATUS winbind_dual_SamLogon(struct winbindd_domain *domain,
TALLOC_CTX *mem_ctx,
+ bool for_netlogon,
bool interactive,
uint32_t logon_parameters,
const char *name_user,
struct netr_SamBaseInfo *base_info = NULL;
struct netr_SamInfo3 *info3 = NULL;
+ if (for_netlogon) {
+ /*
+ * For netlogon we don't call netsamlogon_cache_store()
+ */
+ goto done;
+ }
+
switch (validation_level) {
case 3:
base_ctx = validation->sam3;
const struct tsocket_address *remote = NULL;
const struct tsocket_address *local = NULL;
struct netr_SamInfo3 *info3 = NULL;
+ bool for_netlogon = false;
pid_t client_pid;
if (domain == NULL) {
DBG_NOTICE("[%"PRIu32"]: pam auth crap domain: %s user: %s\n",
client_pid, r->in.domain, r->in.user);
+ if (r->in.flags & WBFLAG_PAM_FOR_NETLOGON) {
+ for_netlogon = true;
+ }
+
result = winbind_dual_SamLogon(domain,
p->mem_ctx,
+ for_netlogon,
false, /* interactive */
r->in.logon_parameters,
r->in.user,