Commit Graph

62 Commits

Author SHA1 Message Date
Armin Novak c8908c8be6 Updated windows shadow server assistance usage. 2018-11-22 11:11:31 +01:00
Armin Novak c3a26b0d6a Removed +async-transport options
The async transport option is broken by design.
If used the main loop is called from the transport thread and the
main thread of the application.
Unless the transport layer is refactored to just work on queues
(input and output) this option will never work, therefore remove it.
2018-08-22 13:56:37 +02:00
Armin Novak 1c72127c6b Do not clear invalid region if no client connected. 2018-03-07 15:37:20 +01:00
Armin Novak 2ad5b3510d Fixed windows shadow server update copy. 2018-03-07 15:37:20 +01:00
Armin Novak 2517755d25 Fixed thread function return and parameters. 2018-03-07 14:36:55 +01:00
Armin Novak 990b8c23a9 Fixed PubSub function pointer casts. 2018-02-14 11:00:52 +01:00
Armin Novak 8b9e3fa51e Fixed use of reserved keywords for include guards. 2017-07-20 09:35:41 +02:00
Armin Novak f8d22c00d6 Fixed compiler warnings and uninitialized data. 2017-02-17 11:17:45 +01:00
Norbert Federa f71b6b46e8 fix string format specifiers
- fixed invalid, missing or additional arguments
- removed all type casts from arguments
- added missing (void*) typecasts for %p arguments
- use inttypes defines where appropriate
2016-12-16 13:48:43 +01:00
Armin Novak 8ef1808191 Adjusted non X11 implementations. 2016-10-14 12:50:04 +02:00
Armin Novak 649d270ccd Fixed GDI_RGN->null initialization. 2016-10-06 13:43:15 +02:00
Armin Novak 9ab04711fa Fixed shadow server color encoding. 2016-10-06 13:43:12 +02:00
Armin Novak 22ddec810b Moved pre and post channel hooks. 2016-10-06 13:43:10 +02:00
Armin Novak 0c551808a3 Fixed gdi_init for windows server. 2016-10-06 13:43:09 +02:00
Armin Novak d35823cf69 Moved channel init code to core library. 2016-10-06 13:43:09 +02:00
zihao.jiang 746a754244 rdpgfx: Implementation for server side channel
server/shadow: support h264 codec with gfx channel
2016-08-07 20:14:33 +08:00
Armin Novak 36cbf1b583 Fixed error handling for channel load failures. 2016-03-14 13:13:43 +01:00
Norbert Federa ef4b29e5b3 ConvertFromUnicode fixes and misc hardening
- Added missing ConvertFromUnicode checks
- If ConvertToUnicode allocates memory, guarantee the null termination
  similar to ConvertFromUnicode's implementation
- Fixed some TestUnicodeConversion.c CTest return values
- Added some CTests for ConvertFromUnicode and ConvertToUnicode
- Misc code and protocol hardening fixes in the surrounding code regions
  that have been touched
2016-03-03 16:56:19 +01:00
Armin Novak 1036f1e296 Fixed default visibility.
When nothing is declared, only export symbols defined
with WINPR_API or FREERDP_API defined.
Override this setting if BUILD_TESTING to allow tests
access to internal functions usually not exposed.
2016-02-26 19:44:14 +01:00
Armin Novak cbf2892ccc Implemented temporary certificate accept.
Certificates can now be accepted temporarily.
The callbacks for certificate validation have been
modified to extend the information presented to the user.
2016-02-05 02:04:57 +01:00
zihao.jiang 60ae27b00a server/shadow: Completely decouple subsystem implementations and shadow framework internal details.
It will be completely possible to implement subsystem with only include/freerdp/server/shadow.h and libfreerdp-shadow.

Details as following:
1. Exported surface structure as subsystem implementations deeply depend on it to send image update
2. Export capture APIs. They are actually indepent APIs to help compare and calculate image difference.
3. Introduce API to trigger client frame update. Conceal details in subsystem->updateEvent
4. Pass client to client callbacks. Subsystem implementation may need to know 'which client' send the interaction event as well as the authentication request.
Add this support in callback definition before anyone really use shadow framework APIs to implement a custom subsystem.
Also added callback for client capability exchange
5. Remove X11_ShadowSubsystem Mac_ShadowSubsystem Win_ShadowSubsystem from libfreerdp-shadow.
Discard FREERDP_API mark on ShadowSubsystemEntry functions and make them be compiled together with shadow.c in CMakeLists.txt.
This is required from PR #2751.
Now subsystem implementations and shadow.c could be regarded as an example for shadow framework.
2016-01-01 03:13:52 +08:00
Bernhard Miklautz bfdf025e88 Merge pull request #2751 from realjiangms/shadow_fix_compile_error_win
server/shadow: Fix compile error on win32.
2015-07-20 17:23:23 +02:00
Bernhard Miklautz 798df32fd9 Integrate pull request feedback
* unify fwrite usage - set nmemb to 1 and the size to the size to write.
2015-07-01 12:22:32 +02:00
zihao.jiang 7a59f09ecf server/shadow: Fix compile error on win32. 2015-07-01 01:36:23 +08:00
Bernhard Miklautz 1cee185e3c hardening: check fread and fwrite return values 2015-06-26 20:38:30 +02:00
David FORT 7c3f8f33ab Fixes for malloc / calloc + other fixes
This patch contains:

* checks for malloc return value + treat callers;
* modified malloc() + ZeroMemory() to calloc();
* misc fixes of micro errors seen during the code audit:
** some invalid checks in gcc.c, also there were some possible
integer overflow. This is interesting because at the end the data are parsed
and freed directly, so it's a vulnerability in some kind of dead code (at least
useless);
** fixed usage of GetComputerNameExA with just one call, when 2 were used
in misc places. According to MSDN GetComputerNameA() is supposed to return
an error when called with NULL;
** there were a bug in the command line parsing of shadow;
** in freerdp_dynamic_channel_collection_add() the size of array was multiplied
by 4 instead of 2 on resize
2015-06-22 19:21:47 +02:00
Marc-André Moreau 5526348079 Merge branch 'master' of github.com:FreeRDP/FreeRDP 2015-05-21 13:29:59 -04:00
Marc-André Moreau ebf863f2eb Merge pull request #2557 from realjiangms/shadow_fix_hang2395
shadow fix multi-client hang
2015-05-20 16:26:31 -04:00
Marc-André Moreau 29d14773c8 Merge branch 'master' of github.com:FreeRDP/FreeRDP
Conflicts:
	client/Windows/wf_client.c
	libfreerdp/common/assistance.c
2015-05-20 10:12:24 -04:00
zihao.jiang 85dd90d817 shadow fix multi-client hang
Merge from commit d4df3a952b
Conflicts:

	server/shadow/shadow_subsystem.c
2015-05-11 00:04:07 +08:00
Norbert Federa 71a4349928 fixed multiple missing gdi return value checks
mainly gdi_Create* functions
2015-05-08 21:39:23 +02:00
Marc-André Moreau 30dd40e10a wfreerdp: fix and improve remote assistance 2015-05-07 14:20:49 -04:00
Norbert Federa 25fc866a58 Fix unchecked CreateThread calls and misc fixes 2015-05-05 13:55:48 +02:00
Norbert Federa ef1fd12b15 Fix unchecked CreateEvent calls and misc fixes
1)
Added missing checks for CreateEvent which also required the
following related changes:

- changed freerdp_context_new API to BOOL
- changed freerdp_peer_context_new API to BOOL
- changed pRdpClientNew callback to BOOL
- changed pContextNew callback to BOOL
- changed psPeerAccepted callback to BOOL
- changed psPeerContextNew callback to BOOL

2)
Fixed lots of missing alloc and error checks in the
changed code's neighbourhood.

3)
Check freerdp_client_codecs_prepare result to avoid segfaults
caused by using non-initialized codecs.

4)
Fixed deadlocks in x11 caused by missing xf_unlock_x11() calls
in some error handlers

5)
Some fixes in thread pool:
- DEFAULT_POOL assignment did not match TP_POOL definition
- don't free the pool pointer if it points to the static DEFAULT_POOL
- added error handling and cleanup in InitializeThreadpool
2015-04-29 18:18:39 +02:00
Bernhard Miklautz 515502ffa5 change return types of callbacks to BOOL
* change all client/server callbacks to BOOL
* update all clients accordingly
* add multiple return value checks
* small fixes
2015-04-21 14:18:07 +02:00
Marc-André Moreau 7ef55ab9b7 shadow: improve subsystem structure 2014-09-18 15:43:11 -04:00
Marc-André Moreau a5f8bdf51c shadow: add EnumMonitor functions 2014-09-18 14:29:42 -04:00
Marc-André Moreau 527638c691 shadow: delay subsystem initialization for monitor enumeration 2014-09-18 13:06:49 -04:00
Marc-André Moreau 48d15998e7 shadow: add common subsystem code 2014-09-17 22:58:57 -04:00
Marc-André Moreau 6afd621d4c Merge branch 'master' of github.com:awakecoding/FreeRDP into shadow
Conflicts:
	server/Mac/mf_audin.c
	server/Mac/mf_event.c
	server/Mac/mf_info.c
	server/Mac/mf_mountain_lion.c
	server/Mac/mf_peer.c
	server/Mac/mf_rdpsnd.c
	server/Mac/mfreerdp.c
	server/shadow/CMakeLists.txt
2014-09-17 20:15:01 -04:00
Armin Novak 17991386b3 Fixed log level of error message. 2014-09-16 10:17:54 +02:00
Armin Novak 72f06bdcdf Decreased logging verbosity. 2014-09-15 19:56:21 +02:00
Armin Novak 5b5791c8d7 Using wlog for server now. 2014-09-15 08:55:00 +02:00
Marc-André Moreau ca90650336 shadow: fix race conditions 2014-08-15 18:12:53 -04:00
Marc-André Moreau 536697d63b shadow: fix build for Windows XP 2014-08-15 16:06:08 -04:00
Marc-André Moreau 09ae1ac9ca shadow: initial working support for WDS+RDP backend 2014-08-15 14:57:09 -04:00
Marc-André Moreau 0457a29f57 shadow: fix WDS connectivity 2014-08-15 14:15:53 -04:00
Marc-André Moreau 9adaadb93a shadow: add more virtual channels to RDP backend like WDS API 2014-08-14 19:23:48 -04:00
Marc-André Moreau 158f9856ba shadow: start RDP client backend for WDS 2014-08-14 18:41:22 -04:00
Marc-André Moreau 97cd85803d shadow: initial WDS working setup 2014-08-14 13:10:43 -04:00