Resize session using disconnect/reconnect sequence should not be
performed before we have received an auto-reconnect cookie which is
used for reconnecting to the session. There is a race when trying to
reconnect at this point so a defer timer is used to delay this further
from the point where the auto-reconnect cookie is received.
Fixes a problem where a login prompt is shown upon reconnect even if
the auto-reconnect cookie is available and used.
Signed-off-by: Henrik Andersson <hean01@cendio.com>
Signed-off-by: Karl Mikaelsson <derfian@cendio.se>
Extract ui_init_connection() into smaller functions
to clarify purpose.
Signed-off-by: Henrik Andersson <hean01@cendio.com>
Signed-off-by: Thomas Nilefalk <thoni56@cendio.se>
Move ui_init_connection() outside main loop since it is the source for the
fight of requested session size after a resize reconnect. This should only
be called once for setting up initial requested session size via command
line args.
Signed-off-by: Henrik Andersson <hean01@cendio.com>
Signed-off-by: Thomas Nilefalk <thoni56@cendio.se>
This adds support for resizing the RDP session dynamically based on
the window size. Some complicated logic has been added to avoid
sending excessive amounts of resize requests to the RDP server.
When supported, this resize mechanism should use the RDPEDISP way of
signalling the server to initiate a Deactivate/Activate sequence, but
rdesktop will fall back on Disconnect/Reconnect if RDPEDISP is not
supported by the server.
ui_select has been refactored and most functionality has been broken
out into three new functions, simplifying ui_select into a loop.
Signed-off-by: Henrik Andersson <hean01@cendio.com>
Signed-off-by: Karl Mikaelsson <derfian@cendio.se>
Signed-off-by: Thomas Nilefalk <thoni56@cendio.se>
g_bitmap_compression is a global variable scattered through the code
but only accessed and used in one place; rdp_out_bitmap_caps().
Demoted it to localvariable and replaced with hardcoded value.
Most of the RPD protocol errors (reason > 0x1000) would only be
triggered by coding errors in the client. A few of them can occur due
to server errors however. We should attempt to handle these cases.
There seems to have been confusion with regards to which exit code and
message was returned by rdesktop for the following cases:
* disconnected by admin
* logged out by admin
* disconnect by user
* logoff by user
Looking at Microsoft's official documentation as well as testing using
Windows Server 2008 R2, 2012 R2 and 2016 reveals that this commit fixes
this issue. They do now match the reasons sent by the server.
This fixes several issues where credentials are required
before the connection is carried out. Such as dual
authentication prompts when redirected by load balancer.
The previous fix for clipping problems was not enough, reverted
that change in xwin.c in favor for adding reset of window clipping
rect at reconnect.
Fix issue #117
The use of redirection cookie was never done due to global
g_redirect flag was cleared on the wrong place. This fixes
the problem with dual authentication prompts when redirect
to another server upon connect.
Fixes issue #18
This commit will add a logging system to solve the problem that
one actually need to recompile rdesktop from source to enable
different debug logging.
- Same logging api for all kind of logging and messages to
end user.
- Adding -v for verbose output when running rdesktop.
- All messages are logged into a subject and with a type, eg:
logger(Keyboard, Notice, "Autos-electing %s based on locale.", locale);
- Debug logging is enabled trough a environment variable RDEKSTOP_DEBUG,
which specifies subjects of interest, comma separated. There is a special
subject named All which includes all subject for debug loggin. There is also
a simple logic opeartor '!' = NOT which can be used in combination like:
RDESKTOP_DEBUG=All,!Graphics,!Sound
Which would give debug log output for All subject except Graphics and Sound.
redirection were the RDPDR channel is shutdown by server.
The RDPDR channel is shutdown by server when responses from
abdonend iorequests are received on a reinitialized RDPDR
channel. This fix adds epochs for RDPDR channel and tags
iorequest to specific epoch to handle abdonend iorequest.
git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/rdesktop/trunk@1836 423420c4-83ab-492f-b58f-81f9feb106b5
within rdp_connect() loop.
Fixes silent exits of rdesktop when receiving a redirection
PDU before license handling which is a corner case appeared
while using CredSSP+Kerberos.
git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/rdesktop/trunk@1825 423420c4-83ab-492f-b58f-81f9feb106b5
and implement the usage of the new command in rdesktop.
If a seamless command is specified the persistent mode
of the session will be changed to non-persistent.
git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/rdesktop/trunk@1822 423420c4-83ab-492f-b58f-81f9feb106b5
when specifying that nothing should be disabled in
performance flags.
This is a workaround for rdesktop not supporting
alpha cursors.
git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/rdesktop/trunk@1818 423420c4-83ab-492f-b58f-81f9feb106b5
Fixes bug #384
Thanks to Alexander Zakharov for pinpointing
the core issue.
git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/rdesktop/trunk@1816 423420c4-83ab-492f-b58f-81f9feb106b5
This fix a bug where redirection using CredSSP fails to SSO
due to wrong password sent to server and asks for a correct one.
The source to this issue was that the password was zeroed before
the actual redirection is handled.
git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/rdesktop/trunk@1795 423420c4-83ab-492f-b58f-81f9feb106b5