From 5f4842cf65ce64bfdf577cd549565da20ca818cf Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 10 Dec 2007 18:41:19 +0100 Subject: r26376: Add context for libcli_resolve. (This used to be commit 459e1466a411d6f83b7372e248566e6e71c745fc) --- source4/auth/auth_server.c | 6 +++--- source4/auth/kerberos/krb5_init_context.c | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'source4/auth') diff --git a/source4/auth/auth_server.c b/source4/auth/auth_server.c index b5fcda15b3..f200ad9665 100644 --- a/source4/auth/auth_server.c +++ b/source4/auth/auth_server.c @@ -24,7 +24,7 @@ Support for server level security. ****************************************************************************/ -static struct smbcli_state *server_cryptkey(TALLOC_CTX *mem_ctx, bool unicode, int maxprotocol, const char **name_resolve_order) +static struct smbcli_state *server_cryptkey(TALLOC_CTX *mem_ctx, bool unicode, int maxprotocol, struct resolve_context *resolve_ctx) { struct smbcli_state *cli = NULL; fstring desthost; @@ -45,7 +45,7 @@ static struct smbcli_state *server_cryptkey(TALLOC_CTX *mem_ctx, bool unicode, i while(next_token( &p, desthost, LIST_SEP, sizeof(desthost))) { strupper(desthost); - if(!resolve_name( desthost, &dest_ip, 0x20, name_resolve_order)) { + if(!resolve_name(resolve_ctx, desthost, &dest_ip, 0x20)) { DEBUG(1,("server_cryptkey: Can't resolve address for %s\n",desthost)); continue; } @@ -215,7 +215,7 @@ static NTSTATUS check_smbserver_security(const struct auth_context *auth_context if (cli) { } else { - cli = server_cryptkey(mem_ctx, lp_unicode(auth_context->lp_ctx), lp_cli_maxprotocol(auth_context->lp_ctx), lp_name_resolve_order(auth_context->lp_ctx)); + cli = server_cryptkey(mem_ctx, lp_unicode(auth_context->lp_ctx), lp_cli_maxprotocol(auth_context->lp_ctx), lp_resolve_context(auth_context->lp_ctx)); locally_made_cli = true; } diff --git a/source4/auth/kerberos/krb5_init_context.c b/source4/auth/kerberos/krb5_init_context.c index e3479b12d1..d0bc383ea0 100644 --- a/source4/auth/kerberos/krb5_init_context.c +++ b/source4/auth/kerberos/krb5_init_context.c @@ -30,6 +30,7 @@ #include "lib/events/events.h" #include "roken.h" #include "param/param.h" +#include "libcli/resolve/resolve.h" /* context structure for operations on cldap packets @@ -277,7 +278,7 @@ krb5_error_code smb_krb5_send_and_recv_func(krb5_context context, } status = socket_connect_ev(smb_krb5->sock, NULL, remote_addr, 0, - lp_name_resolve_order(global_loadparm), ev); + lp_resolve_context(global_loadparm), ev); if (!NT_STATUS_IS_OK(status)) { talloc_free(smb_krb5); continue; -- cgit