Commit Graph

3027 Commits

Author SHA1 Message Date
David Fort
0a404d5728 fix a warning seen on the MacOS CI 2022-05-30 14:05:41 +02:00
akallabeth
65938708c0 Fixed WITH_PKCS11 option 2022-05-12 11:36:01 +02:00
akallabeth
4c452a96c4 Fixed broken #define guards 2022-05-12 11:36:01 +02:00
David Fort
77413f49b2 winpr: rework alignment functions
_align_XXX functions aren't widely available depending on the C runtime. That causes
problems with mingw where we can easily have some runtime mixes (which lead to mysterious
segfaults most of the time). This patch introduce winpr_aligned_XXX functions that will
either use the function available, or use an emulation layer.
2022-05-12 11:36:01 +02:00
David Fort
82092f6752 smartcard: add verbose output during listing 2022-05-12 11:36:01 +02:00
akallabeth
ca9247ddd9 Do not compile ncrypt_pkcs11 if CMake option is not set 2022-05-06 13:39:26 +02:00
David Fort
4ffd3e84b9 smartcard: take in account pkcs11-module in smartcard listing and print pkcs11 errors 2022-05-06 13:39:26 +02:00
David Fort
a612ca4ba2 winpr: fix unitary test when CreateProcess is CreateProcessW
As the second argument of CreateProcessW is modified to split with spaces and so
this can not be a const arg.
2022-05-05 13:11:18 +02:00
Armin Novak
03ed367fb9 Fixed broken USE_UNWIND check 2022-05-05 13:05:33 +02:00
Armin Novak
400fe6f796 Fixed argument mismatch 2022-05-03 11:48:20 +02:00
akallabeth
6ce3499e13
Settings getter tests (#7869)
* Added tests for freerdp_[static|dynamic]_collection_* functions

* Added settings unit test for clone functions

* Fix argument for winpr_RAND and winpr_RAND_pseudo

Using void* eliminates all assumptions of which type the buffer is.
This eliminates unnecessary warnings.
2022-05-02 11:39:38 +02:00
akallabeth
a62fe8a3e9 Enable unwind.h and dladdr as default backtrace implementation
* config option USE_UNWIND to enable/disable
2022-04-29 15:15:53 +02:00
akallabeth
f10da4552b default android to unwind 2022-04-29 14:27:44 +02:00
akallabeth
9330559d24 Defined and use _write 2022-04-29 14:27:44 +02:00
akallabeth
00b00ea521 Added unwind.h support 2022-04-29 14:27:44 +02:00
akallabeth
f146709eec Moved corkscrew backtrace to own file 2022-04-29 14:27:44 +02:00
akallabeth
3e62a05134 Moved windows backtrace to own file 2022-04-29 14:27:44 +02:00
akallabeth
0491f91327 Moved execinfo backtrace to own file 2022-04-29 14:27:44 +02:00
akallabeth
f8ada8984d Simplified CMake variable names 2022-04-29 14:27:44 +02:00
akallabeth
860f44f762 CMake check_include and struct cleanup
Move to WinPR what should be there.
2022-04-29 14:27:44 +02:00
akallabeth
340f9dd775 Fixed conditional warnings 2022-04-28 12:37:19 +02:00
akallabeth
d63817640f Fixed ArrayList_SetItem, return success 2022-04-28 12:37:19 +02:00
akallabeth
6bc7f6ca88 Fixed cast-qual warnings 2022-04-28 12:37:19 +02:00
akallabeth
962c5c3ef0 Fixed dead store warnings 2022-04-28 12:37:19 +02:00
akallabeth
ec699f6c75 scanbuild fixes 2022-04-28 12:37:19 +02:00
akallabeth
1dcc5a180a Fixed warnings 2022-04-28 11:24:51 +02:00
akallabeth
cc3e28f2f1 Fixed -Wdocumentation errors 2022-04-28 11:24:51 +02:00
akallabeth
507722aca4 Fixed snprintf return value checks 2022-04-28 10:49:09 +02:00
akallabeth
2dfc1ddb12 Removed obsolete trio 2022-04-28 10:49:09 +02:00
akallabeth
667b471686 Fixed cast-quality warnings 2022-04-28 09:17:20 +02:00
Armin Novak
e1b4b4aee0 Replaced WINPR_HANDLE_DEF with a struct type 2022-04-28 08:42:09 +02:00
Armin Novak
2dc98adb62 Updated _wcschr and _wcsrchr to match MSDN spec 2022-04-27 19:42:04 +02:00
Armin Novak
5482607b15 Added Stream_PointerAs
This macro allows retrieving the stream pointer casted to correct
type.
2022-04-27 19:42:04 +02:00
Armin Novak
833a445e4e Refactor thread condition logic
* Add better return value checks
* Combine logic blocks in structs
* Add (easier to read) static functions for blocks
* Use condition variables only in combination with BOOL
2022-04-27 18:12:37 +02:00
Armin Novak
08035be41b Added missing WINPR_API 2022-04-25 16:06:34 +02:00
akallabeth
74c1a006e9 Fixed format string for Stream_CheckAndLogRequiredLength
__LINE__ requires %d and not %PRIuz
2022-04-23 10:10:09 +02:00
akallabeth
19de452f9c Cleaned up ntlm_fetch_ntlm_v2_hash 2022-04-22 15:30:23 +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
David Fort
f232562d8b smartcard: take in account the module path for listing smartcards
The PKCS1 module was taken only for the kerberos part.
Also make as exported the winpr_NCryptOpenStorageProviderEx function.
2022-04-15 09:06:09 +02:00
akallabeth
752ac3b479
Fix #7793: Do not expose internal input API (#7794)
* Fixed GetFileInformationByHandle initializers

* Fix #7793: Do not expose internal input API

Slow-Path input uses UINT16 for scancodes on wire, but only the
lower byte is actually used. (the extended fields are sent in
keyboardFlags field)
Hide this implementation detail and adjust the API to use UINT8
for the code instead just like the corresponding Fast-Path PDU

* Added a warning for problematic slow path keyCodes
2022-04-13 09:34:05 +02:00
Armin Novak
9d5e7b0d38 Fixed broken stream check 2022-04-06 08:58:32 +02:00
Armin Novak
037084abd5 Fix #7754 remove last newline in convert_filedescriptors_to_file_list 2022-03-28 16:21:27 +02:00
Armin Novak
22194a2ec6 Fixed missing field read. 2022-03-28 15:52:59 +02:00
Armin Novak
29b8298ff8 Fixed windows build (_snpnrintf) 2022-03-28 15:52:59 +02:00
Armin Novak
42ddb0898e Fixed NTLM flag handling
* NTLMSSP_NEGOTIATE_WORKSTATION_SUPPLIED and NTLMSSP_NEGOTIATE_DOMAIN_SUPPLIED
* Problem with clients not supporting NTLMSSP_NEGOTIATE_LM_KEY
* Improve logging
2022-03-28 15:52:59 +02:00
akallabeth
47bd162065 Added function sspi_SetAuthIdentityW 2022-03-28 15:52:59 +02:00
akallabeth
905609381f Unified sspi_FreeAuthIdentity 2022-03-28 15:52:59 +02:00
Armin Novak
453d3b4c8b Fixed #7754: nautilus does not like \r\n 2022-03-28 14:59:30 +02:00
akallabeth
c2e882c509
Nla server cleanup && server auth fix (#7743)
* Reduce negotiate logging verbosity

* Remove duplicate pointers from rdpNla

* Fixed server nla auth

* Encapsulated nla_server_recv_credentials
2022-03-25 10:47:05 +01:00
Zhengyi Fu
e62aaff319 winpr: add GetFileInformationByHandle 2022-03-24 13:40:31 +01:00