diff options
author | Andrew Tridgell <tridge@samba.org> | 2010-07-16 14:32:42 +1000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2010-07-16 18:24:27 +1000 |
commit | 6b266b85cf34145ac1f03d8f787b81121e4ec92b (patch) | |
tree | 9f6faebdcf58c73e0297bfdf3b905ef256f8e478 /source4/winbind | |
parent | e4c35c5a09dd66c9280caa39130b7e3b941b7e51 (diff) | |
download | samba-6b266b85cf34145ac1f03d8f787b81121e4ec92b.tar.gz samba-6b266b85cf34145ac1f03d8f787b81121e4ec92b.tar.bz2 samba-6b266b85cf34145ac1f03d8f787b81121e4ec92b.zip |
s4-loadparm: 2nd half of lp_ to lpcfg_ conversion
this converts all callers that use the Samba4 loadparm lp_ calling
convention to use the lpcfg_ prefix.
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source4/winbind')
-rw-r--r-- | source4/winbind/idmap.c | 6 | ||||
-rw-r--r-- | source4/winbind/wb_cmd_getpwnam.c | 4 | ||||
-rw-r--r-- | source4/winbind/wb_cmd_getpwuid.c | 4 | ||||
-rw-r--r-- | source4/winbind/wb_dom_info.c | 6 | ||||
-rw-r--r-- | source4/winbind/wb_dom_info_trusted.c | 2 | ||||
-rw-r--r-- | source4/winbind/wb_init_domain.c | 8 | ||||
-rw-r--r-- | source4/winbind/wb_pam_auth.c | 6 | ||||
-rw-r--r-- | source4/winbind/wb_samba3_cmd.c | 8 | ||||
-rw-r--r-- | source4/winbind/wb_server.c | 26 | ||||
-rw-r--r-- | source4/winbind/wb_sid2domain.c | 2 | ||||
-rw-r--r-- | source4/winbind/wb_utils.c | 4 |
11 files changed, 38 insertions, 38 deletions
diff --git a/source4/winbind/idmap.c b/source4/winbind/idmap.c index ede2485e6a..be679db1cc 100644 --- a/source4/winbind/idmap.c +++ b/source4/winbind/idmap.c @@ -164,7 +164,7 @@ struct idmap_context *idmap_init(TALLOC_CTX *mem_ctx, idmap_ctx->lp_ctx = lp_ctx; idmap_ctx->ldb_ctx = ldb_wrap_connect(mem_ctx, ev_ctx, lp_ctx, - lp_idmap_url(lp_ctx), + lpcfg_idmap_url(lp_ctx), system_session(lp_ctx), NULL, 0); if (idmap_ctx->ldb_ctx == NULL) { @@ -279,7 +279,7 @@ failed: * * If no mapping exists, a new mapping will be created. * - * \todo Check if SIDs can be resolved if lp_idmap_trusted_only() == true + * \todo Check if SIDs can be resolved if lpcfg_idmap_trusted_only() == true * \todo Fix backwards compatibility for Samba3 * * \param idmap_ctx idmap context to use @@ -398,7 +398,7 @@ static NTSTATUS idmap_sid_to_xid(struct idmap_context *idmap_ctx, goto failed; } - /*FIXME: if lp_idmap_trusted_only() == true, check if SID can be + /*FIXME: if lpcfg_idmap_trusted_only() == true, check if SID can be * resolved here. */ ret = idmap_get_bounds(idmap_ctx, &low, &high); diff --git a/source4/winbind/wb_cmd_getpwnam.c b/source4/winbind/wb_cmd_getpwnam.c index a82387bd63..ac723593d2 100644 --- a/source4/winbind/wb_cmd_getpwnam.c +++ b/source4/winbind/wb_cmd_getpwnam.c @@ -124,13 +124,13 @@ static void cmd_getpwnam_recv_user_info(struct composite_context *ctx) WBSRV_SAMBA3_SET_STRING(pw->pw_passwd, "*"); WBSRV_SAMBA3_SET_STRING(pw->pw_gecos, user_info->out.full_name); WBSRV_SAMBA3_SET_STRING(pw->pw_dir, - lp_template_homedir(state->service->task->lp_ctx)); + lpcfg_template_homedir(state->service->task->lp_ctx)); all_string_sub(pw->pw_dir, "%WORKGROUP%", state->workgroup_name, sizeof(fstring) - 1); all_string_sub(pw->pw_dir, "%ACCOUNTNAME%", user_info->out.account_name, sizeof(fstring) - 1); WBSRV_SAMBA3_SET_STRING(pw->pw_shell, - lp_template_shell(state->service->task->lp_ctx)); + lpcfg_template_shell(state->service->task->lp_ctx)); state->group_sid = dom_sid_dup(state, user_info->out.primary_group_sid); if(composite_nomem(state->group_sid, state->ctx)) return; diff --git a/source4/winbind/wb_cmd_getpwuid.c b/source4/winbind/wb_cmd_getpwuid.c index f5e7f6b4b1..f6f3cb282e 100644 --- a/source4/winbind/wb_cmd_getpwuid.c +++ b/source4/winbind/wb_cmd_getpwuid.c @@ -145,13 +145,13 @@ static void cmd_getpwuid_recv_user_info(struct composite_context *ctx) WBSRV_SAMBA3_SET_STRING(pw->pw_passwd, "*"); WBSRV_SAMBA3_SET_STRING(pw->pw_gecos, user_info->out.full_name); WBSRV_SAMBA3_SET_STRING(pw->pw_dir, - lp_template_homedir(state->service->task->lp_ctx)); + lpcfg_template_homedir(state->service->task->lp_ctx)); all_string_sub(pw->pw_dir, "%WORKGROUP%", state->workgroup, sizeof(fstring) - 1); all_string_sub(pw->pw_dir, "%ACCOUNTNAME%", user_info->out.account_name, sizeof(fstring) - 1); WBSRV_SAMBA3_SET_STRING(pw->pw_shell, - lp_template_shell(state->service->task->lp_ctx)); + lpcfg_template_shell(state->service->task->lp_ctx)); pw->pw_uid = state->uid; diff --git a/source4/winbind/wb_dom_info.c b/source4/winbind/wb_dom_info.c index b6ec7dd67f..8e4d238390 100644 --- a/source4/winbind/wb_dom_info.c +++ b/source4/winbind/wb_dom_info.c @@ -64,11 +64,11 @@ struct composite_context *wb_get_dom_info_send(TALLOC_CTX *mem_ctx, dom_sid = dom_sid_dup(mem_ctx, sid); if (dom_sid == NULL) goto failed; - ctx = finddcs_send(mem_ctx, lp_netbios_name(service->task->lp_ctx), - lp_nbt_port(service->task->lp_ctx), + ctx = finddcs_send(mem_ctx, lpcfg_netbios_name(service->task->lp_ctx), + lpcfg_nbt_port(service->task->lp_ctx), domain_name, NBT_NAME_LOGON, dom_sid, - lp_resolve_context(service->task->lp_ctx), + lpcfg_resolve_context(service->task->lp_ctx), service->task->event_ctx, service->task->msg_ctx); if (ctx == NULL) goto failed; diff --git a/source4/winbind/wb_dom_info_trusted.c b/source4/winbind/wb_dom_info_trusted.c index eebabaee44..8086714a6e 100644 --- a/source4/winbind/wb_dom_info_trusted.c +++ b/source4/winbind/wb_dom_info_trusted.c @@ -199,7 +199,7 @@ static void trusted_dom_info_recv_dcname(struct tevent_req *subreq) if (*state->info->dcs[0].name == '\\') state->info->dcs[0].name++; make_nbt_name(&name, state->info->dcs[0].name, 0x20); - ctx = resolve_name_send(lp_resolve_context(state->service->task->lp_ctx), state, + ctx = resolve_name_send(lpcfg_resolve_context(state->service->task->lp_ctx), state, &name, state->service->task->event_ctx); composite_continue(state->ctx, ctx, trusted_dom_info_recv_dcaddr, diff --git a/source4/winbind/wb_init_domain.c b/source4/winbind/wb_init_domain.c index 03a2c9a9c0..f07d17a64e 100644 --- a/source4/winbind/wb_init_domain.c +++ b/source4/winbind/wb_init_domain.c @@ -158,14 +158,14 @@ struct composite_context *wb_init_domain_send(TALLOC_CTX *mem_ctx, state->domain->netlogon_pipe = NULL; if ((!cli_credentials_is_anonymous(state->domain->libnet_ctx->cred)) && - ((lp_server_role(service->task->lp_ctx) == ROLE_DOMAIN_MEMBER) || - (lp_server_role(service->task->lp_ctx) == ROLE_DOMAIN_CONTROLLER)) && + ((lpcfg_server_role(service->task->lp_ctx) == ROLE_DOMAIN_MEMBER) || + (lpcfg_server_role(service->task->lp_ctx) == ROLE_DOMAIN_CONTROLLER)) && (dom_sid_equal(state->domain->info->sid, state->service->primary_sid))) { state->domain->netlogon_binding->flags |= DCERPC_SCHANNEL; /* For debugging, it can be a real pain if all the traffic is encrypted */ - if (lp_winbind_sealed_pipes(service->task->lp_ctx)) { + if (lpcfg_winbind_sealed_pipes(service->task->lp_ctx)) { state->domain->netlogon_binding->flags |= (DCERPC_SIGN | DCERPC_SEAL ); } else { state->domain->netlogon_binding->flags |= (DCERPC_SIGN); @@ -211,7 +211,7 @@ static void init_domain_recv_netlogonpipe(struct composite_context *ctx) state->domain->lsa_binding = init_domain_binding(state, &ndr_table_lsarpc); /* For debugging, it can be a real pain if all the traffic is encrypted */ - if (lp_winbind_sealed_pipes(state->service->task->lp_ctx)) { + if (lpcfg_winbind_sealed_pipes(state->service->task->lp_ctx)) { state->domain->lsa_binding->flags |= (DCERPC_SIGN | DCERPC_SEAL ); } else { state->domain->lsa_binding->flags |= (DCERPC_SIGN); diff --git a/source4/winbind/wb_pam_auth.c b/source4/winbind/wb_pam_auth.c index 0c33f1cf8b..e09addac73 100644 --- a/source4/winbind/wb_pam_auth.c +++ b/source4/winbind/wb_pam_auth.c @@ -177,7 +177,7 @@ static void pam_auth_crap_recv_logon(struct composite_context *ctx) state->unix_username = talloc_asprintf(state, "%s%s%s", state->domain_name, - lp_winbind_separator(state->lp_ctx), + lpcfg_winbind_separator(state->lp_ctx), state->user_name); if (composite_nomem(state->unix_username, state->ctx)) return; @@ -219,11 +219,11 @@ struct composite_context *wb_cmd_pam_auth_send(TALLOC_CTX *mem_ctx, const char *user, *domain; DATA_BLOB chal, nt_resp, lm_resp, names_blob; int flags = CLI_CRED_NTLM_AUTH; - if (lp_client_lanman_auth(service->task->lp_ctx)) { + if (lpcfg_client_lanman_auth(service->task->lp_ctx)) { flags |= CLI_CRED_LANMAN_AUTH; } - if (lp_client_ntlmv2_auth(service->task->lp_ctx)) { + if (lpcfg_client_ntlmv2_auth(service->task->lp_ctx)) { flags |= CLI_CRED_NTLMv2_AUTH; } diff --git a/source4/winbind/wb_samba3_cmd.c b/source4/winbind/wb_samba3_cmd.c index fcb587a007..9b8f8e0663 100644 --- a/source4/winbind/wb_samba3_cmd.c +++ b/source4/winbind/wb_samba3_cmd.c @@ -190,7 +190,7 @@ NTSTATUS wbsrv_samba3_interface_version(struct wbsrv_samba3_call *s3call) NTSTATUS wbsrv_samba3_info(struct wbsrv_samba3_call *s3call) { s3call->response->result = WINBINDD_OK; - s3call->response->data.info.winbind_separator = *lp_winbind_separator(s3call->wbconn->lp_ctx); + s3call->response->data.info.winbind_separator = *lpcfg_winbind_separator(s3call->wbconn->lp_ctx); WBSRV_SAMBA3_SET_STRING(s3call->response->data.info.samba_version, SAMBA_VERSION_STRING); return NT_STATUS_OK; @@ -200,7 +200,7 @@ NTSTATUS wbsrv_samba3_domain_name(struct wbsrv_samba3_call *s3call) { s3call->response->result = WINBINDD_OK; WBSRV_SAMBA3_SET_STRING(s3call->response->data.domain_name, - lp_workgroup(s3call->wbconn->lp_ctx)); + lpcfg_workgroup(s3call->wbconn->lp_ctx)); return NT_STATUS_OK; } @@ -208,14 +208,14 @@ NTSTATUS wbsrv_samba3_netbios_name(struct wbsrv_samba3_call *s3call) { s3call->response->result = WINBINDD_OK; WBSRV_SAMBA3_SET_STRING(s3call->response->data.netbios_name, - lp_netbios_name(s3call->wbconn->lp_ctx)); + lpcfg_netbios_name(s3call->wbconn->lp_ctx)); return NT_STATUS_OK; } NTSTATUS wbsrv_samba3_priv_pipe_dir(struct wbsrv_samba3_call *s3call) { struct loadparm_context *lp_ctx = s3call->wbconn->listen_socket->service->task->lp_ctx; - const char *priv_socket_dir = lp_winbindd_privileged_socket_directory(lp_ctx); + const char *priv_socket_dir = lpcfg_winbindd_privileged_socket_directory(lp_ctx); s3call->response->result = WINBINDD_OK; s3call->response->extra_data.data = discard_const(priv_socket_dir); diff --git a/source4/winbind/wb_server.c b/source4/winbind/wb_server.c index 2e1af61de6..ee44f0a240 100644 --- a/source4/winbind/wb_server.c +++ b/source4/winbind/wb_server.c @@ -213,14 +213,14 @@ static void winbind_task_init(struct task_server *task) } /* Make sure the directory for the Samba3 socket exists, and is of the correct permissions */ - if (!directory_create_or_exist(lp_winbindd_socket_directory(task->lp_ctx), geteuid(), 0755)) { + if (!directory_create_or_exist(lpcfg_winbindd_socket_directory(task->lp_ctx), geteuid(), 0755)) { task_server_terminate(task, "Cannot create winbindd pipe directory", true); return; } /* Make sure the directory for the Samba3 socket exists, and is of the correct permissions */ - if (!directory_create_or_exist(lp_winbindd_privileged_socket_directory(task->lp_ctx), geteuid(), 0750)) { + if (!directory_create_or_exist(lpcfg_winbindd_privileged_socket_directory(task->lp_ctx), geteuid(), 0750)) { task_server_terminate(task, "Cannot create winbindd privileged pipe directory", true); return; @@ -234,17 +234,17 @@ static void winbind_task_init(struct task_server *task) /* Find the primary SID, depending if we are a standalone * server (what good is winbind in this case, but anyway...), * or are in a domain as a member or a DC */ - switch (lp_server_role(service->task->lp_ctx)) { + switch (lpcfg_server_role(service->task->lp_ctx)) { case ROLE_STANDALONE: primary_sid = secrets_get_domain_sid(service, service->task->event_ctx, service->task->lp_ctx, - lp_netbios_name(service->task->lp_ctx), &errstring); + lpcfg_netbios_name(service->task->lp_ctx), &errstring); if (!primary_sid) { char *message = talloc_asprintf(task, "Cannot start Winbind (standalone configuration): %s: " "Have you provisioned this server (%s) or changed it's name?", - errstring, lp_netbios_name(service->task->lp_ctx)); + errstring, lpcfg_netbios_name(service->task->lp_ctx)); task_server_terminate(task, message, true); return; } @@ -253,11 +253,11 @@ static void winbind_task_init(struct task_server *task) primary_sid = secrets_get_domain_sid(service, service->task->event_ctx, service->task->lp_ctx, - lp_workgroup(service->task->lp_ctx), &errstring); + lpcfg_workgroup(service->task->lp_ctx), &errstring); if (!primary_sid) { char *message = talloc_asprintf(task, "Cannot start Winbind (domain member): %s: " "Have you joined the %s domain?", - errstring, lp_workgroup(service->task->lp_ctx)); + errstring, lpcfg_workgroup(service->task->lp_ctx)); task_server_terminate(task, message, true); return; } @@ -266,11 +266,11 @@ static void winbind_task_init(struct task_server *task) primary_sid = secrets_get_domain_sid(service, service->task->event_ctx, service->task->lp_ctx, - lp_workgroup(service->task->lp_ctx), &errstring); + lpcfg_workgroup(service->task->lp_ctx), &errstring); if (!primary_sid) { char *message = talloc_asprintf(task, "Cannot start Winbind (domain controller): %s: " "Have you provisioned the %s domain?", - errstring, lp_workgroup(service->task->lp_ctx)); + errstring, lpcfg_workgroup(service->task->lp_ctx)); task_server_terminate(task, message, true); return; } @@ -284,8 +284,8 @@ static void winbind_task_init(struct task_server *task) return; } - service->priv_pipe_dir = lp_winbindd_privileged_socket_directory(task->lp_ctx); - service->pipe_dir = lp_winbindd_socket_directory(task->lp_ctx); + service->priv_pipe_dir = lpcfg_winbindd_privileged_socket_directory(task->lp_ctx); + service->pipe_dir = lpcfg_winbindd_socket_directory(task->lp_ctx); /* setup the unprivileged samba3 socket */ listen_socket = talloc(service, struct wbsrv_listen_socket); @@ -299,7 +299,7 @@ static void winbind_task_init(struct task_server *task) status = stream_setup_socket(task->event_ctx, task->lp_ctx, model_ops, &wbsrv_ops, "unix", listen_socket->socket_path, &port, - lp_socket_options(task->lp_ctx), + lpcfg_socket_options(task->lp_ctx), listen_socket); if (!NT_STATUS_IS_OK(status)) goto listen_failed; @@ -316,7 +316,7 @@ static void winbind_task_init(struct task_server *task) status = stream_setup_socket(task->event_ctx, task->lp_ctx, model_ops, &wbsrv_ops, "unix", listen_socket->socket_path, &port, - lp_socket_options(task->lp_ctx), + lpcfg_socket_options(task->lp_ctx), listen_socket); if (!NT_STATUS_IS_OK(status)) goto listen_failed; diff --git a/source4/winbind/wb_sid2domain.c b/source4/winbind/wb_sid2domain.c index bdbfc3eceb..b77044ee80 100644 --- a/source4/winbind/wb_sid2domain.c +++ b/source4/winbind/wb_sid2domain.c @@ -84,7 +84,7 @@ struct composite_context *wb_sid2domain_send(TALLOC_CTX *mem_ctx, if (dom_sid_equal(service->primary_sid, sid) || dom_sid_in_domain(service->primary_sid, sid)) { - ctx = wb_get_dom_info_send(state, service, lp_workgroup(service->task->lp_ctx), + ctx = wb_get_dom_info_send(state, service, lpcfg_workgroup(service->task->lp_ctx), service->primary_sid); if (ctx == NULL) goto failed; ctx->async.fn = sid2domain_recv_dom_info; diff --git a/source4/winbind/wb_utils.c b/source4/winbind/wb_utils.c index 43effc3028..ffc4aa1950 100644 --- a/source4/winbind/wb_utils.c +++ b/source4/winbind/wb_utils.c @@ -31,10 +31,10 @@ bool wb_samba3_split_username(TALLOC_CTX *mem_ctx, struct loadparm_context *lp_c const char *domuser, char **domain, char **user) { - char *p = strchr(domuser, *lp_winbind_separator(lp_ctx)); + char *p = strchr(domuser, *lpcfg_winbind_separator(lp_ctx)); if (p == NULL) { - *domain = talloc_strdup(mem_ctx, lp_workgroup(lp_ctx)); + *domain = talloc_strdup(mem_ctx, lpcfg_workgroup(lp_ctx)); } else { *domain = talloc_strndup(mem_ctx, domuser, PTR_DIFF(p, domuser)); |