[SCM] Samba Shared Repository - branch master updated

Günther Deschner gd at samba.org
Thu Nov 12 17:17:47 MST 2009


The branch, master has been updated
       via  3732798... s3-rpcclient: use the parsed binding string flags for auth choice.
      from  d2a9f4a... Remove unused variable warning. Jeremy.

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 3732798008f26052c030e8a8fc9c9404fd6f5669
Author: Günther Deschner <gd at samba.org>
Date:   Thu Nov 12 16:45:33 2009 +0100

    s3-rpcclient: use the parsed binding string flags for auth choice.
    
    This allows rpcclient to be called like this:
    
    rpcclient ncacn_ip_tcp:w2k8r2[sign,seal] -U administrator%secret -c "dscracknames gd"
    
    Guenther

-----------------------------------------------------------------------

Summary of changes:
 source3/rpcclient/rpcclient.c |   18 ++++++++++++++++++
 1 files changed, 18 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/rpcclient/rpcclient.c b/source3/rpcclient/rpcclient.c
index dbf7f1f..5f59c26 100644
--- a/source3/rpcclient/rpcclient.c
+++ b/source3/rpcclient/rpcclient.c
@@ -965,6 +965,24 @@ out_free:
 		binding->transport = NCACN_NP;
 	}
 
+	if (binding->flags & DCERPC_SIGN) {
+		pipe_default_auth_level = DCERPC_AUTH_LEVEL_INTEGRITY;
+		pipe_default_auth_type = PIPE_AUTH_TYPE_NTLMSSP;
+	}
+	if (binding->flags & DCERPC_SEAL) {
+		pipe_default_auth_level = DCERPC_AUTH_LEVEL_PRIVACY;
+		pipe_default_auth_type = PIPE_AUTH_TYPE_NTLMSSP;
+	}
+	if (binding->flags & DCERPC_AUTH_SPNEGO) {
+		pipe_default_auth_type = PIPE_AUTH_TYPE_SPNEGO_NTLMSSP;
+	}
+	if (binding->flags & DCERPC_AUTH_NTLM) {
+		pipe_default_auth_type = PIPE_AUTH_TYPE_NTLMSSP;
+	}
+	if (binding->flags & DCERPC_AUTH_KRB5) {
+		pipe_default_auth_type = PIPE_AUTH_TYPE_SPNEGO_KRB5;
+	}
+
 	if (get_cmdline_auth_info_use_kerberos(rpcclient_auth_info)) {
 		flags |= CLI_FULL_CONNECTION_USE_KERBEROS |
 			 CLI_FULL_CONNECTION_FALLBACK_AFTER_KERBEROS;


-- 
Samba Shared Repository


More information about the samba-cvs mailing list