Commit Graph

4200 Commits

Author SHA1 Message Date
Armin Novak
fe987091f4 [client,x11] add signal cleanup handler for pipe 2023-07-03 13:21:43 +02:00
akallabeth
3dbd9c7eeb [client,x11] fix unicode input
key up and down events were reverted
2023-07-03 13:21:43 +02:00
akallabeth
2d85aa43fa [client,x11] add thread reading from named pipe
the named pipe input is converted to unicode and sent as keyboard input
2023-07-03 13:21:43 +02:00
akallabeth
a01f3ec5ab [client,common] allow adding a named keyboard pipe
This allows starting FreeRDP clients with a named pipe that will type in
text written to the named pipe as keyboard input
2023-07-03 13:21:43 +02:00
Armin Novak
8822ad53c1 [client,x11] fix memory leak 2023-07-03 10:19:34 +02:00
akallabeth
9565ff4b29 [client,x11] restrict pointer move to active window 2023-07-03 10:00:29 +02:00
akallabeth
32b60ae438 [pointer] unify mouse pointer settings 2023-07-03 10:00:29 +02:00
akallabeth
7397fa4ae5 [client,common] fix uninitialized variable 2023-06-29 14:30:09 +02:00
akallabeth
2810a3702c [client,common] fix missing return 2023-06-28 09:45:09 +02:00
akallabeth
3f78b3c379 [build] fix unused compiler warnings 2023-06-28 09:45:09 +02:00
Michael Saxl
d55e035260 [gateway,arm] Azure Virtual Desktop Gateway support
This PR creates a new /gateway:type:arm transport.
It depends on CJSON

The arm transport is not a transport by itself but is responsible
for getting the websocket endpoint from a configuration url derived from
the configured gateway host in the rdpw file or cmdline
2023-06-27 21:15:08 +02:00
Armin Novak
93423eaf11 [client,common] move pen detection to client common 2023-06-26 11:22:32 +02:00
Hodol Han
c278170a2a [client,x11] Reinit xinput input event masks on device changes
Reinitialize xinput input event masks to get events from newly plugged
devices after setup. We utilize XI_DeviceChanged and XI_HierarchyChanged
event types to handle device changes.
2023-06-23 08:36:09 +02:00
Armin Novak
732bd37307 [client,android] enable unicode input 2023-06-23 08:18:16 +02:00
Armin Novak
db661798f1 [client,common] fix multitouch detection 2023-06-22 11:46:56 +02:00
Michael Saxl
44c1ec3276 [gateway,websocket] implement plain websocket transport
* factor out most websocket specific code parts into websocket.c
* create wst.c (Websocket Transport) as gateway transport implementation
* introduce GatewayUrl setting that holds the websocket url
* introduce GatewayHttpExtAuthBearer that holds the HTTP Bearer
* GatewayHttpExtAuthBearer can be used by both rdg and wst
2023-06-22 09:21:42 +02:00
Michael Saxl
9a5bedd8be cli parameter /gateway:bearer:bearertoken 2023-06-22 09:21:42 +02:00
digitalsignalperson
edee918dac remove unused variable, remove comment, add missing return statement 2023-06-21 22:59:53 +02:00
digitalsignalperson
84e1148bf1 Forcing PenHoverCancel allowed the eraser hover icon to apprear consistently after using the eraser, but fast writing with the pen would miss some line segments. Reverting to where it all works, but the hover icon doesn't display eraser correctly most of the time after erasing something 2023-06-21 18:42:38 +02:00
digitalsignalperson
9c7a541d9c Implement pen functionality for X11, including pressure, hover, and eraser 2023-06-21 18:42:38 +02:00
akallabeth
1fc0d5b4b1 [winpr] remove casts for winpr_RAND calls 2023-06-21 09:57:52 +02:00
Armin Novak
04fa5b3033 [client,mac] update to use AuthenticateEx 2023-06-19 10:08:59 +02:00
fifthdegree
5dd1363b8e Fix format issue in building url for sdl webview 2023-06-19 08:42:33 +02:00
Dan Holliday
f2ae9c00be Added the ability to quite the RDP session by pressing "r-ctrl + shift + D". The reason for this is when in full screen I have no way to exit from xrdp if I don't want to close my session. 2023-06-14 08:49:21 +02:00
Dan Holliday
72b614262f Fixed some incorrect key mappings with. I found that the "+/=" key on a UK keyboard didn't do anything. I also found that the "+" key on the keypad acted as if it was the "+/=" key. I've corrected some of the keycodes and confirmed that they keyboard functions as expected. 2023-06-14 08:49:21 +02:00
Armin Novak
b05eacb99e [build] fixed compilation warnings 2023-06-08 08:13:16 +02:00
Armin Novak
970f0c54e8 [stream] use const correct Stream_Pointer access 2023-06-08 08:09:33 +02:00
Armin Novak
a4c6b36a19 [build] fix memory sanitizer stack frame warnings 2023-06-07 09:14:45 +02:00
Armin Novak
8ec0b1262e [client,common] add /args-from:env
allow reading command line from a environment variable
2023-06-06 10:39:48 +02:00
Armin Novak
a0fd9cf957 [client,sdl] encapsulate c++ context
to properly initialize c++ us a heap allocated wrapper class
2023-06-05 14:15:03 +02:00
Armin Novak
da7c3b688f [client,sdl] use unique_ptr for SDL_Surface et al 2023-05-31 11:29:21 +02:00
Armin Novak
68995ddffb [client,sdl] wrap WinPR event in class 2023-05-31 11:29:21 +02:00
Armin Novak
ccbcc4cb65 [client,sdl] wrap critical section in class 2023-05-31 11:29:21 +02:00
Armin Novak
63ed6dc771 [client,sdl] use std::thread 2023-05-31 11:29:21 +02:00
Armin Novak
16cbe8882d [client,sdl] unique_ptr for input 2023-05-31 11:29:21 +02:00
Armin Novak
1a74d832de [client,sdl] unique_ptr for display channel 2023-05-31 11:29:21 +02:00
Armin Novak
324e8c7813 [client,sdl] use SDL_WaitEvent 2023-05-31 11:29:21 +02:00
Armin Novak
3e44efc841 [cmake] use FindX11 from CMake 3.13 2023-05-31 11:05:56 +02:00
akallabeth
28b0821ec6 [cmake] build xfreerdp standalone project 2023-05-31 11:05:56 +02:00
Armin Novak
481ba1581c [client,sdl] fixed warning in webview 2023-05-30 15:42:39 +02:00
Armin Novak
4545783dff [client,x11] always only send available clipboard 2023-05-30 13:42:28 +02:00
akallabeth
f941a1ec8e [cmake] unify RPATH settings and client deps detection 2023-05-26 11:38:32 +02:00
akallabeth
dc5ec9c196 [cmake] sfreerdp-client standalone build 2023-05-26 11:38:32 +02:00
akallabeth
7288680bdd [client,common] add clipboard feature mask
allow selectivly enabling or disabling clipboard direction and file
support
2023-05-25 16:26:39 +02:00
akallabeth
b8f7b59fff [warnings] fix casts and return 2023-05-24 08:24:32 +02:00
akallabeth
9f2d22c975 [client,sdl] refactor webview 2023-05-24 08:24:32 +02:00
akallabeth
9b112be058 [warnings] fix -Wold-style-cast 2023-05-24 08:24:32 +02:00
akallabeth
4ee6cfe13a [warnings] fix -Wmissing-prototypes 2023-05-24 08:24:32 +02:00
akallabeth
b598386928 [warnings] fix -Wnewline-eof 2023-05-24 08:24:32 +02:00
akallabeth
3ff34c03a0 [warnings] fix -Wwritable-strings 2023-05-24 08:24:32 +02:00
akallabeth
df76b59da7 [warnings] fix -Wshadow 2023-05-24 08:24:32 +02:00
akallabeth
9f1b13cf0a [warnings] fix -Wsuggest-override 2023-05-24 08:24:32 +02:00
akallabeth
18cde293e8 [warnings] fix -Wmissing-field-initializers 2023-05-24 08:24:32 +02:00
akallabeth
c355b2656b [warnings] fix -Wextra-semi 2023-05-24 08:24:32 +02:00
akallabeth
8e51463a7e [warnings] fix -Wzero-as-null-pointer-constant 2023-05-24 08:24:32 +02:00
akallabeth
d4fc9d5327 [client,common] auto reconnect abort early on cancel 2023-05-23 08:51:41 +02:00
akallabeth
2ec4601669 [cmake,sdl] use option instead of set 2023-05-23 08:51:18 +02:00
Armin Novak
a8476b8688 [cmake] fix qt5 find_package and linking 2023-05-23 06:04:55 +02:00
fifthdegree
449b96adb2 Use popup browser for AAD auth in SDL client
Optionally build the SDL client with Qt WebEngine to create a popup
browser for authentication to AAD. Also change the URL output on the
command line to use the "nativeclient" redirect for easier copy/pasting
of the authorization code.
2023-05-23 06:04:55 +02:00
akallabeth
9b67ef1a87 [client,common] add command line argument /args-from
This new argument allows reading all command line options from a file or
from stdin. It is a standalone argument and can not be combined with any
other.
2023-05-22 16:17:33 +02:00
akallabeth
a78182c425 [client,sdl] unify primary surface cleanup 2023-05-12 14:41:28 +02:00
akallabeth
1b28ed7c9c [client,sdl] fix blend mode
override blend mode on initial fill
2023-05-12 14:41:28 +02:00
akallabeth
4a006322af [winpr,clipboard] fix url unescape for file uri 2023-05-12 13:57:56 +02:00
akallabeth
52786d0f12 [input] update to use new WINPR_KEYBOARD_TYPE*
* Use new enum constants with WINPR_KEYBOARD_* prefix
* Fix mapping of keycodes and scancodes, the offset of 8 is no longer
  required if the proper keyboard type is used.
2023-05-12 09:52:01 +02:00
Armin Novak
4be82bf085 [client,common] print smartcard list info
if a reader is detected, print out the number of (valid) certificates
detected. This avoids #8953 empty output if there are no valid
certificates installed on a smartcard.
2023-05-12 08:06:45 +02:00
akallabeth
2b3c8c47a4 [build] fix install with BUILD_SHARED_LIBS=OFF
generate proper CMake targets so static linking works again.
2023-05-12 08:03:56 +02:00
akallabeth
c950ca375c [client,common] fix value present flag check
need to check for COMMAND_LINE_VALUE_PRESENT instad of COMMAND_LINE_ARGUMENT_PRESENT
2023-04-28 07:39:35 +02:00
akallabeth
516668d02b [fclose] ensure no invalid pointers are passed.
fclose has undefined behaviour for NULL pointers, so check for these.
2023-04-28 07:39:35 +02:00
Armin Novak
e0aec72d71 [pkg-config] unify exec_prefix 2023-04-24 22:01:15 +02:00
Bernhard Miklautz
d1069b3bc1 new: use prefix in pkg-config files for libdir 2023-04-24 11:19:01 +02:00
akallabeth
dd57de8e19 [client,sdl] add function to context 2023-04-19 11:04:13 +02:00
akallabeth
0627baa939 [client,sdl] move functions to proper place 2023-04-19 11:04:13 +02:00
akallabeth
01293f4c3f [client,sdl] migrate sdl_kbd to class 2023-04-19 11:04:13 +02:00
akallabeth
63606b3c7c [client,sdl] migrate display channel to class 2023-04-19 11:04:13 +02:00
akallabeth
05a2291861 [client,sdl] split sdl_freerdp.hpp 2023-04-19 11:04:13 +02:00
Armin Novak
26ee0590d6 [client,sdl] use CriticalSectionLock
use c++ RAII to lock critical sections
2023-04-19 11:04:13 +02:00
Armin Novak
86470103c4 [client,sdl] rename c++ headers to hpp 2023-04-19 11:04:13 +02:00
akallabeth
c35b41c05d [client,sdl] rename update trigger helper class 2023-04-19 11:04:13 +02:00
Armin Novak
f5453aa952 [client,sdl] standalone build
* move to c++
* build out of tree
2023-04-19 11:04:13 +02:00
Pascal Nowack
7fce527cff client/X11: Fix IO errors during server to client file transfer
When receiving a file list, xfreerdp3 rebuilds the content of the FUSE
filesystem.
Since fetching uri-lists can happen during a paste action too, xfreerdp3
caches the content of the last fetched mime type.
However, uri-lists exists in different variations, e.g. nautilus uses a
different mime type, than gnome-terminal does.
Furthermore, FormatLists can also contain other formats in addition to
file lists.
Fetching those contents during a paste operation leads to IO errors in
the paste operation.

In order to fix those errors, cache every mimetype in two hash tables:
One for the raw (unconverted) data, and one for the converted data.
When a content request is received, xfreerdp3 can with the already
cached converted data, directly serve the data.
If the content is not available as cached data, but its source data was
already fetched, use that source data to create the converted data.
Then serve the converted data.
Only if no cached converted data or cached raw data is available, issue
a new FormatDataRequest.
2023-04-17 08:33:53 +02:00
Armin Novak
3c3c996974 [client,common] do not insist on 32bpp for rfx/gfx 2023-04-13 14:35:51 +02:00
Armin Novak
7a283a140a [client,sdl] improve mouse scroll speed 2023-04-13 13:20:38 +02:00
Armin Novak
91056dc96c [client,common] fix file clipboard locking 2023-04-11 11:34:19 +02:00
weoses
eb10a060a5 [android] Add UI setting - "Use back button as Alt-f4" 2023-04-05 15:11:29 +02:00
Armin Novak
9f1bcc07b6 [client,windows] use CredUI flag CREDUI_FLAGS_USERNAME_TARGET_CREDENTIALS 2023-04-05 11:42:06 +02:00
Armin Novak
1e63d8c493 [utils,passphrase] use CredUI on windows 2023-04-05 11:42:06 +02:00
Armin Novak
659baa905c [utils] fix windows console read
On windows freerdp_interruptible_getc did not work at all. Fix this so
that reading characters works. This still does not hide input for
passwords or is actually interruptible, but at least it reads the data
correctly.
2023-04-05 11:42:06 +02:00
akallabeth
767818e97e [client,cmdline] fix gateway option parser
Options like /gateway:type:http,no-websockets,port:1234 were not
properly parsed. The `type:http,no-websockets` must be considered as
separate options with weak dependency.
Thanks to @akarl10 for pointing out this problem.
2023-04-04 09:06:05 +02:00
Pascal Nowack
d9fe2df6b5 client/X11: Only serve cached data when format matches
Format lists can contain multiple clipboard formats. When the data for
one is requested, xfreerdp caches it.
When the data for a different format in the same format lists is
requested, xfreerdp cannot use the already cached data, since that data
refers to a different format.
As a result, xfreerdp needs to ask for the data of the now requested
format.

However, this is currently not the case. xfreerdp will just provide the
data of the first request after receiving the last format list.
In order to fix this situation, also save the format id of the last
requested format.
If the format id of the cached data matches the one of the current
request, serve the data from the cached data.
Otherwise, issue a new FormatDataRequest.
2023-04-04 09:05:39 +02:00
Pascal Nowack
1f79eaa831 client/X11: Reintroduce handling for relieving filename restriction
Commit 6492a00959 introduced a way to
relieve the filename restriction, which ensured that file lists
containing files with names, that have characters, which are not allowed
on MS Windows.
This relief handling kicked in, when xfreerdp did not connect to MS
Windows RDS.
Commit d521c7fa74 got rid of any
wClipboardDelegate occurrence in xf_cliprdr.c, which also got rid of the
filename restriction relieve handling.
However, the relief handling was not added back, so do it now.
2023-04-04 09:05:39 +02:00
Pascal Nowack
126fb7b2fc client/cliprdr_file: Fix small typo 2023-04-04 09:05:39 +02:00
akallabeth
a9b4d812b3 [client,common] improve help for /list 2023-03-27 10:28:13 +02:00
luoyuan
37b0defd86 [client,windows]fix: keyboard focus error when minimize window by click taskbar icon
Signed-off-by: luoyuan <luoyuan@innosilicon.com.cn>
2023-03-24 08:50:49 +01:00
Armin Novak
19297707e0 [android] fixed build and runtime issues
* fixed a return value bug in event handling
* fixed some android manifest issues with newer API
* fixed version parser in java to properly load libraries
2023-03-23 09:58:37 +01:00
akallabeth
9515babd69 [client,windows] unify ctrl & alt down check 2023-03-23 08:46:49 +01:00
bugiii
8967ed1cff Add CTRL+ALT+Break, remove WM_SYSKEYDOWN 2023-03-23 08:46:49 +01:00
bugiii
bad802b6cd Update wf_event.c
Modified to recognize CTRL+ALT+ENTER using the already implemented keystates array.
2023-03-23 08:46:49 +01:00
Armin Novak
3f5b44ba36 [clients] fix wClipboard locking 2023-03-22 16:28:01 +01:00
akallabeth
a5b42f0f84 [includes] untangled circular includes 2023-03-15 08:22:23 +01:00
akallabeth
a360f1ca8c [build] fix a few compiler warnings 2023-03-13 13:04:45 +01:00
Armin Novak
39b3847428 [client,windows] fix pointer type 2023-03-13 09:36:07 +01:00
Armin Novak
36a5c39b6b [build] fix a few warnings 2023-03-13 08:46:51 +01:00
Armin Novak
9f1fc5adaf [client,common] add /sec:aad to command line help 2023-03-10 16:38:07 +01:00
Armin Novak
233ac929ea [client,common] use interruptible getline 2023-03-10 16:38:07 +01:00
akallabeth
f5423caace [auth,aad] add freerdp* argument to callback 2023-03-10 16:38:07 +01:00
fifthdegree
4cbfa006f2 Implement support for RDS AAD
Have a working implementation of the RDS AAD enhanced security mechanism
for Azure AD logons
2023-03-10 16:38:07 +01:00
Armin Novak
c23dc3ba9d [CMake] Fix use of BUILD_SHARED_LIBS
the option is named BUILD_SHARED_LIBS and not CMAKE_BUILD_SHARED_LIBS
2023-03-10 11:40:08 +01:00
Armin Novak
6e5307c037 [client,common] fix on off option parsing
* Return an enum to allow evaluation of what option was provided
* fix /sec:nla and /sec:nla:on behaviour.
2023-03-10 11:40:08 +01:00
akallabeth
151baa9ae5 [client,sdl] fix va_arg casts to match void* size 2023-03-09 11:17:37 +01:00
akallabeth
22f5bd48c4 [client,wayland] fix function arguments to match
the function pointer expected different arguments from the one provided.
2023-03-09 11:17:37 +01:00
akallabeth
387dcd4001 [client,sdl] fix missing type cast 2023-03-09 11:17:37 +01:00
akallabeth
6646ff9eb0 [client,common] fix wrong arguments for file clipboard 2023-03-09 11:17:37 +01:00
Martin Fleisz
093bf79837 common:: Fix const issues with current rdp file API 2023-03-08 14:08:34 +01:00
Martin Fleisz
ee06d70bfe common: Fix handling of networkautodetect rdp file setting
According to
https://learn.microsoft.com/en-us/windows-server/remote/remote-desktop-services/clients/rdp-files#session-behavior
both, `bandwidthautodetect` and `networkautodetect` are now enabled with
a value of 1 and disabled with a value of 0.

Earlier rdp files interpreted the `networkautodetect` setting inverted.
2023-03-07 15:42:40 +01:00
Martin Fleisz
b3ae857805 common: Minor code cleanup of rdp file handling
This PR contains various changes to rdp file handling:

The old code had a strange mixture of handling settings. When loading a
file every line of the file was cached in `rdpFile::lines`. Sometimes
functions would operate on these cached lines, sometimes they would
operate on the actual values in the `rdpFile` instance.

On the other hand if an `rdpFile` instance was created from
`rdpSettings`, this line cache simply did not exist, causing functions
to behave differently, depending on whether the instance was created by
reading a file or by populating it from `rdpSettings`.

The new implementation has now a single way of accessing values (
`find_integer_entry`/`find_string_entry`) and the `rdpFile::lines` data
is used to handle unknown settings.

The PR also adds some argument checking and assertions.
2023-03-07 15:42:40 +01:00
Armin Novak
f01aaab35a [client,x11] fix variable shadow 2023-03-07 07:51:52 +01:00
Armin Novak
c016562478 [client,x11] enable XSync with debug builds 2023-03-07 07:51:52 +01:00
Armin Novak
8fdd261d25 [client,x11] install X11 error handler
always install a custom X11 error handler to log the issue and location
in code.
2023-03-07 07:51:52 +01:00
Armin Novak
0b048e247e [client,x11] add Safe_XGetAtomName 2023-03-07 07:51:52 +01:00
Armin Novak
05134dc3a0 [client,x11] log location for wrapped X11 calls 2023-03-07 07:51:52 +01:00
Armin Novak
26d1fff864 [client,x11] wrap XGetWindowProperty
use a logging version of the function to diagnose issues
2023-03-07 07:51:52 +01:00
Armin Novak
87a91eb0c6 [client,x11] wrap XDeleteProperty
wrap function calls to logging version for debugging.
2023-03-07 07:51:52 +01:00
Armin Novak
684558d6d7 [client,x11] wrap XChangeProperty
to debug bug reports occuring only with certain setups wrap the function
call with a logging edition so we have the arguments available in the
log for debugging.
2023-03-07 07:51:52 +01:00
Armin Novak
af23e8f9a0 [client,sdl] lock updates
use a critical section to lock SDL related data updates
2023-03-07 07:51:36 +01:00
Armin Novak
fc964e857e [client,common] fix function name clash
log is an intrinsic function on windows, rename to writelog
2023-03-06 14:02:30 +01:00
Martin Fleisz
912b30ba06 common: Fix parsing of rdp file domain info
`freerdp_parse_username` always returns non-NULL domain information when
called. This currently results in `settings->domain` being overridden in
every case, even though we might have read domain information from the
file before.

This PR fixes this issue by checking if domain information was present
in the file and if not use the parsed domain informatin.
2023-03-06 11:41:22 +01:00
Armin Novak
77943d4329 [warnings] Fixed missing-prototypes warnings 2023-03-06 10:04:59 +01:00
Armin Novak
2eeb5d718a [warnings] Fixed shadow warnings 2023-03-06 10:04:59 +01:00
Armin Novak
4450af84d1 [warnings] Fixed sizeof-pointer-memaccess warnings 2023-03-06 10:04:59 +01:00
Armin Novak
3d8cb485f4 [warnings] Fixed strict-prototypes warnings 2023-03-06 10:04:59 +01:00
Armin Novak
24b3d0c9f3 [warnings] Fixed unused-label warnings 2023-03-06 10:04:59 +01:00
Armin Novak
2da605ef18 [client,common] fix missing return 2023-03-05 17:55:28 +01:00
Armin Novak
d7c55d76df [client,x11] fixed missing NULL check in clipboard 2023-03-05 17:55:28 +01:00
Armin Novak
cc65f5db31 [client,x11] fixed clipboard data cache 2023-03-05 17:55:28 +01:00
Armin Novak
f7682a5e79 [client,common] fix fuse inode creation, add logging 2023-03-05 17:55:28 +01:00
Armin Novak
a5fb3ad40a [client,common] fixed fuse linking 2023-03-05 17:55:28 +01:00
Armin Novak
7722961fcc [client,common] simplify file clipboard API 2023-03-05 17:55:28 +01:00
Armin Novak
e3099fbbd0 [client,common] fixed compile without fuse 2023-03-05 17:55:28 +01:00
Armin Novak
46f1d141c1 [client,common] fixed winpr clipboard locking 2023-03-05 17:55:28 +01:00
Armin Novak
6d2e7b91c7 [client,common] cliprdr file copy client to server
* better logging of failures
* do not keep FILE* open to avoid running out of file handles
2023-03-05 17:55:28 +01:00
Armin Novak
bfea14a5b1 [cliprdr] deactivate local file paste if not supported
if the file clipboard was compiled without FUSE do not announce the
availability.
2023-03-05 17:55:28 +01:00
Armin Novak
0fb242da7b [client,x11] properly initialize file clipboard 2023-03-05 17:55:28 +01:00
Armin Novak
b526078c3c [client,wayland] add file clipboard 2023-03-05 17:55:28 +01:00
Armin Novak
a3f6e3603c [client,common] fuse clipboard server to client 2023-03-05 17:55:28 +01:00
Armin Novak
39c06a4683 [client,common] fix file copy client to server 2023-03-05 17:55:28 +01:00
Armin Novak
8e7619502b [client,common] refactored fuse clipboard
* use proper permissions (no read/write for group and others)
* handle streamID for multiple simultaneous copy/paste operations
* properly handle requests with a queue
2023-03-05 17:55:28 +01:00
Armin Novak
a230c6b1dc [client,cliprdr] use hash table for remote streams 2023-03-05 17:55:28 +01:00
Armin Novak
ba128f4661 [client] move file clipboard to client common 2023-03-05 17:55:28 +01:00
Armin Novak
d521c7fa74 remove wClipboardDelegate 2023-03-05 17:55:28 +01:00
Armin Novak
5829079756 [client,windows] remove calls to now private functions 2023-03-05 17:03:18 +01:00
Armin Novak
0445eec0bc [client,common] fix /gateway option parsing
due to a bug the first letter of the gateway options was ignored.
2023-03-02 19:04:48 +01:00
Armin Novak
ffc4d419db [client,sdl] fix uninitialized variable cleanup 2023-03-01 13:45:13 +01:00
Armin Novak
8af35bd42a [client] add deprecation/experimental warnings 2023-03-01 13:45:13 +01:00
Armin Novak
73158a040a [client,common] add warning functions
Added helper functions to inform a user about current state of a client
in use:
* freerdp_client_warn_exeprimental warns about unstable clients
* freerdp_client_warn_deprecated warns about clients to be dropped
2023-03-01 13:45:13 +01:00
akallabeth
273bb6a7a8 [build] use static libraries as intermediate 2023-03-01 08:18:34 +01:00
akallabeth
b4e9c8b39f [build] removed complex libraries
* remove obsolete complex libraries helper
* fix static linking
2023-03-01 08:18:34 +01:00
Armin Novak
b2fa6da8d2 [client,x11] fix fuse2 compatibility 2023-02-28 09:47:54 +01:00
Armin Novak
e673405711 [client,x11] split file clipboard to own struct
* split file clipboard to own file
* check for changed file data in cliprdr_file_context_update_data,
  prevents duplidate entries in fuse filesystem
2023-02-28 09:47:54 +01:00
Armin Novak
acc5e2d301 [client,common] use non blocking IO
when reading from stdin use non blocking IO so that we can check if the
session terminated in between.
2023-02-28 09:47:54 +01:00
akallabeth
ae8f7c272d [client,x11] fixed clipboard data cache
clean only cached data not the fuse cache if other formats are requested
2023-02-28 09:47:54 +01:00
akallabeth
1ba8d826f8 [client,x11] add some debug logs, fix warnings 2023-02-28 09:47:54 +01:00
akallabeth
3d9969ef65 [client,x11] export x11_event_string 2023-02-28 09:47:54 +01:00
akallabeth
adce7378c3 [core,cache] make protocol caches private
most protocol internal caches do not need to be exposed. this reduces
the public API and allows us to more easily improve/change this during a
release cycle
2023-02-27 17:31:52 +01:00
Armin Novak
f0e9797b4c [build] require CMake >= 3.13
required for target_link_options
2023-02-27 11:18:02 +01:00
Armin Novak
f357312584 [utils] term signal cleanup handlers
add functions to register/unregister termination cleanup handlers
2023-02-23 20:28:15 +01:00
Armin Novak
64efb7ecfd [client,x11] fail build on manpage generation
if manpages should be build but dependencies are missing fail the build
2023-02-23 20:28:15 +01:00
Armin Novak
078162616d [client,x11] split clipboard formats
* a format to request
* a local format to convert to
* add logging
2023-02-23 20:28:15 +01:00
Armin Novak
b8a709ccda [client,x11] fixed file clipboard cache
if files are pasted in different file-browser (or e.g. xclip is used)
the data was retrieved in wrong format.
2023-02-21 16:42:54 +01:00
Armin Novak
1522b5aa91 xx 2023-02-21 16:42:54 +01:00
Armin Novak
fe3de9b9bf [client,x11] log fuse_session_loop errors 2023-02-21 16:42:54 +01:00
Armin Novak
68d3bcb99a [clipboard] remove linux specifics from channels/cliprdr.h 2023-02-21 16:42:54 +01:00
Armin Novak
10bf44c112 [client,x11] use fuse_root_id 2023-02-21 16:42:54 +01:00
Armin Novak
ded270e167 [client,x11] fix fuse file list reset 2023-02-21 16:42:54 +01:00
Armin Novak
9b174c50c9 [client,x11] add fuse debug messages 2023-02-21 16:42:54 +01:00
Armin Novak
d694733106 [client,x11] fix fuse detection and use 2023-02-21 16:42:54 +01:00
akallabeth
a91b2f4999 [client,sdl] fixed error code mapping 2023-02-21 14:38:34 +01:00
akallabeth
f807af6f8e [client,sdl] do not wait for SDL to complete
when updating the window surface in sdl_end_paint do not wait for
completion of the operation. The check is done in sdl_begin_paint, so
the RDP stack can continue processing other data on queue until a
graphic operation needs to be processed.
2023-02-21 14:38:34 +01:00
akallabeth
82a0eab71f [client,sdl] add debug options 2023-02-21 14:38:34 +01:00
akallabeth
e3a7eaf39a [client,sdl] run sdl in main thread. 2023-02-21 14:38:34 +01:00
akallabeth
ab5be61e89 [client,common] working REDIRECTION_VERSION6
* REDIRECTION_VERSION6 requires enabled multitransport, enable it
* Add a fallback if multitransport was disabled
2023-02-20 16:04:04 +01:00
Martin Fleisz
1bec63c2f2 client/win: Fix invalid ShowWindow call from gfx thread
ShowWindow must be called from the thread that owns the window.
Currently it might be called from the gfx channel thread which causes
random app hangs/window not showing up issues.
2023-02-16 10:41:21 +01:00
akallabeth
45dfeabe92 [client,common] set default callbacks before ClientNew
ohterwise the default callbacks might override custom callbacks set by
an implementation by accident
2023-02-16 08:16:09 +01:00
Armin Novak
25023d3a3a [client,scard] fix missing callback instance arg
every callback requires context, add freerdp* instance just as the
Authenticate et al callbacks already have
2023-02-15 13:34:18 +01:00
Armin Novak
5d97a03bf4 [client] auto intialize callbacks
initialize all message/user query callbacks with client_cli_*
2023-02-15 13:34:18 +01:00
akallabeth
caaf4edffa [clients] clean up .gitignore
too much was ignored, clean up the list
2023-02-15 13:34:18 +01:00
akallabeth
ff3c7c82ee [client,x11] fix /gdi:hw drawing. 2023-02-14 09:30:45 +01:00
akallabeth
7728df6804 [client,mac] fix wrong getter for ServerPort 2023-02-12 20:17:11 +01:00
akallabeth
87b30958a6 [cyrpto] unify PEM read/write
use crypto_read_pem and crypto_write_pem in all places required
2023-02-12 20:17:11 +01:00
akallabeth
9e8fc60a45 [client,common] add openssl includes for TLS version 2023-02-12 20:17:11 +01:00
akallabeth
4499a55f43 [core,smartcardlogon] use rdpCertificate 2023-02-12 20:17:11 +01:00
akallabeth
2eda0aa2ea [core,settings] remove unused setting 2023-02-03 11:24:32 +01:00
Armin Novak
427a4fa057 [client,common] deprecate old gateway options 2023-02-03 11:08:46 +01:00
Armin Novak
923b068382 [client,common] unified credential hiding
* Unify command line credential string replace in a single function
* Extend the string replace, add all options containing a token or
  a password
2023-02-03 11:08:46 +01:00
Armin Novak
9d8954f56a [client,common] add new option /gateway
* unifies old /g, /gu, /gd, /gp, /gt, /gat and /gateway-usage-method
  options into a single one.
* add new option auto-consent:[on|off]
2023-02-03 11:08:46 +01:00
Armin Novak
57698ed1f9 [client,common] fixed possible memory leak 2023-02-03 11:08:46 +01:00
Armin Novak
cd48e17740 [gateway,settings] add GatewayAutoConsent option
with this option the client automatically accepts consent messages of
the gateway server.
2023-02-03 11:08:46 +01:00
akallabeth
1b254c17ea [client,wayland] fix cast warnings 2023-02-01 09:51:54 +01:00
Armin Novak
70f6c09ff4 [core] fix persistent bitmap cache setting
* Only activate if both, client and server support the capability
* Use settings getter to access setting
2023-01-26 09:30:17 +01:00
Armin Novak
641022b795 [logging] remove __FUNCTION__ from actual message
prefer the log formatter to provide that information.
2023-01-25 16:26:39 +01:00
Armin Novak
05f933398c [client,sdl] print number of monitors before listing 2023-01-25 14:27:15 +01:00
Armin Novak
c1174152c3 [client,common] print help on wrong list command 2023-01-25 14:27:15 +01:00
Armin Novak
aee9f68f7d fixed SDL utils. 2023-01-25 14:27:15 +01:00
Armin Novak
56df6177e1 [client,sdl] Add WSAStartup
Windows requires WSAStartup to be called for the client to work.
2023-01-25 14:27:15 +01:00
Armin Novak
d2b50a06b5 [client,sdl] only call freerdp_disconnect if connected 2023-01-24 10:16:55 +01:00
Armin Novak
4b3133b138 [client,sdl] use dynamic logger instance 2023-01-18 09:32:41 +01:00
Armin Novak
a1b764019d [client,sdl] add log functions 2023-01-18 09:32:41 +01:00
Armin Novak
defa74b94b [build] continue if SDL2 is requested but not found 2023-01-18 09:32:41 +01:00
Rozhuk Ivan
a111b78530 [core] Rename TLS functions
Rename tls_ to freerdp_tls_ to avoid namespace conflicts with libtls
and probaly other tls crypto libs.
2023-01-14 08:50:26 +01:00
Armin Novak
e6a4b86fd6 [client,mac] use settings getter/setter 2023-01-14 08:09:08 +01:00
jfliu
5b44bc63e8 fix Chinese title on mac 2023-01-14 08:09:08 +01:00
amazingfate
a691b48bc0 hide password for mac client 2023-01-13 11:42:08 +01:00
akallabeth
1f7bcd4a1a [client,sdl] print experimental warning 2023-01-10 17:38:00 +01:00
Armin Novak
070353bf90 added SDL2 client 2023-01-10 17:38:00 +01:00
akallabeth
82ba9ede9c [freerdp] use FREERDP_/UWAC_/RDTK_ prefix for conditional headers 2023-01-10 17:38:00 +01:00
Armin Novak
d66b165b8e [client,common] common touch handling 2023-01-10 17:38:00 +01:00
Bernhard Miklautz
08ffe661e0 fix [client/Mac]: ninja build
Problem that caused the ninja build to fail:

* `ninja: error: build.ninja:14841: bad $-escape (literal $ must be written as $$)` - because of the way CONFIGURATION was passed
* missing build dependency betwenn client/Mac and client/Mac/cli
2023-01-10 13:26:54 +01:00
Armin Novak
d978a0dbdb [client,x11] fix rail checks
rail might be deactivated during connect, so ensure that the default
session rendering path properly checks the window pointer
2023-01-10 11:49:02 +01:00
akallabeth
9a80afeb08 [client,cmdline] add support for .rdpw file extension 2022-12-21 16:11:57 +01:00
akallabeth
8c6ee2061b [client,cmdline] fixed /gfx parsing
* Fixed a bug not activating AVC444 when requested
* Unified legacy /gfx-h264 parsing with /gfx
2022-12-15 11:20:34 +01:00
Armin Novak
2b49047c34 [client] Fix keyboard input
properly pass key repeat events to the server.
2022-12-13 14:37:05 +01:00
Armin Novak
d90aa5d6f5 [client,x11] Fixed #8099: Detect key autorepeat
When a key is pressed in autorepeat mode, skip the KeyRelease events in
between.
2022-12-13 14:37:05 +01:00
Armin Novak
5f81005ecb [transport] remove polling loop
We no longer have a blocking polling loop in transport. Instead assume
there is more data after a packet was processed and let the transport
try again. If there is another packet ready, this repeats until only a
partly received (or no new data available) situation is reached.
2022-12-12 12:59:32 +01:00
akallabeth
d4808dd3e1 Fixed various compiler warnings 2022-12-09 15:58:26 +01:00
Armin Novak
bd7e2263ad fixed const and type cast warnings 2022-12-09 15:58:26 +01:00
akallabeth
3ddf99ad64 Fixed Wformat warnings 2022-12-09 15:58:26 +01:00
akallabeth
f553d453b8 [client,x11] use HashTable_ForEach for rail paint 2022-12-09 12:30:14 +01:00
Armin Novak
ef5f51ba04 [x11,client] remove dead initialization code 2022-12-09 12:30:14 +01:00
Armin Novak
1bc110518d [x11,rail] cleaned up rail drawing code
The remote application drawing code was simplified
2022-12-09 12:30:14 +01:00
Armin Novak
4008033065 [x11,client] assert use of xfc->depth
Do not use color depth settings before they are initialized
2022-12-09 12:30:14 +01:00
Armin Novak
eda1359f52 [x11,client] clean up color depth initialization
* Do not use transparency except in remote application mode.
* Fall back to default color depth in rail mode if no transparency
  supported
2022-12-09 12:30:14 +01:00
Armin Novak
22d5394993 [x11,client] unified drawing path
Do not distinguish between rail and desktop sessions when drawing
2022-12-09 12:30:14 +01:00
Armin Novak
96243c1d17 [x11,client] unify modifier map update/free 2022-12-09 12:30:14 +01:00
akallabeth
4d885e3a6e [client,x11] Initialize window with 32bit color
Allow alpha channel to be properly processed for rail
2022-12-09 12:30:14 +01:00
akallabeth
7b6023b340 [client,x11] move X11 init to post connect 2022-12-09 12:30:14 +01:00
akallabeth
cb5c98aab0 [core,client] Add PostFinalDisconnect callback
To have more fine granied control add a new callback.
Now you have the following callback pairs:
* PreConnect <--> PostFinalDisconnect
* PostConnect <--> PostDisconnect
2022-12-09 12:30:14 +01:00
Armin Novak
5a24ec2171 [client,windows] release keyboard grab on minimize 2022-12-09 11:28:21 +01:00
Armin Novak
7027699a5c [client,cmdline] remove -fast-path option
This option is quite an expert setting and should not be exposed that
prominently. Remove it as it can still be changed with the /tune option.
2022-12-06 16:41:24 +01:00
Armin Novak
3e3ed445b4 [client,file] add rdgiskdcproxy to settings
Adds a new option FreeRDP_KerberosRdgIsKdc to manually set the KDC url
to the gateway server url
2022-12-06 14:07:53 +01:00
Armin Novak
3b7d515f85 [client,file] add kdcproxyname to parsing options 2022-12-06 14:07:53 +01:00
Armin Novak
9218a404b5 [client,x11] force initial format list 2022-12-03 10:53:18 +01:00
Armin Novak
a5d9c3b846 [client,cmdline] fix order of arguments
option_starts_with was called with inverted arguments.
2022-11-29 22:29:29 +01:00
Armin Novak
40b55466bf [client,windows] Fixed useless string conversion 2022-11-28 10:42:36 +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
00ee213f97 [winpr,android] Unify JNI_OnLoad
* Split JNI_OnLoad and JNI_OnUnload to own module to be usable from more
  than only timezone
* Explicitly call System.loadLibrary('winpr') (and other FreeRDP
  libraries) in android client as JNI_OnLoad is only triggered by that
  and not implicit loading
2022-11-28 10:42:36 +01:00
Armin Novak
c5e425242a [settings] Typo in GatewayHttpExtAuthSspiNtlm 2022-11-23 11:19:21 +01:00
Armin Novak
b6b05e93a4 [xfreerdp] fix sending monitor layout PDU
only send it if there are more monitors available.
2022-11-22 15:30:31 +01:00
akarl10
b1583d56c0 [rdg] implementation of http_extauth_sspi_ntlm 2022-11-16 20:28:53 +01:00
Armin Novak
5ecd62a5f7 [client,cmdline] Fix /enforce-tlsv1_2 parsing 2022-11-16 16:03:21 +01:00
Armin Novak
a489c69f10 [client,x11] Fixed #8397: Clamp scaled cursor sizes
If a cursor is scaled, ensure the result size is at least 1x1 pixel
wide.
2022-11-16 13:47:02 +01:00
akallabeth
33827cb920 Updated RDP state machine
* More detailed states
* Better transition checks
* No more recursive calling of state machine functions
2022-11-11 11:51:27 +01:00
Armin Novak
697e020abd [rail] Added window update from surface 2022-11-11 06:42:45 +01:00
Armin Novak
325c03501e [gfx] Added new UpdateWindowFromSurface callback
* Adds a new callback and settings in gdiGfxSurface to allow updating
  a window directly from surface bitmap data
* Adds new BOOL in gdiGfxSurface windowMapped and
  handleInUpdateSurfaceArea to control where surface data update is
  being handled
2022-11-11 06:42:45 +01:00
JeonJongHyeon97
55015fd59b Fix untracked clipboard 2022-11-07 08:54:34 +01:00
akallabeth
450f8a1d7e Fixed wrong define check
The deprecated command line must only be used if
WITH_FREERDP_DEPRECATED_COMMANDLINE is defined
2022-11-04 14:46:58 +01:00
akallabeth
3023057b16 Cleaned up some loop code in xf_monitor
Use loop variables to make it more readable
2022-11-04 14:46:58 +01:00
Armin Novak
5306c3ec0a Write an error log if a PEM file can not be read. 2022-11-03 11:06:15 +01:00
akallabeth
c0193a1813 Fixed #8259: in remote app mode keep the keyboard state
If the mouse enters/leaves the window or the window is unmapped in
desktop session mode we can reset the keyboard modifiers state
while in remote app mode these events have different meaning. Be
more strict in the latter case and only reset on focus out
2022-11-03 11:01:30 +01:00
Armin Novak
3dc5ac74a9 Fix parsing of smartcard options 2022-10-27 11:55:49 +02:00
Armin Novak
5e1d7c0f8d Unified comparisons
* Use option_starts_with for all checks
* Use option_ends_with for all checks
* Use option_equals for all comparisons
2022-10-27 11:36:58 +02:00
Armin Novak
fa1bbfe1bd Fixed on/off string length checks 2022-10-27 10:13:57 +02:00
Armin Novak
605ff25269 Fixed string size for keyboard option parser 2022-10-27 10:13:57 +02:00
akallabeth
967749d43f Unify command line deprecation warning log messages 2022-10-27 10:13:57 +02:00
akallabeth
e3528e3728 Unified /app-* command line arguments 2022-10-27 10:13:57 +02:00
akallabeth
f7850f08aa Added option WITH_FREERDP_DEPRECATED_COMMANDLINE_COMMANDLINE
This allows building deprecated command line options without adding
deprecated functions to the build.
2022-10-27 10:13:57 +02:00
akallabeth
55362225cc Unified /kbd-* command line options
The number of /kbd-* options grew too large, unify them under a
single /kbd:<option1>,<option2>,... setting
2022-10-27 10:13:57 +02:00
akallabeth
d1a736273e Added deprecation log messages, fixed on|off parsing for /sec 2022-10-27 10:13:57 +02:00
akallabeth
391199cbeb Unified /*-cache command line options
There were multiple options enabling/disabling cache features.
Unifed them all under a single /cache:<option1>,<option2>,...
2022-10-27 10:13:57 +02:00
akallabeth
41284f47e7 Unify /gfx options
* Deprecate all gfx-* options
* Extend argument parsing for /gfx:<option1>,<option2>,...
2022-10-27 10:13:57 +02:00
akallabeth
181debc3d1 Remove /tls:enforce:ssl3 option
SSL3 is deactivated during connect anyway, so do not expose the
option
2022-10-20 10:51:50 +02:00
akallabeth
ef6842d249 Fixed TLS1_3_VERSION check and parse_tls_seclevel
* Only add TLS1_3_VERSION to array if the SSL library build against
  has support for TLS 1.3
* Fix wrong parse function call for 'seclevel'
2022-10-20 10:51:50 +02:00
Armin Novak
187b553b97 Allow overriding TLS version
Now use a generic option to allow setting all possible SSL/TLS versions.
Use /tls:enforce:[ssl3|1.0|1.1|1.2|1.3] to set accordingly
2022-10-19 20:31:53 +02:00
Armin Novak
119b8d4474 Unified command line options to list something
There are various options to list smartcards, monitors, keyboard
settings. Unify them all under a single /list:<something> option
2022-10-19 20:31:53 +02:00
Armin Novak
7e82c9f19f Cleaned up functions printing information 2022-10-19 20:31:53 +02:00
Armin Novak
1f6476016d Update command line option /sec*
* Deprecate /sec-* flags
* Allow multiple arguments for /sec
2022-10-19 20:31:53 +02:00
Armin Novak
ed3bc5c51a Only enable deprecated commandline with WITH_FREERDP_DEPRECATED 2022-10-19 20:31:53 +02:00
Armin Novak
1c8bcbeb6a Added deprecation warnings to /cert-* options 2022-10-19 20:31:53 +02:00
Armin Novak
d357fa3237 Added a unified /tls: option
There are too many tls settings scattered over multiple different
switches. Add a unified option and deprecate the old ones
2022-10-19 20:31:53 +02:00
fifthdegree
eb04eb0008 Support using smartcard for gateway authentication 2022-10-19 18:55:38 +02:00
fifthdegree
e847f159a6 Try to use the smartcard key name Windows uses
Windows expects the containerName field in TSSmartCardCreds to be what
it would use for a smartcard key's name. Try to accomodate that (at
least for PIV and GIDS cards).
2022-10-19 18:55:38 +02:00
fifthdegree
9d0beaccae smartcardlogon: choose a single smartcard to use
Require a single smartcard certificate to be chosen and define a
callback to choose when more than one is available.
2022-10-19 18:55:38 +02:00
xiaopengzhou@hotmail.com
34afe6b23e Fix Format List PDU is not sent when the Clipboard Redirection Virtual Channel is initialized for the second time. (X11 client) 2022-10-18 09:14:21 +02:00
Marc-André Moreau
e3594c91dc Add UserSpecifiedServerName setting, /server-name command-line parameter 2022-10-14 17:59:57 -04: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
Armin Novak
be9cc98c08 Refactored cmdline common
* Add settings setter where possible
* Load dynamic sound channel alongside static one
* Load clipboard channel if requested
2022-10-13 14:48:40 +02:00
akallabeth
b58dd122b2 Disable functions that require WITH_CHANNEL if not defined 2022-10-13 14:38:06 +02:00
akallabeth
dfb6e9200c Fixed build without RDPEI channel 2022-10-13 14:38:06 +02:00
akallabeth
a38d584bf1 Do not compile client functions for encomsp if channel deactivated 2022-10-13 12:12:24 +02:00
David Fort
f76c14c256 fix smartcard logon with smartcard emulation
When smartcard emulation was enabled we were dumping the key and cert to
temporary files for PKINIT call, but they were deleted before we have
actually done the PKINIT. This patch fixes it.

It also add debug statement for the listing of smartcard keys / certs.

This also fixes the listing of smartcard on certain windows configurations
were we have to force NCRYPT_SILENT when doing a NCryptOpenKey.
2022-10-13 12:03:58 +02:00
Marc-André Moreau
27a865af74 Add Negotiate SSPI authentication module filtering 2022-10-12 22:07:45 +02:00
akallabeth
bd4b261a88 Fixed #8296: Assert floatbar->handle and not xfc->window 2022-10-12 21:44:27 +02:00
akallabeth
796ceb2783 Fixed #8269: Ignore mouse/input events during floatbar events 2022-10-07 11:26:56 +02:00
akallabeth
98f9a4da19 Clean up use of memset 2022-10-07 11:26:56 +02:00
akallabeth
8671339b12 Added assertions to floatbar 2022-10-07 11:26:56 +02:00
akallabeth
60720e7706 Improved streamdump file format 2022-10-07 10:38:03 +02:00
akallabeth
ed0f258423 Use GFX small cache by default
RAILS does have some problems if this is not enabled and there is
no real benefit for not setting it, so default it
2022-10-06 16:20:47 +02:00
David Fort
3947294ffb Adjust smartcard listing
When no CSP is provided, we were listing smartcard materials by querying the
MS_SCARD_PROV_A CSP, unfortunately on some windows hosts, the smartcards aren't
listed in that CSP. So this patch does the key listing by browsing all CSPs
instead of just a default one. You can still force a CSP and you'll get keys only
from this one.

This patch also address cases where the certificate on the smartcard doesn't
have a UPN attribute, if that happen we try to get a UPN from the email address.
2022-10-06 16:06:35 +02:00
David Fort
229e047231
fix build under mingw (#8271) 2022-10-04 16:06:22 +02:00
Marc-André Moreau
cd6fcaacb4 use kerberos command-line suboptions for KDC URL 2022-09-30 19:33:12 +02:00
Marc-André Moreau
21d28ab62d add --kdc-url command-line parameter 2022-09-30 19:33:12 +02:00
akallabeth
1849632c43
Fixed format strings to match arguments (#8254)
* Fixed format strings to match arguments

Reviewed and replaced all %d specifiers to match proper type

* Added proxy dynamic channel command type to log messages.
2022-09-29 14:55:27 +02:00
akallabeth
b44810418b reformatted changes 2022-09-29 09:06:28 +02:00
Stefan Koell
eb90985bf5 cleanup resources 2022-09-29 09:06:28 +02:00
Stefan Koell
a77e742e99 switch to CredReadW, more code cleanup 2022-09-29 09:06:28 +02:00
Stefan Koell
ec9542d0e1 added header file and more code cleanup 2022-09-29 09:06:28 +02:00
Stefan Koell
45578d3c63 various coding style changes according to feedback 2022-09-29 09:06:28 +02:00
Stefan Koell
f8b6154a20 Support for windows credential manager when username and password is not available
* added wf_defaults.c (also in CMakeLists.txt) which provides the capability to read credential manager entries and set username and password in the rdpSettings accordingly
* the same will be done if a gateway host is specified without credentials
* the behavior will be similar to mstsc.exe on windows
2022-09-29 09:06:28 +02:00
David Fort
c5c2e37f6d
More winpr fixes (#8255)
* Fix build with mingw

4a71cab2e7 broke wf_events.c.
The drive channel was not building because of missing definitions.

* winpr: make functions return False when not implemented
2022-09-28 16:07:04 +02:00
akallabeth
4a71cab2e7
Replaced custom coordinate macros with windows ones (#8247)
GET_X_LPARAM and GET_Y_LPARAM correctly extract the mouse x/y
coordinates from lParam
2022-09-26 12:11:50 +02:00
akallabeth
d2ab631c40
Test uri fix (#8232)
* Fixed TestUri unit test

* Make proper unit test out of the test function
* Add proper test cases

* Replace FindFirstFileA with FindFirstFileW for addins

This allows addin paths to contain unicode symbols.

* Fixed parse_uri_to_local_file definition

* Move to common clipboard.c file
* Move to header file so it can be included in test case

* Added WINPR_LOCAL for test builds

This macro exports internal functions in case of a unit test build
This way unit tests can access these without other workarounds.

* Fixed typo in function name is_dos_driver

* Cleaned up FindFirstFileW call

Use a wrapper function to convert to unicode and call the function

* Cleaned up BUILD_TESTING and EXPORT_ALL_SYMBOLS

* EXPORT_ALL_SYMBOLS now does as the name implies and exports all
  non static functions/variables from the library.
* BUILD_TESTING now only sets the defines for test code and
  activates EXPORT_ALL_SYMBOLS to allow tests to access internal
  code

* Fixed windows client warnings

* disable CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS
2022-09-26 11:22:02 +02:00
James Fu
a04021d38b Send resize on window state change 2022-09-22 13:48:24 +02:00
akallabeth
b18ca128c8
Fixed missing encomsp check (#8238)
The channel might not have been initialized and the pointer NULL
2022-09-22 10:27:52 +02:00
David Fort
e266784b24 client: fix channel loading for rdp2tcp
The RDP2Tcp channel has no associated bool in settings for configuring the loading
of the channel (only settings->RDP2TCPArgs for the args), so let's load it outside
of the big loading loop (prevent a warning for unknown bool setting 1519).
2022-09-21 16:04:02 +02:00
garbb
24fc77a073 fix mouse button "stuck" down when dragged out of window
If user presses mouse button down within window and then moves it
outside of window before releasing, host will still see mouse
button as "stuck down" because mouse up event is not sent. So use
`SetCapture()`/`ReleaseCapture()` to capture mouse events until
button is released.
Also, since coordinates from WM_* events are signed values,
need to prevent negative values from being sent.
2022-09-21 09:59:22 +02:00
Armin Novak
c018632870 Cleaned up android input event processing
* Unified event cleanup code
* Add proper support for unicode input
* Add proper return code for event process failures
2022-09-20 15:52:14 +02:00
Simon Nivault
82b58325a3 Add switch to declare printer as default or not 2022-09-20 13:25:05 +02:00
2fly2
7e8986325c fix can not copy file after last copy
Signed-off-by: 2fly2 <wjatchd@163.com>
2022-09-20 11:56:35 +02:00
2fly2
afd28494a2 fix copy 0 size file on windows
Signed-off-by: 2fly2 <wjatchd@163.com>
2022-09-20 11:56:35 +02:00
2fly2
880a82e97b fix connection abort when copy from remote wordpad, local windows 10, open local clipboard history in settings
Signed-off-by: 2fly2 <wjatchd@163.com>
2022-09-19 14:13:08 +02:00
garbb
940317282c remember participantId for use with assistance set control request 2022-09-19 09:41:45 +02:00
garbb
22bd0a43e6 add windows client assistance request control menu item 2022-09-16 08:47:06 +02:00
garbb
488b52405a change to c style comment 2022-09-15 10:25:35 +02:00
garbb
0413dfe7df if /auto-request-control, only request control once upon connect
if auto-request-control setting is enabled then only request control once upon connect, otherwise it will auto request control again every time server turns off control which is a bit annoying.
2022-09-15 10:25:35 +02:00
David Fort
1905524442
Channel loading (#8204)
* update .gitignore and cleanup conditionnal callback call

* client: rework channel loading

Automate the loading of channels that only depend on a given enabled setting.
2022-09-14 13:53:27 +02:00
Armin Novak
98f9c7e04b Fix #8176: Check fullscreen state and not setting
Timer based dynamic resolution updates are disabled in fullscreen
state. Check current value and not (permanent) setting
2022-09-14 08:51:54 +02:00
Armin Novak
8561b08592 Fixed gnome and mate clipboard format synthesizers 2022-09-13 14:42:33 +02:00
garbb
e06ac251d5
[windows] Disable input events on focus loss (#8199) 2022-09-13 09:34:15 +02:00
garbb
383ecc3cbd fix graphics glitch on toggle smart-sizing 2022-09-13 09:23:32 +02:00
Armin Novak
707b9348ee Unify encomsp request control code 2022-09-13 09:22:41 +02:00
garbb
8d00137cad Update wf_channels.c 2022-09-12 12:58:28 +02:00
garbb
4c2c6ed310 Update wf_client.h 2022-09-12 12:58:28 +02:00
garbb
51085a1e26 Update wf_channels.c 2022-09-12 12:58:28 +02:00
garbb
0bf644aa9a Update wf_client.h 2022-09-12 12:58:28 +02:00
garbb
5346b6628b Update wf_channels.c 2022-09-12 12:58:28 +02:00
garbb
3d12e4e8ff do not resize client window if emart sizing is enabled
If smart-sizing option is enabled in windows client and the server's desktop resolution changes, do not change the size of the client window.
This is because I would assume that if the user has enabled smart-sizing, they would intend for the window to be set to a particular size and not change.
Also, when connecting to windows 10 client, `wf_desktop_resize()` is called once just after connect and so if wfreerdp is run with `/smart-sizing:WxH` then the window will start at the size `WxH` but then immediately change to the desktop resolution of the server which makes the `/smart-sizing:WxH` parameter effectively do nothing.
2022-09-12 09:23:05 +02:00
garbb
ef5316ca1d Update wf_client.c 2022-09-12 08:40:10 +02:00
garbb
c5573371c2 Update wf_client.c 2022-09-12 08:40:10 +02:00
garbb
bb487f045a Update wf_client.c 2022-09-12 08:40:10 +02:00
garbb
9dc75441ec Update wf_gdi.h 2022-09-12 08:40:10 +02:00
garbb
c869e647fa fix scaling of update rect on windows client 2022-09-12 08:40:10 +02:00
garbb
4dbac37aed Update wf_gdi.c 2022-09-12 08:35:38 +02:00
garbb
7cfafee570 add /smart-sizing:WxH and /window-position:XxY for windows client 2022-09-12 08:35:38 +02:00
Kang Lin
98db5691e1
FIX: error checking (#8181) 2022-09-07 09:23:48 +02:00
Martin Fleisz
d8ac6e978e x11: Fix disconnects if WITH_XCURSOR is set to OFF
Fix disconnects if WITH_XCURSOR is set to OFF. In that case xf_Pointer_New currently returns FALSE causing a disconnect.
2022-09-05 14:12:47 +02:00
David Fort
4fc7a9417d
Various fixes / improvements (#8146)
* xfreerdp: fix typo in logs

* winpr: file appender, small code cleanup

* shadow-server: add an option for TLS secrets

This allows to dissect connections to the shadow server.
2022-08-22 09:42:15 +02:00
liuyuh007
95b4d3cd3d
Update cmdline.c (#8140)
ipv6 port parse error
2022-08-19 13:43:44 +02:00
2fly2
8dfadc5885
fix moving a window shrinks it 14x7 when connect to server 2019 (#8083)
* fix moving a window shrinks it 14x7 when connect to server 2019

Signed-off-by: 2fly2 <wjatchd@163.com>

* use clang-format to apply correct formatting

Signed-off-by: 2fly2 <wjatchd@163.com>

Signed-off-by: 2fly2 <wjatchd@163.com>
2022-08-16 14:22:03 +02:00
Jianfeng Liu
899424e941
xf_floatbar use XmbDrawString instead of XDrawString (#8127)
* xf_floatbar use XmbDrawString instead of XDrawString

* xf_floatbar fall back to XDrawString when fontSet is NULL

Co-authored-by: Jianfeng Liu <jfliu@zshield.net>
2022-08-16 14:21:06 +02:00
David Fort
942273e9cb
tls: add an option to dump tls secrets for wireshark decoding (#8120)
This new option /tls-secret-file:<file> allows to dump TLS secrets in a file with
the SSLKEYLOGFILE format. So this way you can setup the TLS dissector of wireshark
(Pre-Master-Secret log filename) and see the traffic in clear in wireshark.
It also add some more PFS ciphers to remove for netmon captures.
2022-08-16 10:40:32 +02:00
zengguang
e3cfe7300c
Fixed app windows destroy will do close(0) (#8073)
shmid was not initailized on creation of app window, that will be close fd = 0. everytimes in app windows destroy (Call xf_DestroyWindow ).
2022-07-15 09:18:45 +02:00
Armin Novak
b2df9207e4 Fixed #8054: multimonitor settings 2022-07-07 14:24:07 +00:00