diff --git a/bin/rdpy-rdpproxy b/bin/rdpy-rdpproxy index 5774d02..c5fb3e2 100755 --- a/bin/rdpy-rdpproxy +++ b/bin/rdpy-rdpproxy @@ -11,7 +11,7 @@ from rdpy.protocol.rdp import rdp class TestServerFactory(rdp.ServerFactory): def __init__(self): - rdp.ServerFactory.__init__(self, "/home/speyrefitte/dev/certificate/rdpy.key", "/home/speyrefitte/dev/certificate/rdpy.crt") + rdp.ServerFactory.__init__(self, "/home/sylvain/dev/certificate/rdpy.key", "/home/sylvain/dev/certificate/rdpy.crt") def startedConnecting(self, connector): pass diff --git a/rdpy/protocol/rdp/mcs.py b/rdpy/protocol/rdp/mcs.py index e117456..fa103ac 100644 --- a/rdpy/protocol/rdp/mcs.py +++ b/rdpy/protocol/rdp/mcs.py @@ -139,6 +139,7 @@ class MCS(LayerAutomata): self._clientSettings.getBlock(gcc.MessageType.CS_CORE).serverSelectedProtocol.value = self._transport._selectedProtocol self.sendConnectInitial() else: + self._serverSettings.getBlock(gcc.MessageType.SC_CORE).clientRequestedProtocol.value = self._transport._requestedProtocol self.setNextState(self.recvConnectInitial) def connectNextChannel(self): diff --git a/rdpy/protocol/rdp/tpdu.py b/rdpy/protocol/rdp/tpdu.py index 3b37861..1673e80 100644 --- a/rdpy/protocol/rdp/tpdu.py +++ b/rdpy/protocol/rdp/tpdu.py @@ -282,7 +282,6 @@ class ClientTLSContext(ssl.ClientContextFactory): """ def getContext(self): context = SSL.Context(SSL.TLSv1_METHOD) - context.set_options(0x00020000)#SSL_OP_NO_COMPRESSION context.set_options(SSL.OP_DONT_INSERT_EMPTY_FRAGMENTS) context.set_options(SSL.OP_TLS_BLOCK_PADDING_BUG) return context @@ -297,9 +296,8 @@ class ServerTLSContext(ssl.DefaultOpenSSLContextFactory): class TPDUSSLContext(SSL.Context): def __init__(self, method): SSL.Context.__init__(method) - self.set_options(0x00020000)#SSL_OP_NO_COMPRESSION self.set_options(SSL.OP_DONT_INSERT_EMPTY_FRAGMENTS) self.set_options(SSL.OP_TLS_BLOCK_PADDING_BUG) - - ssl.DefaultOpenSSLContextFactory.__init__(self, privateKeyFileName, certificateFileName, SSL.TLSv1_METHOD, TPDUSSLContext) + + ssl.DefaultOpenSSLContextFactory.__init__(self, privateKeyFileName, certificateFileName, SSL.SSLv23_METHOD, TPDUSSLContext) \ No newline at end of file