Updated RDP scripts (simple cosmetic changes)

This commit is contained in:
Adolfo Gómez García 2021-09-23 16:53:17 +02:00
parent ef3dd893d9
commit cb8284d076
8 changed files with 21 additions and 28 deletions

View File

@ -7,7 +7,7 @@ globals()['sp'] = sp # type: ignore # pylint: disable=undefined-variable
def execUdsRdp(udsrdp):
import subprocess # @Reimport
import subprocess
import os.path
params = [os.path.expandvars(i) for i in [udsrdp] + sp['as_new_xfreerdp_params'] + ['/v:{}'.format(sp['address'])]] # type: ignore
@ -22,7 +22,7 @@ def execNewXFreeRdp(xfreerdp):
tools.addTaskToWait(subprocess.Popen(params))
# Try to locate a "valid" version of xfreerdp as first option (<1.1 does not allows drive redirections, so it will not be used if found)
# Try to locate a xfreerdp and udsrdp. udsrdp will be used if found.
xfreerdp = tools.findApp('xfreerdp')
udsrdp = tools.findApp('udsrdp')
fnc, app = None, None
@ -35,10 +35,9 @@ if udsrdp is not None:
if app is None or fnc is None:
raise Exception(
'''<p>You need to have installed xfreerdp (>= 1.1) or rdesktop, and have them in your PATH in order to connect to this UDS service.</p>
'''<p>You need to have xfreerdp (>= 2.0) installed on your systeam, and have it your PATH in order to connect to this UDS service.</p>
<p>Please, install the proper package for your system.</p>
<p>Also note that xfreerdp prior to version 1.1 will not be taken into consideration.</p>
'''
)
else:
fnc(app) # @UndefinedVariable
fnc(app)

View File

@ -1 +1 @@
byw3/YCTXrA7ROHh+Ol4tap8+4IHGyOoMRHeTYEz4G6DXCsRK3Fz0zHCIghNp0Oq4igfyjmoPRK8L5FMQhDln1VdTZFt9L4/vqIeBMUHO30PoVPXs8nhc9B+6gY6ZvAERgtRG/aEkCvNHstWdvZLUs54XdokcWDQacsmezepD3xvR8lj2eCufdYHbg99wgBwwgfqMCtvgpnZsXVssAmhpam4YhpIUb0xaisw470bcvouC0l9AeLsXumOpl+NGOYo9HQXk0LcqNChOua1y9IOe3VcD9HTffsi/3k96CTCMFgynr2TRaXlCSVMcwkg3n4hN2PdoKWSrNPUnEtgPxAUcQaDq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subprocess.Popen(params))
# Try to locate a "valid" version of xfreerdp as first option (<1.1 does not allows drive redirections, so it will not be used if found)
# Try to locate a xfreerdp and udsrdp. udsrdp will be used if found.
xfreerdp = tools.findApp('xfreerdp')
udsrdp = tools.findApp('udsrdp')
fnc, app = None, None
@ -37,19 +37,18 @@ if udsrdp:
if app is None or fnc is None:
raise Exception(
'''<p>You need to have installed xfreerdp (>= 1.1) or rdesktop, and have them in your PATH in order to connect to this UDS service.</p>
<p>Please, install apropiate package for your system.</p>
<p>Also note that xfreerdp prior to version 1.1 will not be taken into consideration.</p>
'''<p>You need to have xfreerdp (>= 2.0) installed on your systeam, and have it your PATH in order to connect to this UDS service.</p>
<p>Please, install the proper package for your system.</p>
'''
)
else:
# Open tunnel
fs = forward(remote=(sp['tunHost'], int(sp['tunPort'])), ticket=sp['ticket'], timeout=sp['tunWait'], check_certificate=sp['tunChk']) # type: ignore
# Check that tunnel works..
if fs.check() is False:
# Open tunnel and connect
fs = forward(remote=(sp['tunHost'], int(sp['tunPort'])), ticket=sp['ticket'], timeout=sp['tunWait'], check_certificate=sp['tunChk']) # type: ignore
# Check that tunnel works..
if fs.check() is False:
raise Exception(
'<p>Could not connect to tunnel server.</p><p>Please, check your network settings.</p>'
)
fnc(app, fs.server_address[1])
fnc(app, fs.server_address[1])

View File

@ -1 +1 @@
Jn+TxgKjznKd0NE+dQQcwWH3J+9n60qGdk9SrCzP4ew6M7XEG7QDtKTTWnCYpe3bABSihdD8NXwXmd9TVJ219vVhqjeBxLCZAKowdJRGThM+op7NagBvNNJ+QGg/kdkr5bucjtVdOB6+QpQ0oeyrRU9jgcSv4l9OstQaGsI9nKvRc+PV1I4JT64BDGgoqS1TIe40XF0tt9k477T30hxSeSIpQ7Tgn9V+SYABMnvpQKD/o6+pbofMxpOagEGD/jBujq2bfbmdvg1ZjzA06RYzg1b8sheaQ48TE3IQhx9pQdh0/DMzU1x92UiqG9IVJO8gNJJnPh6n2D1C8YaRjgQ9byN0Rq7WufHXtAWaaGbC128AZuUV1XgwWUgIYYxrN/Y2mbQ7xA+HSMd1/VQAmo4wOw1fKXbtB+IRIK7m5Go2VbD5n/CxEttyjQ6sprTqA2EeQJn84jWs7Gf8a4ztwb+yePYGCehYyhVCv+AoQDzeFDuAmGpiOMitk9+T000cJStZNbdrm9J0hKhMIGUZLWphoMHIA/gNtEAndSrvIEyx1Fg8hKEDTfhRl/1wex7JhB29QOy0lg5FMWaA7OInnIcpgyfYz/mqPADn6hVl6AqfYlSv8DshGMuXkDtcnVuUxUjuz+/rnzNpBwFBuN/4BHmMw2bSBzr/yTnOSMMAlimvLuo=
AORn+jRScHB88fR14guVUuSNlLRbJjMwWYGrWJv2aEMXCzrf5pMF2MHg41CIUXnPNFaR0XZEkrEAZRlmfzK601vpj5fSqIMhqXE7TPsdWKuq+LZj3rRrFdDQLc5D1xTD7QbxFaCCyldwa2gNIRSPlc+nT7LranH/j1aLYTaueK5GrNJCOYX+CUKl3pFFrQ+Jc7F3+qBpnxhLXk9kHi/p4Z1bLbQx2FxpeWdQnNNhwlkGIkVPWSQUhTI/SOrmKzKqGWDfP8OLNnBBW4mIJowwhS1wFhJ/TIlW5btbL1zwVa1vo/au55Q2/zbttFLarb6d2tnLVRUALIpMiC9r8o71LQ7yXMKnjcwgavQurY/AUlMUpEbD5w5ed7h/gn9HrFffMYqqXTcV5386aIh6HwdCgJxarFPlOG+w2GK2fgMetS9UDb+AIiYYGFRk6eJ014Y2mEHfQoPpM6wrPghuZ2Q405azgJH3ROeB4C8JWxlnpgkBJlri2KiEwufzuxVKLJEQoYiEC3Pm6CyjenIwqNcw5Ik0Zccuw7S72XjozcE1etfntb8piX13dnFQ/8lmnG4enIMUjPOncaYOSzcCh9IC7iFpjAaYC9mpYAwjJBGEtL9sFNTZx+w2D0PS0vNRUIjoR/PoZ1FGOiy3CiL7qKij/1I6QSIHOxp3wo4yROzR94I=

View File

@ -1,4 +1,3 @@
# pylint: disable=import-error, no-name-in-module, too-many-format-args, undefined-variable, invalid-sequence-index
import subprocess
import shutil
import os

View File

@ -1 +1 @@
k2MlUoIqtMvDVVJwW0/1BLrUqKtfOjxESXZqLeIrMtf45ioUJdrXYexkRlYZH9dbcnOvAukYwXn/UKurU7uIvsG18+Oyph7JfHydl4cDuneQAbMYOELvpbr2DfJGlCYE4p+FQHaLro9u5und80CMdyurG2QeqP1YAYidSrElNedokcmKMfxaOGTbdzY8E4I4i6Mt5A3d7pizhClynKgRNXOnukf3f3rTkVS1DQB0FheQQfZkHQJQo0W/1TBomj+zpi1/3iUd09tcOCs2F3rnz1JZkQnJcMt41wCtDUhClZUUTT4tb23PmXiMsJ4ARYIojyTALUAT+a56TCL0eSAs9o+8rAFEd3/VbG8Top6B/SjTUt/34Dvgef9sbjobuDEtvVQHUSNJ8btsPcuvxedstRKkRKeHOOYsFdRTl4gJrdyFqFGVvHph8mlcsjS18z3u6I5ZGH0mEa2kq5bHdZBTlPujl92xZwUwmlKy8zsKyyG6H33rxKZ16AbKu/Z2I102WHBIQeUWJAV7sQi56tZImJqTvZgod3FteK+hekuCGnnLataY6NwRdaIp97EXQCO7JrqK/y84/rn9p90KtIdUDHAlQMK7yEmGBmJ+i3lpLFTjPe1A1P+0O1J45WnqOBuF/UFPxtHr5yeLqRUZz3Fp93CprgzJBzmoqAw8Je8w85o=
hWCOxfB6KhYm93AeRp3dBe0LOYNjRdlBMzgTYlRlIe89Kiq2YyO9ap/cYG9xT8+oClWTQwhL7esSrE/7sH0bo7OSy5X2EwjNreP2hET+F+1oDEKMlJiYh3ZkN+TWQXf6kuylnp1LMsVSpMIGEJ9qZ2xgdsngyxJTh1LIPHdX2hBi4JgjUSz37PNiGXTbtUS89QvY4yrBT1Vajai28RlsnUMnwW4X9YPfk1s7++GY//wjdpd2vPwwQvfLs+70KwpWYKo3UkLdRW6Tpkhbw8IbM9wF1MrT1ID1k6//hBJ5pFa7m2vacsx7zIviETsUMIs9Zol3YNBetFsllNX+mlPNxEQv/s23DMt41ibHsiTk8+FMHphmPidlAwQNhNTfb+FIIRRa9MFb88lm/5l8NYqx5Vb48KiD8K6xE6+HOrFm0wU3MkeA1nfDlO1xotp/ze8Ur2iVA50QebrgUkDkEGO1GybU5IUSo1k/DesNHspIv8nej5BsLrbMPxDApCsUki7d2Ufr4aHgcc2CNLJrVT71yXcCW7ngLUIz4wnjBxCnQwP1AsIA4uXOHbqs0lXZ3yde2wCqQUsHpR1R1BtVOxQzbwezsAbYHNJROQlqpDltwSg8Fy0enFuYy4znVAN/5VxUARCWSN77/O3VniW3ll365eoHDI5Zh4UrKOgqFxTrr28=

View File

@ -1,7 +1,3 @@
# This is a template
# Saved as .py for easier editing
from __future__ import unicode_literals
# pylint: disable=import-error, no-name-in-module, too-many-format-args, undefined-variable, invalid-sequence-index
import subprocess
import shutil

View File

@ -1 +1 @@
mXksARM07umS8DEB4cQfXHzmiOlfO2pRApXYFu9283FqNnRLquXb5NbNyS5eZ7n0WW7mwC6XXGSs6V3KKtzJEzgs6rQKDR6ZXFYqO5vqkeuEnAIakX66Jg//43E2tZVVHOn/wQrJXLvNFv3WFI6+EeNXZOnydiSBP5N3Omh3DwO+xegDFOyv8V7Keo2iTZK1Pyihs1dZfDs5+v3fmPNX4GoSAMDqVDMC9AeMoEFIVvLHOfc+XFVrwZVKqKDhoMyT1Zsw970KHugb2szX7FFRaHdO1FNWuFFlkjKAqiSHfD/dBZxsK0BzdHulVqyHDpLWNmDCqR5TpvwclYGAz4qboT6RAzYBXSGLArdyGEoVpiRd4/eTrRwQxnbVsXls1prkeCctAkVZMajvYekmG0KKxZ5t8yUF2wSlr3J/b2xbuHhioYGKfNGvrj1RSfjl1WbTF3oKm8iEpaxXtC7tjSvt5mM/fu+O553nj1jDSJgFWUJLkZ1MlPHH3nEerAT/OW8nCRHKRfQYH8CblB9GZ5Iew4yyHptjj2tKnrAatKa+w/B+R1pySMLO7V9Qwj0adc4WIzQohtFKxG7aDAbQ3eRVRimjoIw5XvErvT1oj3ThGkTqnz55bSd+IpTOQk5lWQH3Z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