Commit Graph

1917 Commits

Author SHA1 Message Date
Karl Mikaelsson
3abeca252b Log system pointer changes via Fast-Path updates 2017-10-13 14:02:03 +02:00
Karl Mikaelsson
72f63d04ec Decipher remaining capabilitysets sent from rdesktop 2017-10-13 14:02:03 +02:00
Karl Mikaelsson
9ca206bc08 Clarify order and bitmap capability set functions 2017-10-13 14:02:03 +02:00
Karl Mikaelsson
3b0a0c1334 Improve rdp_out_general_caps
Rename to rdp_out_ts_general_capabilityset to match the structure
name, describe all fields and use constants instead of magic numbers.
2017-10-13 14:02:03 +02:00
Karl Mikaelsson
e669be67fe Merge pull request #167 from derfian/avoid-smart-card-error-log-entries
Move more Smart Card error messages to the debug level
2017-10-12 10:07:45 +02:00
Karl Mikaelsson
cebd4ad016 Move all Smart Card error messages to the debug level
Running rdesktop with smart card redirection could lead to scenarios
where rdesktop keeps producing error messages about the Smart Card
redirection when there isn't really an error. I don't believe that we
should log an error if the underlying PC/SC interface reports
SCARD_E_NO_SERVICE.

The logged information could be useful for developers in debugging
scenarios, so I'm keeping is as Debug rather than removing it
outright.
2017-10-11 17:24:46 +02:00
Karl Mikaelsson
ae31a05f22 Let Travis build with both GCC and clang, take 2
Last approach didn't work, hopefully this will work better.
2017-10-06 12:54:11 +02:00
Karl Mikaelsson
eb975fcec3 Let Travis compile with both gcc and clang
Catch all the compilation warnings!
2017-10-06 12:44:48 +02:00
Henrik Andersson
43a5f3f054 Merge pull request #166 from uglym8/add_osx_to_travis
Add osx support for Travis CI build
2017-10-06 11:15:14 +02:00
Alexander Zakharov
168566109c Add osx support for Travis CI 2017-10-06 12:06:57 +03:00
Henrik Andersson
ed7e43818f Merge pull request #158 from derfian/maybe-better-audio-sync
rdpsnd_process_ping: include actual packsize value in reply
2017-10-06 10:36:06 +02:00
Henrik Andersson
41b8e1ce06 Merge pull request #160 from derfian/remove-make-proto
Remove infrastructure to auto-generate proto.h
2017-10-06 10:35:36 +02:00
Henrik Andersson
b37122330a Merge pull request #159 from derfian/audio-refactoring-to-spec
Audio refactoring to spec
2017-10-06 10:35:05 +02:00
Henrik Andersson
df038988b6 Merge pull request #162 from uglym8/fix_osx_build
Fix osx build
2017-10-06 09:40:09 +02:00
Alexander Zakharov
ed3726a9fa Handle the lack of SCARD_CTL_CODE on Mac 2017-10-05 19:47:59 +03:00
Alexander Zakharov
f091a38cff Sane way to fix absence of HOST_NAME_MAX on osx 2017-10-05 19:47:50 +03:00
Alexander Zakharov
b71d79cdb1 Add support for Kerberos on Mac 2017-10-05 19:45:03 +03:00
Karl Mikaelsson
1f13c85583 Remove infrastructure to auto-generate proto.h
If proto.h is supposed to be auto-generated it should probably not be
present in the repo at all. Re-running cproto showed that proto.h has
been manually edited for quite some time, so this just makes this the
only workflow.

It also gets rid of a bit of #ifdefs, so that's nice.
2017-10-05 15:18:13 +02:00
Karl Mikaelsson
8316b346e8 Remove accidental packsize reference
This was work done on another branch that got included here by
mistake.
2017-10-05 15:02:01 +02:00
Karl Mikaelsson
e48f947794 Include selected sound driver in the verbose output
This could be somewhat useful for troubleshooting audio, so burying it
in the debug log output is unhelpful.
2017-10-05 14:41:25 +02:00
Karl Mikaelsson
329289ff6c Don't log an error on new audio format handshakes
This happens regularly and it's not an error. An easy way to trigger
this scenario is to let cmd.exe produce a bell sound by tab-completing
something non-existant.
2017-10-05 14:41:25 +02:00
Karl Mikaelsson
7870ef6f86 Refactor rdpsnd to follow to the MS-RDPEA specs more closely
Rename functions and change the constants to match the specification.
2017-10-05 14:41:25 +02:00
Karl Mikaelsson
8cb6bf4e95 rdpsnd_process_ping: include actual packsize value in reply
The rdpsnd_process_ping function did not conform to the MS-RDPEA spec
by leaving out the packsize in the reply. The MS-RDPEA spec is rather
clear that this needs to be the same value as received in the training
request.

I think I'm seeing a slight improvement in audio sync after this
change.
2017-10-05 14:29:44 +02:00
Henrik Andersson
db8b56db44 Merge pull request #156 from derfian/smart-card-logging
Don't log common Smart Card error codes as rdesktop errors
2017-10-05 10:55:30 +02:00
Henrik Andersson
12b28b83d7 Merge pull request #155 from samhed/disconnectreasons
Handle more disconnect reasons
2017-10-05 10:53:43 +02:00
Samuel Mannehed
b89a5899f0 Update man-page with new return codes/texts 2017-10-05 10:45:54 +02:00
Henrik Andersson
0a3a6fbca8 Merge pull request #154 from derfian/fix-disk-logging
Move logging code to after variable declarations
2017-10-05 07:19:55 +02:00
Karl Mikaelsson
dca441c4e6 Don't log warnings/errors from TS_SCardGetStatusChange at all
Not sure why I thought the user needed to see this at all.
2017-10-04 17:11:02 +02:00
Samuel Mannehed
b0813fa275 Add handling for a few special RDP error codes
Most of the RPD protocol errors (reason > 0x1000) would only be
triggered by coding errors in the client. A few of them can occur due
to server errors however. We should attempt to handle these cases.
2017-10-04 16:27:34 +02:00
Samuel Mannehed
e8562507e7 Add handling for connection broker error codes 2017-10-04 15:51:36 +02:00
Samuel Mannehed
e272feaa8a Print the reason code for protocol errors 2017-10-04 15:50:49 +02:00
Karl Mikaelsson
96faa24bd5 Don't log common Smart Card error codes as rdesktop errors
The proper thing to do would be to forward the errors to the server
and let it deal with it. No need to present these as errors to the
user.
2017-10-04 15:20:46 +02:00
Samuel Mannehed
2e744bf54f Indent rdesktop exit codes 2017-10-04 13:21:57 +02:00
Samuel Mannehed
dfad103fd9 Tweak wording of disconnect reason messages
They are now a bit more specific and better match the description of
the disconnection reasons sent by the server.
2017-10-04 12:36:59 +02:00
Samuel Mannehed
3aca74880a Fix specific admin/user disconnect/logout codes
There seems to have been confusion with regards to which exit code and
message was returned by rdesktop for the following cases:

* disconnected by admin
* logged out by admin
* disconnect by user
* logoff by user

Looking at Microsoft's official documentation as well as testing using
Windows Server 2008 R2, 2012 R2 and 2016 reveals that this commit fixes
this issue. They do now match the reasons sent by the server.
2017-10-04 12:32:42 +02:00
Samuel Mannehed
a6a2120cf7 Rename constants for disconnect reasons
To make them easier to search for - let's match the names with the
corresponding names on the server side:

https://msdn.microsoft.com/en-us/library/cc240544.aspx
2017-10-04 09:35:14 +02:00
Karl Mikaelsson
1a026814a5 Move logging code to after variable declarations 2017-10-03 11:07:32 +02:00
Henrik Andersson
594438e5eb Make deprecated rdp_out_unistr() static 2017-09-29 16:30:17 +02:00
Henrik Andersson
ff1a42f809 Refactor of writing utf16 strings to packets.
This remove the use of deprecated rdp_out_unistr() and
uses correct string length instead of assumition that all
utf16 symbols are represented by 2 bytes.
2017-09-29 16:30:17 +02:00
Henrik Andersson
995e830665 Use new out_utf16s_padded() string function for fixed string 2017-09-29 16:30:17 +02:00
Henrik Andersson
791906e45d Add function to write fixed length utf16 string to stream 2017-09-29 16:30:17 +02:00
Henrik Andersson
e195953496 Refactor of writing utf16 strings to packets.
This remove the use of deprecated rdp_out_unistr() and
some minor cleanups.
2017-09-29 16:30:17 +02:00
Henrik Andersson
e35a76bce2 Refactor writing of utf16 strings into packets
The old code was filled by assumtions that all symbols in utf16
is represented by 2 bytes which is not true and resulted in
truncated strings.

Fixes issue #60
2017-09-29 14:25:41 +02:00
Henrik Andersson
de8fe9429f Add two new stream functions for writing utf16 strings
This is the first steps of removing the old rdp_out_unistr() and
using clearer code.
2017-09-29 14:24:27 +02:00
Henrik Andersson
b8fe3e9315 Rename parse to stream 2017-09-29 11:13:02 +02:00
Henrik Andersson
fc6ce03875 Make use of shared stream api
Remove own componized realloc and reset code to
shared stream api implementation.
2017-09-28 19:15:00 +02:00
Henrik Andersson
4cbfda90fd Move static stream helper functions to parse.c 2017-09-28 19:12:11 +02:00
Henrik Andersson
0954ac3ca5 Some cursors are hard to see on dark background
The new cursor rendering code that was added will render
1bpp XOR cursors as plain black cursors. This introduces
a problem were the cursor is not visible on dark backgrounds.
This change adds a white outlined rendering of the shape to
those specific cursors.
2017-09-27 13:49:33 +02:00
Henrik Andersson
96cf016028 Add sound backend dependencies
to get a bigger compile coverage
2017-09-26 16:26:04 +02:00
Henrik Andersson
9b98c3b229 Add support for pulseaudio backend
This work is done by Nikita Krupenko which sent a patch to
rdesktop in 2010 for version 1.6.0. I have now ported it
over to trunk and it seems to work as expected.
2017-09-26 15:07:14 +02:00