Commit Graph

1882 Commits

Author SHA1 Message Date
Norbert Federa
4c4019203a core/fastpath: removed flawed slow-path conversion
Commit 0357a38e31 modified the function
fastpath_send_update_pdu() to check if the desired update is possible
by checking the payload size against the computed maxLength and the
clients's advertised max request size.
If the check failed that commit added a workaround which simply
copied the payload to a slow path updade.
This workaround is totally flawed and causes protocol errors:
- the fast path update code is not checked and required data format
  conversions are missing
- depending on the fast path update code rdp_send_data_pdu() would
  have to be called with differend data pdu type values but the
  workaround always uses DATA_PDU_TYPE_UPDATE
- the workaround does not check if the total size would exceed
  the maximum possible size for a slow path update

The check if a fast path output is actually possible with the
passed parameters is basically a good idea.
However, if that check fails it would only indicate an error in
the server implementation who must not generate updates that
exceed the client's max request size.
Even though a slow-path conversion would be possible there is
much more involved than simply copying the payload stream.
In addition it is highly doubtful if there is a benefit at all.
Even the oldest rdesktop and windows ce clients do support fast
path and although some lack the multi-fragment update capability
we cannot really send larger updates using slow-path outputs.

For the reasons elucidated above, I have removed the workaround
but kept a modified version of the check if a fast-path output
is possible at all.
2015-02-03 13:51:35 +01:00
Bernhard Miklautz
d625edbe97 gfx/pointer: add support to set pointer
Extend rdp_pointer with function SetPosition. Can then be used by
clients support setting pointer by server which might be used in
shadowing scenarios.
2015-02-02 10:57:31 +01:00
Marc-André Moreau
7c6948cd5c xfreerdp: make use of freerdp_get_event_handles 2015-01-30 09:47:02 -05:00
Marc-André Moreau
3a906caa4a freerdp: add event handle usage instead of file descriptors 2015-01-29 22:57:58 -05:00
Marc-André Moreau
ef71181897 libfreerdp-core: fix Win32 gateway authentication 2015-01-29 14:07:02 -05:00
Marc-André Moreau
b387708069 libfreerdp-core: fix Win32 socket event handle 2015-01-29 11:35:52 -05:00
Marc-André Moreau
bb67968141 libfreerdp-core: cleanup transport debug output 2015-01-28 15:37:20 -05:00
Marc-André Moreau
977cd21919 libfreerdp-core: don't enable GatewayBypassLocal by default 2015-01-28 15:16:31 -05:00
Marc-André Moreau
a9df86ab16 libfreerdp-core: update gateway code for Windows 2015-01-28 14:54:03 -05:00
Marc-André Moreau
5bf8b1509e libfreerdp-core: improve socket BIO handling 2015-01-28 13:46:17 -05:00
Marc-André Moreau
32a991c165 libfreerdp-core: move socket event and nonblock options to socket BIO 2015-01-27 21:18:26 -05:00
Marc-André Moreau
27af9786e2 Merge pull request #2322 from akallabeth/channel_load_once
Preventing channels from being loaded twice
2015-01-22 16:05:41 -05:00
Armin Novak
7fc9f98d3c Updated h264_decompress arguments. 2015-01-22 13:24:15 +01:00
Armin Novak
d42261f5eb Added destination buffer width to h264_decompress.
Added proper region limit checks in h264_decompress.
2015-01-22 13:22:53 +01:00
Armin Novak
c43faeec0a Removed broken buffer size check.
To check the decoded h264 frame size against the output buffer is wrong.
The size of the output buffer must only hold the data defined by the
region rectangles.
2015-01-22 13:06:37 +01:00
Armin Novak
34b700dd0f Preventing channels from being loaded twice
Skipping channels already loaded in freerdp_channels_client_load
This prevents channels already loaded in a context to be added a
second time to the channel list.
2015-01-20 18:01:33 +01:00
Marc-André Moreau
4fe932f21f libfreerdp-core: cleanup redirection debug output 2015-01-20 10:46:32 -05:00
Armin Novak
cbadeb4dd3 Fixed variable initialisation and cleanup. 2015-01-20 12:31:11 +01:00
Armin Novak
b07cded5d2 Added CHANNEL_EVENT_DISCONNECTED handling.
Additional error checks and logging.
2015-01-20 11:58:45 +01:00
Armin Novak
a217e02924 Prettiefied WLog messages. 2015-01-20 11:10:16 +01:00
Armin Novak
a295a42664 Prettiefied WLog messages. 2015-01-20 11:10:03 +01:00
Armin Novak
595680d169 Prettiefied WLog messages. 2015-01-20 11:09:54 +01:00
Armin Novak
015bfeb897 Prettiefied WLog messages. 2015-01-20 11:08:41 +01:00
Armin Novak
4f42a7955f Prettiefied WLog messages. 2015-01-20 11:06:26 +01:00
Norbert Federa
344362a8a3 clients: fix "focus in event" issues
The input->FocusInEvent callback implementations (normal and fast-path) have
always sent the mouse position even if the pointer was outside of the freerdp
client area. In addition xfreerdp used the wrong pointer coordinates which
were relative to the root window instead of its own.
On focus-in the pointer position must only be sent if the pointer is
currently within the program's client area. However, the clients had no way
to pass that information to input->FocusInEvent which required an API change.

- removed mouse pointer x, y parameters from input interface's FocusInEvent
- clients are responsible to call input->MouseEvent on focus-in if necessary
- fixed xfreerdp and wfreerdp accordingly
2015-01-16 18:40:57 +01:00
Bernhard Miklautz
c70293aa60 Fix clang compiler warnings 2015-01-16 00:41:57 +01:00
Marc-André Moreau
fa538911ca libfreerdp-core: fix build on Windows 2015-01-15 15:04:35 -05:00
Marc-André Moreau
701186e461 libfreerdp-core: silence false error on server disconnect 2015-01-15 14:52:35 -05:00
Marc-André Moreau
d8ddfd83c3 libfreerdp-core: parse gateway idle timeout + final status code 2015-01-14 16:49:21 -05:00
Marc-André Moreau
94f828a873 libfreerdp-core: fix detection of TS Gateway transport disconnection 2015-01-14 15:39:35 -05:00
Marc-André Moreau
81e190eccb libfreerdp-crypto: fix tls_write_all ringbuffer usage 2015-01-14 13:25:54 -05:00
Marc-André Moreau
98cd697cad libfreerdp-utils: add ringbuffer debug output 2015-01-14 13:15:57 -05:00
Marc-André Moreau
580de466fc Merge branch 'master' of github.com:FreeRDP/FreeRDP 2015-01-14 11:24:13 -05:00
Marc-André Moreau
620694c10a Merge pull request #2301 from akallabeth/disconnect_fix
Disconnect / Reconnect fix
2015-01-14 08:56:54 -05:00
Armin Novak
b3eafca85b Fixed return type for nego_transport_connect and nego_transport_disconnect. 2015-01-14 11:35:19 +01:00
Marc-André Moreau
f79deaff7b libfreerdp-core: partial OUT channel recycling support 2015-01-13 16:35:34 -05:00
Marc-André Moreau
43fe94d939 libfreerdp-core: fix identification of OUT R1/A2 RTS PDU 2015-01-13 15:01:07 -05:00
Marc-André Moreau
fc38dcc775 libfreerdp-core: gateway cleanup 2015-01-13 13:50:46 -05:00
Martin Haimberger
bba342a6be added set_error_info function
if an error_info is set, a TS_SET_ERROR_INFO_PDU
will be sent to the client on disconnect with
the error_info
2015-01-13 08:09:36 -08:00
Armin Novak
b5281b7877 Fixed broken state reset, now gateway works again. 2015-01-13 16:35:06 +01:00
Armin Novak
5f2105b930 Added prototype for freerdp_client_disconnect. 2015-01-13 12:44:16 +01:00
Armin Novak
524e4635fd Fixed typos.
gdi_free now done on disconnect.
2015-01-13 12:00:51 +01:00
Armin Novak
600074373c Fixed rdp_reset. 2015-01-12 13:47:04 +01:00
Armin Novak
e3df1d3d5b Fixed freerdp_disconnect and freerdp_reconnect. 2015-01-12 13:44:34 +01:00
Armin Novak
e0139fc4d8 Added nego_disconnect. 2015-01-12 13:44:04 +01:00
Armin Novak
8a1f9c321c Added nego_disconnect function. 2015-01-12 13:43:29 +01:00
Armin Novak
9274de4921 Fixed rdp_client_disconnect and rdp_reset. 2015-01-12 13:36:38 +01:00
Armin Novak
5d3091bd1c Fixed transport cleanup on disconnect. 2015-01-12 13:32:59 +01:00
Norbert Federa
765b25933e license: fix for corrupted licensing packets
Since commit a228952 FreeRDP generates corrupt licensing packets if the rdp
security layer is used and the peer did not indicate that it is capable of
processing encrypted licensing packets:
That commit changed rdp->sec_flags after the rdp stream was already initialized
with encryption enabled which placed the PDU payload at an incorrect offset.

Instead of directly modifying the rdp->sec_flags this patch temporarily
disables rdp->do_crypt during rdp stream initialization if the client has not
advertised support for encrypted licensing packets.
2015-01-12 11:31:18 +01:00
Marc-André Moreau
51554ff16c channels: patch rdpdr/smartcard valgrind leaks, fix hang on disconnect 2014-12-28 14:56:13 -05:00