summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimo Sorce <idra@samba.org>2010-07-20 18:43:37 -0400
committerSimo Sorce <idra@samba.org>2010-07-28 12:21:29 -0400
commit146af48d4887e8fa0c66bf53aa5f204366648478 (patch)
treebf221210dd6e913ee5f43b252ee3597fe1c6c36c
parent250e341e0aad67c2f70fea597f34deadea1d2ccc (diff)
downloadsamba-146af48d4887e8fa0c66bf53aa5f204366648478.tar.gz
samba-146af48d4887e8fa0c66bf53aa5f204366648478.tar.bz2
samba-146af48d4887e8fa0c66bf53aa5f204366648478.zip
s3-dcerpc: revive cli_rpc_pipe_open_krb5()
-rw-r--r--source3/include/proto.h1
-rw-r--r--source3/rpc_client/cli_pipe.c3
-rw-r--r--source3/rpcclient/rpcclient.c9
3 files changed, 12 insertions, 1 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 5ad7fe4a24..1af36dd3e7 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -4842,6 +4842,7 @@ NTSTATUS cli_rpc_pipe_open_schannel(struct cli_state *cli,
struct rpc_pipe_client **presult);
NTSTATUS cli_rpc_pipe_open_krb5(struct cli_state *cli,
const struct ndr_syntax_id *interface,
+ enum dcerpc_transport_t transport,
enum dcerpc_AuthLevel auth_level,
const char *service_princ,
const char *username,
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c
index 12100c3449..ce34417cd7 100644
--- a/source3/rpc_client/cli_pipe.c
+++ b/source3/rpc_client/cli_pipe.c
@@ -3319,6 +3319,7 @@ NTSTATUS cli_rpc_pipe_open_schannel(struct cli_state *cli,
NTSTATUS cli_rpc_pipe_open_krb5(struct cli_state *cli,
const struct ndr_syntax_id *interface,
+ enum dcerpc_transport_t transport,
enum dcerpc_AuthLevel auth_level,
const char *service_princ,
const char *username,
@@ -3330,7 +3331,7 @@ NTSTATUS cli_rpc_pipe_open_krb5(struct cli_state *cli,
struct pipe_auth_data *auth;
NTSTATUS status;
- status = cli_rpc_pipe_open(cli, NCACN_NP, interface, &result);
+ status = cli_rpc_pipe_open(cli, transport, interface, &result);
if (!NT_STATUS_IS_OK(status)) {
return status;
}
diff --git a/source3/rpcclient/rpcclient.c b/source3/rpcclient/rpcclient.c
index 8b422a28a1..1ab3ac07f6 100644
--- a/source3/rpcclient/rpcclient.c
+++ b/source3/rpcclient/rpcclient.c
@@ -695,6 +695,15 @@ static NTSTATUS do_cmd(struct cli_state *cli,
get_cmdline_auth_info_domain(auth_info),
&cmd_entry->rpc_pipe);
break;
+ case DCERPC_AUTH_TYPE_KRB5:
+ ntresult = cli_rpc_pipe_open_krb5(
+ cli, cmd_entry->interface,
+ default_transport,
+ pipe_default_auth_level,
+ cli->desthost,
+ NULL, NULL,
+ &cmd_entry->rpc_pipe);
+ break;
default:
DEBUG(0, ("Could not initialise %s. Invalid "
"auth type %u\n",