Armin Novak
e61880d077
[standard] replace __FUNCTION__ with __func__
2023-07-27 20:02:43 +02:00
akallabeth
3f78b3c379
[build] fix unused compiler warnings
2023-06-28 09:45:09 +02:00
Richard Markiewicz
946cfb1068
[core,license] Fix build on msvnc with WITH_DEBUG_LICENSE
2023-06-14 17:14:45 +02:00
Armin Novak
f357f1d418
[core,license] allow empty cert info
2023-04-24 13:03:40 +02:00
Armin Novak
8994d4a213
[core,license] fix length checks
...
check the correct stream.
2023-04-19 10:51:33 +02:00
Armin Novak
8c88a477fd
[core,licensing] fix warnings
2023-03-06 15:39:14 +01:00
Armin Novak
a7dac52a42
[license] updated copyright headers
2023-02-12 20:17:11 +01:00
akallabeth
b5d1ea7138
[core,license] use rdpCertificate
2023-02-12 20:17:11 +01:00
akallabeth
d96860780f
Fixed compiler warnings
2023-02-03 11:09:59 +01:00
akallabeth
00f2679eda
[core,security] refactor functions to check lengths
2023-02-03 11:09:59 +01:00
akallabeth
5f8cc02cf3
[core,license] update length
...
In license_read_encrypted_premaster_secret_blob the length argument was
not set, fix that
2023-02-03 11:09:59 +01:00
akallabeth
936e239acb
[core,license] replaced HWID_LENGTH with sizeof
2023-02-03 11:09:59 +01:00
akallabeth
4b0fcb3dac
[core,licensing] replaced WINPR_MD5_DIGEST_LENGTH with sizeof()
2023-02-03 11:09:59 +01:00
akallabeth
3c242bbe6a
[core,license] replaced MAC_SALT_KEY_LENGTH with sizeof
2023-02-03 11:09:59 +01:00
akallabeth
0f3d72e724
[core,license] replaced SESSION_KEY_BLOB_LENGTH with sizeof
2023-02-03 11:09:59 +01:00
akallabeth
a738f0ec91
[core,license] replaced PREMASTER_SECRET_LENGTH with sizeof
2023-02-03 11:09:59 +01:00
akallabeth
0c5afb923f
[core,license] replaced MASTER_SECRET_LENGTH with sizeof
2023-02-03 11:09:59 +01:00
akallabeth
cf539f33db
[core,license] replaced SERVER_RANDOM_LENGTH with sizeof
2023-02-03 11:09:59 +01:00
akallabeth
31695c94a1
[client random] refactor use
...
* use sizeof() instead of define length
* use settings getter/setter
2023-02-03 11:09:59 +01:00
akallabeth
a3152871ab
[core,crypto] refactor rsa functions
...
* public encrypt/decrypt take rdpCertInfo data as argument
* private encrypt/decrypt take rdpRsaKey as argument
* Add missing length arguments
2023-02-03 11:09:59 +01:00
akallabeth
2af9758173
[core,license] use rdpCertInfo
...
Use the struct rdpCertInfo for certificate related data instead of
declaring separate variables
2023-02-03 11:09:59 +01:00
akallabeth
818267bc80
[core] fixed missing BYTE to WCHAR casts
2023-02-01 09:51:54 +01:00
akallabeth
74530a7931
[format strings] ensure __LINE__ is of type size_t
...
__LINE__ is not particularily well defined (most fall back to int).
We want to ensure that all the uses in a format string match the format
specifier, so do an explicit cast
2023-01-25 14:27:32 +01:00
akallabeth
8ed37e68d2
[stream] use logging capacity checks
2023-01-25 14:27:32 +01:00
akallabeth
d65b73ae9f
[core,license] fixed string conversion
2023-01-25 09:37:40 +01:00
akallabeth
b69c00c448
[core,certificate] const correct write function
2023-01-24 10:16:55 +01:00
akallabeth
37ab25e19d
Fixed all Wdocumentation warnings
2022-12-12 14:24:55 +01:00
akallabeth
7ab917dca8
Fixed Wsign-compare warnings
2022-12-09 15:58:26 +01:00
akallabeth
aaae70ff05
Fixed missing const casts
2022-12-09 15:58:26 +01:00
akallabeth
5799fb2018
Replace ConvertFromUnicode and ConvertToUnicode
...
* Use new ConvertUtf8ToWChar, ConvertUtf8NToWChar,
ConvertUtf8ToWCharAlloc and ConvertUtf8NToWCharAlloc
* Use new ConvertWCharToUtf8, ConvertWCharNToUtf8,
ConvertWCharToUtf8Alloc and ConvertWCharNToUtf8Alloc
* Use new Stream UTF16 to/from UTF8 read/write functions
* Use new settings UTF16 to/from UTF8 read/write functions
2022-11-28 10:42:36 +01:00
akallabeth
bc31bae2b5
[core] Unify RDP state machine
...
Up to this commit the client and server state machine handling used
different return values for state machine changes.
This is fixed with this commit:
* Use common enum return values
* Use common helper functions
2022-11-15 09:57:46 +01:00
akallabeth
7d67adbc54
Refactored licensing module
...
* Make the whole module opaque for easier testing
2022-11-03 17:02:47 +01:00
akallabeth
1c0908bdfb
Use winpr_DeleteFile and winpr_MoveFileEx
2022-10-25 13:58:05 +02:00
akallabeth
43c5289928
Replaced memset/ZeroMemory with initializer
...
* Addes WINPR_ASSERT on many occations
* Replaced memset with array initializer
* Replaced ZeroMemory with array initializer
2022-10-14 12:11:01 +02:00
akallabeth
73cdcdfe09
Logging and parser fixes ( #7796 )
...
* Fixed remdesk settings pointer
* Fixed sign warnings in display_write_monitor_layout_pdu
* Use freerdp_abort_connect_context and freerdp_shall_disconnect_context
* Added and updates settings
* info assert/dynamic timezone
* mcs assert/log/flags
* Fixed and added assertions for wStream
* Unified stream length checks
* Added new function to check for lenght and log
* Replace all usages with this new function
* Cleaned up PER, added parser logging
* Cleaned up BER, added parser logging
* log messages
* Modified Stream_CheckAndLogRequiredLengthEx
* Allow custom format and options
* Add Stream_CheckAndLogRequiredLengthExVa for prepared va_list
* Improved Stream_CheckAndLogRequiredLength
* Now have log level adjustable
* Added function equivalents for existing logger
* Added a backtrace in case of a failure is detected
* Fixed public API input checks
2022-04-19 14:29:17 +02:00
akallabeth
d3ae821477
Improved logging, compiler warning fixes
...
* Improved logging in TPKT, TPDU, MCS, PER
* Proper use of rdpSettings functions
* Fixed missing return values
* Refactored rdp_server_transition_to_state
2022-03-28 15:52:32 +02:00
Armin Novak
4d03d7c0bf
Freerdp remove #ifdef HAVE_CONFIG_H
2022-03-03 11:26:48 +01:00
Armin Novak
b2ad47a809
Reorganized FreeRDP headers
2022-03-03 11:26:48 +01:00
akallabeth
3ccb96d52f
Fixed #7350 : Warnings with Stream_StaticInit
...
* Properly initialize the stream buffer
* Add Stream_StaticConstInit accepting a const buffer
* Modify API to return a pointer to the stream initialized
2021-10-14 12:11:16 +02:00
Armin Novak
5fb59a23a9
Fixed lots of compilation warnings and type mismatches
2021-06-16 15:21:56 +02:00
akallabeth
6b36c6d417
Replace fopen and path functions with wrappers ( #7043 )
...
Functions like fopen, PathFileExists, PathMakePath need to call
the wide character versions on windows for utf-8 support.
2021-05-31 11:42:03 +02:00
akallabeth
c10a030ec6
Fixed use fo crypto_rsa_public_encrypt in license module
2021-05-11 08:00:18 +02:00
akallabeth
e2fd9db0b5
Added const to function arguments
2021-02-17 11:29:56 +01:00
akallabeth
1feb034896
Fixed invalid argument type for license function
2021-02-07 19:58:56 +01:00
Armin Novak
54e02e1642
Use wide char file paths for license
2021-02-04 21:22:21 +01:00
Armin Novak
773cfcd6da
Fixed #6760 : Use wide char file operations on windows.
2021-02-04 21:22:21 +01:00
akallabeth
6ade7b4cbf
Fixed OOB Read in license_read_new_or_upgrade_license_packet
...
CVE-2020-11099 thanks to @antonio-morales for finding this.
2020-06-22 11:51:38 +02:00
Armin Novak
c7187928e9
Fix tpkt header length checks for encrypted packets
...
If securityFlag SEC_ENCRYPT is set, remove the encryption headers from
the TPKT header length on comparison.
2020-03-10 12:20:50 +01:00
Armin Novak
07605b0281
Consume all TPKT data reading new/upgrade license
2020-03-05 13:48:58 +01:00
Armin Novak
318cb3dd47
Added tpkt header length plausibility checks.
2020-03-02 11:40:35 +01:00