Armin Novak
2d166aea89
TSG improvements
...
* Respect connection timeout during connect
* Better debug output
* Cleaned up data types,
(cherry picked from commit ff79636d33
)
2020-06-22 09:30:57 +02:00
akallabeth
2f75c4ac8d
Ensure all NLA structs are freed up
...
(cherry picked from commit 477ad675f3
)
2020-05-18 16:40:33 +02:00
Armin Novak
548bec9ef2
Setting optional last error on transport close
...
Signed-off-by: Armin Novak <armin.novak@thincast.com>
2020-01-09 10:35:49 +01:00
Armin Novak
895cb8f944
Added macro freerdp_set_last_error_if_not
...
This macro replaces the multiple instances where the current
error state is checked before setting an optional error state.
Signed-off-by: Armin Novak <armin.novak@thincast.com>
2020-01-09 10:34:27 +01:00
Armin Novak
2391a1528b
CONNECT_TRANSPORT_FAILED in transport_check_fds
...
If TRANSPORT_LAYER_CLOSED was detected in transport_check_fds
check if there is already a connection error set, otherwise
set FREERDP_ERROR_CONNECT_TRANSPORT_FAILED to allow proper
reconnect or abort handling.
Signed-off-by: Armin Novak <armin.novak@thincast.com>
2020-01-08 17:42:08 +01:00
Armin Novak
7d252cdc8e
Added freerdp_set_last_error_ex function
...
This new function allows better logging of call locations
for errors. Additionally added freerdp_set_error_log macro
to record function, file and line the error was set.
Signed-off-by: Armin Novak <armin.novak@thincast.com>
2020-01-08 17:39:25 +01:00
Norbert Federa
a4988f5469
transport: check if layer was set to closed
...
There are several code paths and error conditions where
transport->layer is correctly set to TRANSPORT_LAYER_CLOSED but
the required code for checking that state was missing.
E.g. write errors in the rdg code resulted in marking the transport
layer as closed but the transport code would indefinitely continue
to read from the receiving socket.
2019-12-27 12:37:03 +01:00
Armin Novak
7c243da6e1
Remove symbols exported by accident.
2019-12-02 10:57:31 +01:00
Armin Novak
72ca88f49c
Reformatted to new style
2019-11-07 10:53:54 +01:00
David Fort
824d09169e
rdp: fix byte and packet counters
...
Best to count bytes directly at the transport level.
2019-11-04 07:39:35 +01:00
asapelkin
82eadad4a4
Fix some static analizer warnings
2019-10-22 15:39:54 +02:00
Armin Novak
733cc36462
Setting freerdp_last_error in gateway error response.
2019-09-24 09:42:13 +02:00
Armin Novak
f93d625cde
Use GetTickCount64 instead of GetTickCountPrecise.
2019-09-02 15:46:36 +02:00
Armin Novak
f51a9bafcc
Fixed sign-compare warnings
2019-04-05 09:13:24 +02:00
Armin Novak
4ad0770a7e
Silenced function pointer cast warnings for BIO_callback_ctrl
2019-02-21 13:53:51 +01:00
Armin Novak
82863a8518
Refactored NLA to be self contained.
2018-12-05 10:55:06 +01:00
Armin Novak
ecac998340
Fixed rdg bio cleanup.
...
When attaching the RDG BIO to the TLS BIO also transfer ownership.
2018-11-13 12:22:09 +01:00
Armin Novak
3c35a098f5
Fixed direct rdg front bio access.
2018-11-13 11:24:04 +01:00
Armin Novak
b4fc0c75ce
Made rdpRdp opaque
2018-11-13 11:22:37 +01:00
Armin Novak
5f4843191b
Replaced BIO_free with BIO_free_all
...
There is no point in using BIO_free with a custom recursion
to free up stacked BIOs if there is already BIO_free_all.
Using it consistently avoids memory leaks due to stacked BIOs
not being recursively freed.
2018-11-08 12:09:49 +01:00
Armin Novak
f269a0ce5b
Fixed sockfd/socketBio resource leak.
2018-10-25 13:19:45 +02:00
akallabeth
8fe3ac5d26
Merge pull request #4902 from akallabeth/gw_refactor_3
...
Gateway refactoring
2018-10-17 12:23:10 +02:00
Armin Novak
3b7f522eb7
Release stream in transport_write in all error cases.
2018-10-02 10:31:23 +02:00
Armin Novak
9516c251c7
Made TSG struct opaque
2018-09-28 12:00:45 +02:00
Martin Fleisz
f9e52c1850
Merge pull request #4815 from akallabeth/async_transport_remove
...
Removed +async-transport options
2018-08-24 09:48:51 +02:00
Ondrej Holy
47595a857f
core/transport: Fix leak found by covscan
...
0 is valid return value from socket().
leaked_handle: Handle variable "sockfd" going out of scope leaks the handle.
2018-08-22 14:34:02 +02: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
b59b0a4425
Added error log messages.
2018-05-04 09:11:41 +02:00
Martin Fleisz
296b19e172
Merge pull request #4596 from p-pautov/rdg_ssl_fixes
...
RDG related fixes for better compatibility with mstsc
2018-05-03 10:23:12 +02:00
David Fort
0f968b782c
proxy: cleanup SOCKS support and add user/password support
2018-05-02 10:51:16 +02:00
p-pautov
fda76349b9
Fix Windows build.
2018-04-26 02:11:04 -07:00
Pavel Pautov
a0019ec79c
Fallback to RDG RPC transport only if server does not support RDG HTTP and
...
error out in other cases - invalid RDG SSL cert, bad credentials, PAA failue, etc.
2018-04-25 18:36:43 -07:00
Jiri Sasek
b1c1549ad1
SOCKS proxy support
2018-04-23 21:01:01 +02:00
Armin Novak
2517755d25
Fixed thread function return and parameters.
2018-03-07 14:36:55 +01:00
Armin Novak
a419677e8f
Fix invalid handle offset.
2018-03-06 13:58:40 +01:00
David Fort
41823080f9
Fix users of Stream_GetPosition() that returns size_t
2017-12-11 22:38:58 +01:00
David Fort
11ee81be60
Fix XRandr for old systems and MacOSX
...
We need a recent enough version of XRandr to correctly detect monitor.
Also this patch adds some typo or style fixes.
2017-12-08 10:59:38 +01:00
dodo040
b81f168f0e
initial commit for kerberos support
2017-11-13 16:20:55 +01:00
Armin Novak
ce00f4dd8f
Silence WLog_ERR messages if last error is set.
2017-11-06 14:02:22 +01:00
tditsch
a16d9a2ade
refactored Bugfix
2017-09-19 10:18:41 +02:00
tditsch
feca6d9750
Fixed endless loop when RDP Server sends SERVER_DENIED_CONNECTION
2017-09-18 17:29:16 +02:00
Armin Novak
e455cc1745
Fixed SSL error checks in transport_ssl_cb
...
Fix error define use. The callback is called from
ssl3_dispatch_alert or dtls1_dispatch_alert where the alert define
is left shifted by 8. Additionally ignore close notifcation. (#3814 )
2017-03-01 10:46:00 +01:00
akallabeth
7ce1dd0a6c
Merge pull request #3791 from akallabeth/kerberos
...
Kerberos (Rebased #3417 )
2017-02-23 13:46:34 +01:00
Armin Novak
b905e0c26d
Fixed initialisation of kerberos context.
2017-02-23 11:06:47 +01:00
Armin Novak
70baa6fe26
Added additional connect errors.
2017-02-22 09:50:59 +01:00
Armin Novak
363109c581
Using preloaded logger.
2017-02-22 09:42:56 +01:00
Armin Novak
1497b5654e
Using SSL defines instead of magic numbers.
2017-02-22 09:34:20 +01:00
Armin Novak
50cd702a15
Updated KRB5 detection, added error case handler
...
* Linking against KRB5 library now, no dynamic usage.
* Added proper CMake detection script for KRB5 detection
* Added some additional error conditions.
2017-02-21 10:54:34 +01:00
HenryJacques
56c0219907
Update transport.c
2017-02-20 16:04:33 +01:00
Armin Novak
c249705085
Fixed scanbuild warnings.
2017-02-20 13:45:19 +01:00