590d18
From 2585d6d6455d7c9257a8bbc65cc489d4a424a08e Mon Sep 17 00:00:00 2001
590d18
From: Alexander Bokovoy <abokovoy@redhat.com>
590d18
Date: Wed, 5 Aug 2015 21:33:45 +0300
590d18
Subject: [PATCH] Fix selector of protocol for LSA RPC binding string
590d18
590d18
For Windows Server 2012R2 and others which force SMB2 protocol use
590d18
we have to specify right DCE RPC binding options.
590d18
590d18
For using SMB1 protocol we have to omit specifying SMB2 protocol and
590d18
anything else or otherwise SMB1 would be considered a pipe to connect
590d18
to. This is by design of a binding string format.
590d18
590d18
https://fedorahosted.org/freeipa/ticket/5183
590d18
590d18
Reviewed-By: Tomas Babej <tbabej@redhat.com>
590d18
---
590d18
 ipaserver/dcerpc.py | 4 ++--
590d18
 1 file changed, 2 insertions(+), 2 deletions(-)
590d18
590d18
diff --git a/ipaserver/dcerpc.py b/ipaserver/dcerpc.py
590d18
index c604fa3eae4cf94d719190a5a3e3de15d3841d24..74b4743d4bfb9c4950f441f1aa3561fc7a81391c 100644
590d18
--- a/ipaserver/dcerpc.py
590d18
+++ b/ipaserver/dcerpc.py
590d18
@@ -854,8 +854,8 @@ class TrustDomainInstance(object):
590d18
         We try NCACN_NP before NCACN_IP_TCP and use SMB2 before SMB1 or defaults.
590d18
         """
590d18
         transports = (u'ncacn_np', u'ncacn_ip_tcp')
590d18
-        options = ( u'smb2', u'smb1', u'')
590d18
-        binding_template=lambda x,y,z: u'%s:%s[%s,print]' % (x, y, z)
590d18
+        options = ( u'smb2,print', u'print')
590d18
+        binding_template=lambda x,y,z: u'%s:%s[%s]' % (x, y, z)
590d18
         return [binding_template(t, remote_host, o) for t in transports for o in options]
590d18
 
590d18
     def retrieve_anonymously(self, remote_host, discover_srv=False, search_pdc=False):
590d18
-- 
590d18
2.4.3
590d18