www.cendio.com
Bug 7094 - Dynamic session resize for tl-run-rdesktop
: Dynamic session resize for tl-run-rdesktop
Status: CLOSED FIXED
: ThinLinc
| rdesktop (deprecated)
: trunk
: PC Unknown
: P2 Normal
: 4.9.0
Assigned To:
:
:
:
: 6096
  Show dependency treegraph
 
Reported: 2017-12-19 10:45 by
Modified: 2018-03-29 14:42 (History)
Acceptance Criteria:


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From cendio 2017-12-19 10:45:14
When connecting to a Windows server using tl-run-rdesktop the user might want
to resize the window and the Windows session. This is currently only possible
when running tl-run-windesk or tl-run-rdesktop in fullscreen inside a ThinLinc
session. It will then follow the size of the ThinLinc session.

This should be possible even when using windowed mode.
------- Comment #1 From cendio 2017-12-19 10:45:59 -------
Fixed with rdesktop vendordrop done in r32951.
------- Comment #2 From cendio 2017-12-19 10:54:17 -------
https://github.com/rdesktop/rdesktop/pull/206
------- Comment #3 From cendio 2017-12-19 12:32:21 -------
Pressing Ctrl+Alt+Enter when running tl-run-rdesktop in windowed mode in a
ThinLinc crashes rdesktop:

> X Error of failed request:  BadMatch (invalid parameter attributes)
>    Major opcode of failed request:  42  (X_SetInputFocus)
>    Serial number of failed request:  5158 
>    Current serial number in output stream:  5161 
>  Connection error: The connection to the Remote Desktop failed with error 1

Windows server 2016, nightly ThinLinc-rdesktop.
------- Comment #4 From cendio 2017-12-19 16:31:10 -------
(In reply to comment #3)
> >  Connection error: The connection to the Remote Desktop failed with error 1

Also note that rdesktop exits with value 1. This is weird, rdesktop aims to
return the RDP exit codes plus some of it's own. This exit code means that an
administrator disconnected the session:

https://msdn.microsoft.com/en-us/library/cc240544.aspx
------- Comment #5 From cendio 2017-12-19 17:02:46 -------
(In reply to comment #3)
> Pressing Ctrl+Alt+Enter when running tl-run-rdesktop in windowed mode in a
> ThinLinc crashes rdesktop:
> 
> > X Error of failed request:  BadMatch (invalid parameter attributes)
> >    Major opcode of failed request:  42  (X_SetInputFocus)
> >    Serial number of failed request:  5158 
> >    Current serial number in output stream:  5161 
> >  Connection error: The connection to the Remote Desktop failed with error 1
> 
> Windows server 2016, nightly ThinLinc-rdesktop.

thinlinc-rdesktop-4.8.0post-5646.r32962.i686 on 32-bit RHEL6 works great with
Windows Server 2016.
------- Comment #6 From cendio 2017-12-19 17:16:20 -------
Running rdesktop with '-g workarea' triggers a reconnect loop bug.
------- Comment #7 From cendio 2017-12-20 10:21:53 -------
Further info about the case where I see the crash:

Server: ThinLinc server build 5646, Fedora 27, running XFCE4 inside the
session, starting tl-run-rdesktop manually from a terminal within the session

Client: ThinLinc client build 5646, Fedora 27 (same machine as server), running
Wayland
------- Comment #8 From cendio 2017-12-20 10:23:14 -------
I can reliably reproduce it when running inside a ThinLinc session, but I can
not reproduce the crash when doing the same procedure locally outside of
ThinLinc.
------- Comment #9 From cendio 2018-01-11 15:27:12 -------
> Running rdesktop with '-g workarea' triggers a reconnect loop bug.

This was identified as an bug in the original dynamic resize commit were
ui_init_connection() was called within the connect while loop, and not
only once. 

[1]
https://github.com/rdesktop/rdesktop/pull/232/commits/8ef9f39aa815968caf39de8a549956f3d88726e5


> I can reliably reproduce it when running inside a ThinLinc session, but I can
> not reproduce the crash when doing the same procedure locally outside of
> ThinLinc.

I could also only reproduced this X11 BadMatch crash, but the problem could
also be that the rdesktop window disappeared. The bug is an regression and it
has been fixed upstream in commit [1]

[1]
https://github.com/rdesktop/rdesktop/pull/232/commits/a6d82619ee7ef5c1853869e56315e80a10d76f9b
------- Comment #11 From cendio 2018-01-15 14:35:29 -------
(In reply to comment #9)
> > I can reliably reproduce it when running inside a ThinLinc session, but I can
> > not reproduce the crash when doing the same procedure locally outside of
> > ThinLinc.
> 
> I could also only reproduced this X11 BadMatch crash, but the problem could
> also be that the rdesktop window disappeared. The bug is an regression and it
> has been fixed upstream in commit [1]
> 
> [1]
> https://github.com/rdesktop/rdesktop/pull/232/commits/a6d82619ee7ef5c1853869e56315e80a10d76f9b
>

Verified that i could not reproduce this problem using jenkins build #1042
which includes
the vendordrop of rdesktop.
------- Comment #12 From cendio 2018-01-15 14:40:00 -------
(In reply to comment #9)
> > Running rdesktop with '-g workarea' triggers a reconnect loop bug.
> 
> This was identified as an bug in the original dynamic resize commit were
> ui_init_connection() was called within the connect while loop, and not
> only once. 
> 
> [1]
> https://github.com/rdesktop/rdesktop/pull/232/commits/8ef9f39aa815968caf39de8a549956f3d88726e5
> 
> 

I couldn't reproduce a reconnect loop using `-g workarea` or by the equivalent
`-g 100%`
------- Comment #13 From cendio 2018-01-15 14:40:53 -------
I also verified basic functionality with seamless rdp and resizing the
vncviewer window, works as expected.
------- Comment #14 From cendio 2018-01-16 14:21:58 -------
Found a problem with Windows 2008 and the Unity DE on Ubuntu 16.04: If you
request a size bigger than the session (or don't give -g at all), there will be
2 resizes ie 3 connection attempts. Sometimes, this results in an error
message:

Windows Server: Remote Desktop Error: The task you are trying to do can't be
completed because Remote Desktop Services is currently busy

(See
https://social.technet.microsoft.com/wiki/contents/articles/28636.windows-server-remote-desktop-error-the-task-you-are-trying-to-do-can-t-be-completed-because-remote-desktop-services-is-currently-busy.aspx)

I've also seen that you'll end up in the login/authentication dialog, even
though I submitted the password on the command line prompt.
------- Comment #15 From cendio 2018-01-17 09:35:14 -------
Known "unfixable" problem:

With a 2008 Windows Server, if you rapidly toggle in and out of full screen you
might be logged out.

This is caused by 2008 not supporting RDPEDISP and is using reconnects when
changing window sizes. To avoid manual logins a cookie from the server is used.
With rapid toggling the cookie might expire between reconnects and the client
fails to fetch a new cookie.

As long as reconnects and cookies are used this problem will potentially exist.
------- Comment #16 From cendio 2018-01-17 10:19:20 -------
Found a problem with seamless with a 2008R2 server causing the session size to
be wrong.

Create a seamless notepad enlarge the root window. The session size is still
the original size causing clipping (not refreshing) of the notepad window. The
window is also docked at the session window border and not on the root window
border.
------- Comment #18 From cendio 2018-01-22 16:32:28 -------
(In reply to comment #14)
> Found a problem with Windows 2008 and the Unity DE on Ubuntu 16.04: If you
> request a size bigger than the session (or don't give -g at all), there will be
> 2 resizes ie 3 connection attempts. Sometimes, this results in an error
> message:
> 
> Windows Server: Remote Desktop Error: The task you are trying to do can't be
> completed because Remote Desktop Services is currently busy
> 
> (See
> https://social.technet.microsoft.com/wiki/contents/articles/28636.windows-server-remote-desktop-error-the-task-you-are-trying-to-do-can-t-be-completed-because-remote-desktop-services-is-currently-busy.aspx)
> 
> I've also seen that you'll end up in the login/authentication dialog, even
> though I submitted the password on the command line prompt.

The problem is not related to unity, it just provokes the issue better. I can
reproduce the same problem using MSTSC or running rdesktop on any platform. The
key is that it is only reproducible if there is no session started and the
server needs to bring up a session.

The problem seems to be related to profiles due to the problem is reproducible
when using local user on the Window 2008 R2 server. I have search relevant
information on the web and found a lot of indication to the source of the
problem beeing slow winlogin due to roaming profiles or communication with the
domain controller.

To reproduce the problem do this:

- Launch a RDP client and when you see "Welcome" screen, disconnect from the
server by closing the window, this seems to put the session in a "busy" state
and if you connect a second time you will be prevented with that message. Even
if you connect using a different machine.

Also you need to reconnect relative fast due to the session seems to recover
from this state, normally within a few seconds but I have seen cases up to a
minute before you can connect again.
------- Comment #19 From cendio 2018-01-22 16:43:18 -------
(In reply to comment #15)
> Known "unfixable" problem:
> 
> With a 2008 Windows Server, if you rapidly toggle in and out of full screen you
> might be logged out.
> 
> This is caused by 2008 not supporting RDPEDISP and is using reconnects when
> changing window sizes. To avoid manual logins a cookie from the server is used.
> With rapid toggling the cookie might expire between reconnects and the client
> fails to fetch a new cookie.
> 
> As long as reconnects and cookies are used this problem will potentially exist.

Not fully really unfixable and might also be a bug:

rdesktop puts username/password into global variables, and when the first Data
PDU is received the password is cleared. If a pending reconnect is carried out
before a login info pdu packet has been received, the packet that carries a
auto reconnect cookie from the server and a data pdu has been received that
clears the password, the reconnect will carried out using no password and no
cookie and therefor a login screen is shown.

The simplest solution to this might just be to hold the password in memory
until we have received a auto reconnect cookie in the logon info pdu packet.
------- Comment #20 From cendio 2018-01-22 17:08:51 -------
(In reply to comment #19)
> rdesktop puts username/password into global variables, and when the first Data
> PDU is received the password is cleared. If a pending reconnect is carried out
> before a login info pdu packet has been received, the packet that carries a
> auto reconnect cookie from the server and a data pdu has been received that
> clears the password, the reconnect will carried out using no password and no
> cookie and therefor a login screen is shown.
> 
> The simplest solution to this might just be to hold the password in memory
> until we have received a auto reconnect cookie in the logon info pdu packet.
>

Or defer pending resize request until we actually got the autoreconnect cookie.
I favor this due to its makes disconnect/reconnect independent of password and
we could then probably move the clear of password from memory to an earlier
stage in the connect sequence for even better security. However not before the
redirect disconnect/reconnect sequence which needs the password.
------- Comment #21 From cendio 2018-01-22 18:11:14 -------
(In reply to comment #16)
> Found a problem with seamless with a 2008R2 server causing the session size to
> be wrong.
> 
> Create a seamless notepad enlarge the root window. The session size is still
> the original size causing clipping (not refreshing) of the notepad window. The
> window is also docked at the session window border and not on the root window
> border.

Rdesktop is definitely confused of what resolution it should resize to during
a root window triggered resize, 1920x1136 is the origin session size in this
log: 

  UI(debug): ui_set_cursor(): g_current_cursor = 0x3000149, new = 0x300012a
  Core(debug): seamless_process_line(), got 'ACK,498,10'
  UI(debug): xwin_process_events(), ConfigureNotify: Root window changed to
1024x768
  Window resize detected, reconnecting to new size 1920x1136
  Disconnecting...
  Resize reconnect loop triggered, new size 1920x1136
  Connecting to server using NLA...
  Failed to initialize NLA, do you have correct Kerberos TGT initialized ?
  Failed to connect using NLA, trying with SSL
  Core(debug): GSS error [0:13:0]: cssp_connect(), negotiation failed.
  Core(debug):  - Unspecified GSS failure.  Minor code may provide more
information
  Connection established using SSL.
  UI(debug): ui_create_window() width = 1920, height = 1136
  UI(warning): Broken Window Manager: doesn't handle restack (window was moved
to bottom)
------- Comment #22 From cendio 2018-01-29 14:54:47 -------
Regression: no window is shown while being redirected to another server (tested
with 2012R2, 2016) when using CredSSP/Kerberos.

This has been fixed upstream.


https://github.com/rdesktop/rdesktop/commit/54c38f7f62c2a0341132db007bf2dfcf6886c910
------- Comment #23 From cendio 2018-01-31 12:03:35 -------
After toggling from fullscreen to window mode, you (rarely) get a black
screen/window.
------- Comment #24 From cendio 2018-01-31 12:03:51 -------
SeamlessRDP does not resize its background window after a root window resize,
leading to windows that are larger/smaller than the screen when maximized.
------- Comment #25 From cendio 2018-01-31 12:03:59 -------
Resizing a 2008 session during session startup can lead to the session being
stuck in a "hanged" state, preventing login. This is common with Unity, which
is happy to reconfigure/resize the rdesktop window on startup.
------- Comment #27 From cendio 2018-01-31 14:51:48 -------
(In reply to comment #23)
> After toggling from fullscreen to window mode, you (rarely) get a black
> screen/window.

We have not been able to reproduce this scenario with the latest iteration of
the code. We've decided to leave this unsolved until we have a reliable way to
reproduce the problem.
------- Comment #28 From cendio 2018-01-31 14:52:59 -------
(In reply to comment #22)
> Regression: no window is shown while being redirected to another server (tested
> with 2012R2, 2016) when using CredSSP/Kerberos.
> 
> This has been fixed upstream.
> 
> https://github.com/rdesktop/rdesktop/commit/54c38f7f62c2a0341132db007bf2dfcf6886c910

Brought to ctc in r33032.
------- Comment #29 From cendio 2018-02-06 14:27:46 -------
Another problem found on CentOS 6 with XFCE, using the latest rdesktop against
VirtualBox (which does not accept resize):

$ RDESKTOP_DEBUG=Core,UI ./rdesktop scilla -f
Autoselecting keyboard map 'sv' from locale
Password: 
UI(debug): RDP depth: 24, display depth: 24, display bpp: 32, X server BE: 0,
host BE: 0

Core(debug): dvc_channels_add(), Added hash=67f73722, channel_id=-1,
name=Microsoft::Windows::RDS::DisplayControl, handler=0x4385d0
Connecting to server using SSL...
Protocol(warning): Protocol negotiation failed with reason: no valid
authentication certificate on server
Retrying with plain RDP.
UI(debug): ui_create_window() width = 3200, height = 1200
UI(debug): ui_create_cursor(): xhot=0, yhot=0, width=1, height=1, bpp=24
UI(debug): ui_resize_window(), Changing window 3200x1200 to match new session
720x400 size
Connection successful
UI(debug): xwin_process_events(), Window mapped with size 720x400
UI(debug): xwin_process_events(), ConfigureNotify: session: 720x400, new
window: 720x400 (adj: 720x400)
Clipboard(error): xclip_handle_SelectionNotify(), unable to find a textual
target to satisfy RDP clipboard text request

A window is created in the upper left corner and does not cover the entire
desktop. It is possible to interact both with the rdesktop window and the rest
of the desktop, even though in "fullscreen mode".
------- Comment #31 From cendio 2018-02-16 10:30:31 -------
(In reply to comment #29)
> Another problem found on CentOS 6 with XFCE, using the latest rdesktop against
> VirtualBox (which does not accept resize):
> 
> [...]
> 
> A window is created in the upper left corner and does not cover the entire
> desktop. It is possible to interact both with the rdesktop window and the rest
> of the desktop, even though in "fullscreen mode".

Fixed by vendor drop in r33056.
------- Comment #32 From cendio 2018-02-22 09:00:55 -------
The vendor drops made on this bug has pulled following three unrelated 
bug fixes that needs testing...

e112b69 Use proper user-initiated disconnect sequence

 "A correct user initated disconnect sequence should send
  a MCS Disconnect Provider Ultimatum PDU defined in T.128
  upon a disconnect. This commit adds the implementation
  the mentioned PDU and the actual write of the packet."


c58d91c Fix file sizes for redirected disks

 Previously, max file size was truncated to 32bit, eg 4Gb size
 file, with this commit, it now uses 64bit file sizes.
 Theoretically judging by code, a test could be just showing a
 directory with a file bigger that 5Gb and you should see difference
 int the file sizes in explore before and after this fix.


e3fbadf Fix scard handling of PCSCv2 Part 10.

 This is a fix for smartcard readers with pinpad, however it touches
 code that we believed was require. We need to do a regression test
 using normal smart card operations such as login and redirect 
 (encrypt/decrytp) file.
------- Comment #33 From cendio 2018-02-27 14:38:11 -------
The current nighlty build (5708) is not working well at all for me:

 - Connections to rds10 fail with error code 76 (protocol error). Nothing
printed to stderr. The other servers work fine. Only happens when CredSSP is
used.

 - SSO in tl-run-rdesktop doesn't work. I get a server side prompt for
password. Without CredSSP I get a prompt for smart card auth.

 - Pressing escape in the server side prompt just reconnects and I'm stuck
until I close the rdesktop window instead.
------- Comment #34 From cendio 2018-02-27 14:55:05 -------
(In reply to comment #33)
> 
>  - Connections to rds10 fail with error code 76 (protocol error). Nothing
> printed to stderr. The other servers work fine. Only happens when CredSSP is
> used.
> 

This no longer happens after a reboot of rds10.
------- Comment #35 From cendio 2018-02-27 14:59:38 -------
(In reply to comment #33)
> 
>  - SSO in tl-run-rdesktop doesn't work. I get a server side prompt for
> password. Without CredSSP I get a prompt for smart card auth.
> 

See bug 7100 where we did the local workaround for SSO handling.
------- Comment #37 From cendio 2018-03-01 14:01:52 -------
(In reply to comment #33)
>
>  - Pressing escape in the server side prompt just reconnects and I'm stuck
> until I close the rdesktop window instead.
>

Fix brought via vendor drop in revision r33084
------- Comment #39 From cendio 2018-03-07 14:44:56 -------
One subtle change from this is that -g with percentages behaves slightly
different:

 1. Since you can resize the window it might not keep the specified percentage
forever, and it is now about the initial size

 2. It no longer updates the window size when the resolution changes (e.g. when
resizing the ThinLinc client window)

Might not be an issue in practice, but the man page needs to be updated as it
states:

>              If  the  specified  geometry depends on the screen size, and the
>              screen size is changed, rdesktop  will  automatically  reconnect
>              using  the new screen size. This requires that rdesktop has been
>              compiled with RandR support.

However this also affects "-g workarea", which is used by tl-run-winapp. But
that seems to be broken in the latest release as well as it doesn't track
workarea reliably (tested with 4.8.0 on RHEL 6 with GNOME). And perhaps
tl-run-winapp should stop using that argument now that we have more dynamic
resizing.
------- Comment #40 From cendio 2018-03-07 14:46:41 -------
(In reply to comment #39)
> 
>  2. It no longer updates the window size when the resolution changes (e.g. when
> resizing the ThinLinc client window)
> 

Another issue here is that it still reconnects when this happens, even though
it keeps the same size.
------- Comment #41 From cendio 2018-03-08 11:07:55 -------
Tested Windows 2008 R2, 2012 R2 and 2016 with Ubuntu 16.04 and Unity in
ThinLinc. Tested full screen, various -g arguments, resizing of rdesktop and
the session.

2012 and 2016 work really well without any issues. 2008 has some positioning
problems when reconnecting, but they are not regressions so we'll open new bugs
for those.
------- Comment #42 From cendio 2018-03-08 11:10:19 -------
Tested SeamlessRDP with 2008 R2 and 2016 with Ubuntu 16.04 and Unity in
ThinLinc. Could not find any issues where it would misbehave when the session
resizes.
------- Comment #43 From cendio 2018-03-08 16:28:42 -------
(In reply to comment #36)
> ------------------------------------------------------------------------
> r33084 | pairstation | trunk/ctc/rdesktop/rdesktop/
> 
> Bring vendor drop to CTC
> 
> This brings a fix for a reconnect loop reported on bug #7094
> comment #33.
> 
> 
> ------------------------------------------------------------------------

I'm still getting a reconnect loop with 2008. :/

This command line:

> /opt/thinlinc/bin/rdesktop -k sv -d LAB -u ossman rds2008.lab.lkpg.cendio.se
------- Comment #44 From cendio 2018-03-08 16:39:16 -------
Found two issues with 2008 and Unity:

 - For a very small screen (800x600), the rdesktop window gets maximised by
default, and I am unable to un-maximize it. Every attempt triggers a resize,
which re-maximizes it.

 - On a local display (not ThinLinc), I get a server login prompt after the
first resize
------- Comment #45 From cendio 2018-03-09 14:39:18 -------
(In reply to comment #43)
> 
> I'm still getting a reconnect loop with 2008. :/
> 
> This command line:
> 
> > /opt/thinlinc/bin/rdesktop -k sv -d LAB -u ossman rds2008.lab.lkpg.cendio.se

Seen on two different Ubuntu 16.04 machines. Happens with both Unity and Xfce.
Happens with both a new session, and reconnecting. Neither redirection nor
CredSSP seem to affect things.

With full debugging, this is the only thing seen between the Escape and
disconnect:

> Keyboard(debug): KeyPress for keysym (0xff1b, Escape)
> Keyboard(debug): xkeymap_translate_key(), found scancode translation, scancode=0x1, modifiers=0x400
> Keyboard(debug): rdp_send_scancode(), sending scancode=0x1, flags=0x0
> Protocol(debug): rdp_send_input()
> Protocol(debug): rdp_send_input()
> Protocol(debug): rdp_send_input()
> Protocol(debug): rdp_send_input()
> Protocol(debug): rdp_send_input()
> Protocol(debug): rdp_recv(), RDP packet #6, type 0x7
> Protocol(debug): process_ts_set_error_info_pdu(), error info = 0
> Protocol(debug): rdp_recv(), RDP packet #7, type 0x6
> Protocol(debug): rdp_loop(), RDP_PDU_DEACTIVATE packet received
> Disconnecting...
> Protocol(debug): rdp_disconnect()
------- Comment #46 From cendio 2018-03-09 14:48:01 -------
(In reply to comment #44)
> 
>  - On a local display (not ThinLinc), I get a server login prompt after the
> first resize

This happens in ThinLinc as well. It is a bit random though, so it just seems
the local display was better att triggering it.

Debug output shows it getting the cookie:

> Protocol(debug): rdp_recv(), RDP packet #14, type 0x7
> Protocol(debug): process_data_pdu(), received Logon PDU
> Protocol(debug): process_pdu_logon(), Received TS_LOGIN_INFO_EXTENDED
> Protocol(debug): process_ts_logon_info_extended()
> Protocol(debug): process_ts_logon_info_extended(), saving Auto-Reconnect cookie, id=5

And using it during the reconnect:

> Protocol(debug): rdp_send_logon_info(), sending RDP5-style Logon packet
> Protocol(debug): rdp_send_logon_info(), called sec_init with packetlen 350
> Protocol(debug): rdp_send_logon_info(), Sending auto-reconnect cookie.
------- Comment #47 From cendio 2018-03-09 16:12:24 -------
After some more debugging we think we've figured out the issue; a cookie is
only valid for the server that issued it. We cannot use it for another server
and hope to be redirected.

This explains why things were a bit random. We had the following scenarios:

a) Ubuntu 1, using a named DNS:

   - Connect to rds2008, resolved to rds2008-1
   - Redirect to rds2008-2, store that address
   - Resize
   - Reconnect to rds2008-2

   OK

b) Ubuntu 1, using a named DNS:

   - Connect to rds2008, resolved to rds2008-2
   - Resize
   - Reconnect to rds2008, resolved to rds2008-1

   FAIL

c) Ubuntu 2, using a Microsoft DNS:

   - Connect to rds2008, resolved to rds2008-1
   - Redirect to rds2008-2, store that address
   - Resize
   - Reconnect to rds2008-2

   OK

d) Ubuntu 2, using a Microsoft DNS:

   - Connect to rds2008, resolved to rds2008-2
   - Resize
   - Reconnect to rds2008, resolved to rds2008-2

   OK

e) Ubuntu 2, using a Microsoft DNS, bad timing:

   - Connect to rds2008, resolved to rds2008-2
   - Resize
   - Reconnect to rds2008, resolved to rds2008-1

   FAIL

named uses a per request round robin, so you always got swapped results for
each request. Microsoft's DNS however swaps every second, no matter the number
of requests. So you had to time things just right to provoke the bug.
------- Comment #48 From cendio 2018-03-13 18:14:56 -------
(In reply to comment #44)
>  - On a local display (not ThinLinc), I get a server login prompt after the
> first resize

(In reply to comment #44)
> named uses a per request round robin, so you always got swapped results for
> each request. Microsoft's DNS however swaps every second, no matter the
> number of requests. So you had to time things just right to provoke the bug.

https://github.com/rdesktop/rdesktop/pull/249

would appreciate feedback before merging, not feeling very confident about this
------- Comment #50 From cendio 2018-03-23 14:32:11 -------
(In reply to comment #43)
> 
> I'm still getting a reconnect loop with 2008. :/
> 

Works well now. I also did the following as regression test:

 - Disconnecting and logging out the session as an admin

 - Reconnect after network errors

This worked well on 2008 R2. However not so much on 2012 R2:

 a) I get a reconnect loop there now

 b) Throwing out the user as admin results in an immediate reconnect (probably
same issue as a))

 c) The reconnect after network error results in an incorrectly resized and
clipped session. It seems to revert to the session size it started with.

b) also happens on 2016
------- Comment #51 From cendio 2018-03-23 14:35:23 -------
(In reply to comment #44)
> 
>  - On a local display (not ThinLinc), I get a server login prompt after the
> first resize

This works well now. I can confirm using the debug output that it will reuse
the same IP address on every reconnect.
------- Comment #53 From cendio 2018-03-29 13:13:32 -------
Re-tested:

  - Aborting server side login
  - name resolution on reconnect
  - Disconnect/logout by admin
  - Network problems (including resize)

Tested with 2008 R2, 2012 R2, 2016.
------- Comment #54 From cendio 2018-03-29 14:22:26 -------
All window placement issues have been forked off to bug 7140.
------- Comment #56 From cendio 2018-03-29 14:42:15 -------
Everything is now working and tested.