def clientConnectionLost(self, connector, reason):
        """
        @summary: Connection lost event
        @param connector: twisted connector use for rdp connection (use reconnect to restart connection)
        @param reason: str use to advertise reason of lost connection
        """
        #try reconnect with basic RDP security
        if reason.type == RDPSecurityNegoFail and self._nego:
            #stop nego
            log.info("due to security nego error back to standard RDP security layer")
            self._nego = False
            self._security = rdp.SecurityLevel.RDP_LEVEL_RDP
            self._client._widget.hide()
            connector.connect()
            return
        
        log.info("Lost connection : %s"%reason)
        reactor.stop()
        app.exit()
def clientConnectionLost ( self , connector , reason ) : if reason . type == RDPSecurityNegoFail and self . _nego : log . info ( "due to security nego error back to standard RDP security layer" ) self . _nego = False self . _security = rdp . SecurityLevel . RDP_LEVEL_RDP self . _client . _widget . hide ( ) connector . connect ( ) return log . info ( "Lost connection : %s" % reason ) reactor . stop ( ) app . exit ( )
@summary: Connection lost event
        @param connector: twisted connector use for rdp connection (use reconnect to restart connection)
        @param reason: str use to advertise reason of lost connection