Commit Graph

53 Commits

Author SHA1 Message Date
Marc-André Moreau
b2d0aa128f libfreerdp-core: refactor client info pdu functions 2015-02-06 16:55:21 -05:00
Marc-André Moreau
9a8f877396 libfreerdp-core: fix auto reconnect cookie security verifier computation 2015-02-06 16:37:28 -05:00
Marc-André Moreau
70e2862c50 libfreerdp-core: improve client core info debug output 2015-02-06 15:44:29 -05:00
Marc-André Moreau
fa06c4d401 libfreerdp-core: improve reconnection 2015-02-06 14:21:26 -05:00
Armin Novak
4f42a7955f Prettiefied WLog messages. 2015-01-20 11:06:26 +01:00
Norbert Federa
939f1c639a Standard RDP Security Layer Levels/Method Overhaul
[MS-RDPBCGR] Section 5.3 describes the encryption level and method values for
standard RDP security.

Looking at the current usage of these values in the FreeRDP code gives me
reason to believe that there is a certain lack of understanding of how these
values should be handled.

The encryption level is only configured on the server side in the "Encryption
Level" setting found in the Remote Desktop Session Host Configuration RDP-Tcp
properties dialog and this value is never transferred from the client to the
server over the wire.
The possible options are "None", "Low", "Client Compatible", "High" and
"FIPS Compliant". The client receices this value in the Server Security Data
block (TS_UD_SC_SEC1), probably only for informational purposes and maybe to
give the client the possibility to verify if the server's decision for the
encryption method confirms to the server's encryption level.
The possible encryption methods are "NONE", "40BIT", "56BIT", "128BIT" and
"FIPS" and the RDP client advertises the ones it supports to the server in the
Client Security Data block (TS_UD_CS_SEC).
The server's configured encryption level value restricts the possible final
encryption method.
Something that I was not able to find in the documentation is the priority
level of the individual encryption methods based on which the server makes its
final method decision if there are several options.
My analysis with Windows Servers reveiled that the order is 128, 56, 40, FIPS.
The server only chooses FIPS if the level is "FIPS Comliant" or if it is the
only method advertised by the client.

Bottom line:
* FreeRDP's client side does not need to set settings->EncryptionLevel
(which was done quite frequently).
* FreeRDP's server side does not have to set the supported encryption methods
list in settings->EncryptionMethods

Changes in this commit:

Removed unnecessary/confusing changes of EncryptionLevel/Methods settings

Refactor settings->DisableEncryption
* This value actually means "Advanced RDP Encryption (NLA/TLS) is NOT used"
* The old name caused lots of confusion among developers
* Renamed it to "UseRdpSecurityLayer" (the compare logic stays untouched)

Any client's setting of settings->EncryptionMethods were annihilated
* All clients "want" to set all supported methods
* Some clients forgot 56bit because 56bit was not supported at the time the
code was written
* settings->EncryptionMethods was overwritten anyways in nego_connect()
* Removed all client side settings of settings->EncryptionMethods
The default is "None" (0)
* Changed nego_connect() to advertise all supported methods if
settings->EncryptionMethods is 0 (None)
* Added a commandline option /encryption-methods:comma separated list of the
values "40", "56", "128", "FIPS". E.g. /encryption-methods:56,128
* Print warning if server chooses non-advertised method

Verify received level and method in client's gcc_read_server_security_data
* Only accept valid/known encryption methods
* Verify encryption level/method combinations according to MS-RDPBCGR 5.3.2

Server implementations can now set settings->EncryptionLevel
* The default for settings->EncryptionLevel is 0 (None)
* nego_send_negotiation_response() changes it to ClientCompatible in that case
* default to ClientCompatible if the server implementation set an invalid level

Fix server's gcc_write_server_security_data
* Verify server encryption level value set by server implementations
* Choose rdp encryption method based on level and supported client methods
* Moved FIPS to the lowest priority (only used if other methods are possible)

Updated sample server
* Support RDP Security (RdpKeyFile was not set)
* Added commented sample code for setting the security level
2014-12-12 02:17:12 +01:00
Armin Novak
31c88013ca Decreased logging verbosity. 2014-09-15 19:52:19 +02:00
Armin Novak
2f519d7f16 Replaced logging in libfreerdp with wlog defines. 2014-09-15 08:48:46 +02:00
Marc-André Moreau
0457a29f57 shadow: fix WDS connectivity 2014-08-15 14:15:53 -04:00
Marc-André Moreau
7171a0b5c1 libfreerdp-core: fix reconnection using client random 2014-08-11 11:23:23 -04:00
Marc-André Moreau
cff9c16c1e Merge branch 'master' of github.com:FreeRDP/FreeRDP
Conflicts:
	channels/disp/client/disp_main.c
2014-08-11 10:36:07 -04:00
Armin Novak
f4c133eaf8 Replaced custom logging mechanism with WLog wrapper. 2014-08-07 16:51:24 +02:00
Marc-André Moreau
e303c3bd4c channels: cleanup RDP8 virtual channels 2014-07-28 16:47:42 -04:00
Marc-André Moreau
af1be38775 client/common: parse and use remote assistance file 2014-06-28 18:33:46 -04:00
Hardening
ac7507ab8d Adds some check to treat OOM problems + RDP security fix
Malloc can fail so it will, this patch adds some check in some places
where malloc/strdup results were not checked.

This patch also contains a server side fix for RDP security (credit to nfedera).
The signature len was badly set in the GCC packet. And some other RDP security
oriented fixes are also there.
2014-03-25 23:13:08 +01:00
Marc-André Moreau
4310089102 libfreerdp-core: add options for specifying compression level 2014-03-10 11:16:36 -04:00
Marc-André Moreau
cdcd290c44 wfreerdp: fix most build warnings 2014-02-10 22:12:13 -05:00
Marc-André Moreau
1fc2d780f7 libfreerdp-core: fix memory leaks reported by valgrind 2013-10-31 23:35:24 -04:00
Marc-André Moreau
d30f66b1b7 Merge branch 'master' of github.com:FreeRDP/FreeRDP 2013-10-23 14:18:40 -04:00
Daryl Poe
076b8a84c2 commandline session reconnect 2013-10-22 09:14:29 -06:00
Marc-André Moreau
7a7c967425 libfreerdp-rail: cleanup RAIL code 2013-10-09 22:38:26 -04:00
Marc-André Moreau
c4a8fe0064 libfreerdp-core: simplify management and consistency of PerformanceFlags 2013-09-17 14:56:23 -04:00
Marc-André Moreau
a0e09e6273 libfreerdp-core: fix server-side licensing sequence 2013-09-05 18:53:55 -04:00
Marc-André Moreau
2bd6808432 freerdp: merge with master 2013-06-05 10:31:01 -04:00
Vic Lee
06d06fdd2d core/info: server missing audio info flags. 2013-05-23 14:04:58 -07:00
Marc-André Moreau
202614a1a4 libfreerdp-core: reduce reuse of same pdu buffers 2013-05-15 15:54:33 -04:00
Marc-André Moreau
5b92413843 freerdp: purge deprecated stream utils 2013-05-08 16:09:16 -04:00
Marc-André Moreau
51715636a5 freerdp: remove some deprecated stream utils 2013-04-29 22:35:15 -04:00
Marc-André Moreau
066d3384c2 xfreerdp: fix RemoteApp with system message (don't show full desktop on every single connection, just when needed) 2013-03-28 22:26:28 -04:00
Hardening
7701c9d934 Replace printf(...) by fprintf(stderr, ...) 2013-03-28 23:06:34 +01:00
Marc-André Moreau
a8201b0d1b libwinpr-utils: combine old and new stream utils 2013-03-21 15:19:33 -04:00
rdp.effort
0abf945a18 check or propagate return values when writing 2013-01-14 23:40:34 +01:00
rdp.effort
f320fc3530 check stream sizes when reading ClientInfoPDU 2013-01-11 01:18:11 +01:00
rdp.effort
e53e8e524d Initialize lpWideCharStr parameter when using ConvertToUnicode
This patch ensure that lpWideCharStr is initialized by callers of
ConvertToUnicode
2013-01-10 21:30:32 +01:00
Marc-André Moreau
d19e2042c3 libfreerdp-utils: remove deprecrated unicode utils in favor of WinPR 2012-12-17 10:20:25 -05:00
Marc-André Moreau
af9be28000 libfreerdp-utils: purge deprecated freerdp_UnicodeToAsciiAlloc util in favor of WinPR ConvertFromUnicode 2012-12-16 23:34:07 -05:00
Marc-André Moreau
a25c72cb0e libfreerdp-core: rdpSettings refactoring (part 5) 2012-11-08 11:16:54 -05:00
Marc-André Moreau
410b7ab867 libfreerdp-core: rdpSettings refactoring (part 4) 2012-11-07 23:29:24 -05:00
Marc-André Moreau
8544716104 libfreerdp-core: rdpSettings refactoring (part 3) 2012-11-07 18:23:33 -05:00
Marc-André Moreau
6427c9dd90 libfreerdp-core: rdpSettings refactoring (part 2) 2012-11-07 15:13:14 -05:00
Marc-André Moreau
ebc09d17d8 libfreerdp-core: started refactoring rdpSettings 2012-11-07 10:33:06 -05:00
Marc-André Moreau
9d064171a7 freerdp: get rid of old types 2012-10-09 03:26:39 -04:00
Marc-André Moreau
1bf8a45519 freerdp: change uint8, sint8, uint16, sint16 to BYTE, INT8, UINT16, INT16 2012-10-09 03:01:37 -04:00
Marc-André Moreau
1ed644786c freerdp: change boolean type to BOOL type 2012-10-09 02:38:39 -04:00
Marc-André Moreau
5612bc43f8 freerdp: change true/false to TRUE/FALSE 2012-10-09 02:31:28 -04:00
Marc-André Moreau
9909a12af5 libfreerdp-utils: get rid of xmalloc, xrealloc and xfree 2012-10-08 23:21:26 -04:00
Marc-André Moreau
e60a092d81 freerdp: fix headers 2012-10-08 23:02:04 -04:00
Marc-André Moreau
6dcc8e73ee libfreerdp-utils: get rid of rdpBlob 2012-09-24 04:40:32 -04:00
Marc-André Moreau
58e1fd325a libfreerdp-utils: get rid of freerdp_uniconv_in 2012-09-23 20:11:50 -04:00
Marc-André Moreau
d0ac31b2c1 libfreerdp-utils: get rid of freerdp_uniconv_out 2012-09-23 19:49:13 -04:00