Bernhard Miklautz
6e63c6afd9
fix channel/smartcard: remove status mappings
...
The state tracking/modifications (presumably thought as optimization?!) in
PCSC_SCardGetStatusChange_Internal cause a lot of applications to behave
incorrectly and/or hang. Ideally no modifications of the states should
be necessary as PCSC implements the same API as passed over the channel.
2017-12-13 17:04:06 +01:00
Armin Novak
4eb5b8e349
Replaced atoi
2017-11-15 15:52:16 +01:00
Armin Novak
0490aeb018
Fixed clang malloc integer overflow warnings.
2017-07-20 09:29:48 +02:00
dodo040
2f22e679e0
fix format code
2017-07-19 13:16:08 +02:00
dodo040
4e055453ab
fix smartcard argument parsing
2017-07-19 13:16:08 +02:00
dodo040
722e927c64
redirect specific smartcard readers
2017-07-19 13:16:08 +02:00
Andreas Schultz
d2f98261f7
smartcard: implement ListReaderGroups
...
Conflicts:
channels/smartcard/client/smartcard_operations.c
channels/smartcard/client/smartcard_pack.c
channels/smartcard/client/smartcard_pack.h
smartcard_operations: move handling of call argument into functions
The call argument was only use by static functions and was always equal
to operation->call. Remove the argument and use operation-call directly.
Also put the memory allocation and check into the same place.
Conflicts:
channels/smartcard/client/smartcard_operations.c
Updated formatting and API
2017-02-16 16:59:03 +01:00
Norbert Federa
f71b6b46e8
fix string format specifiers
...
- fixed invalid, missing or additional arguments
- removed all type casts from arguments
- added missing (void*) typecasts for %p arguments
- use inttypes defines where appropriate
2016-12-16 13:48:43 +01:00
Armin Novak
eacf2b542e
Fixed memory leaks.
2016-05-12 10:01:30 +02:00
Armin Novak
68c402ac58
Removed windows module.def files.
...
All symbols exported from libraries are declared
using *_API defines.
2016-02-29 15:18:47 +01:00
clangm
62a559ad03
fix typo
...
Pretty sure that's supposed to be __MACOSX__, not __MAXOSX__
2016-01-27 15:40:08 -07:00
Bernhard Miklautz
07417599ce
wlog: rework, cleanup and stabilize API
...
* only expose necessary functions and types in header
* don't expose appender internals
* add generic function WLog_ConfigureAppender to have the possibility
to configure appender specific settings
* detect appender availability if WLog_SetLogAppenderType or
WLog_Appender_New return FALSE or NULL respectively the appender isn't
available or the initialization failed. This is very useful for the
use with optional appenders.
* add Free to the appender interface. At the time of the Free the
appender is known and available so it can be called directly (instead
of calling the right function according to the type)
* make all appender internal function static
* all appenders return the generic wLogAppender type now. Typecasts
are internally done where necessary this abstracts the appenders more
cleanly
2015-11-09 18:25:45 +01:00
bjcollins
ac67e25007
Give unique aliases for smartcards with the same name, so that two readers do not end up with the same alias.
2015-09-02 12:11:47 -05:00
Rostislav Kondratenko
3f81ff87a6
Removing private context on hCard so that transaction will properly unlock when context is released.
2015-07-17 18:13:41 +03:00
Rostislav Kondratenko
f2863fabf5
Re-enabled PCSC-Lite transactions and fixed smartcard deinitialization so it will release all contexts to unblock calls waiting for transactions
2015-07-17 16:37:44 +03:00
Bernhard Miklautz
bf73f4e4f1
Fix unchecked strdups
...
* add missing checks
* adapt function return values where necessary
* add initial test for settings
2015-06-22 19:09:59 +02:00
Armin Novak
7403cdc60c
Added PathMakePath function.
2015-06-09 13:16:28 +02:00
David FORT
29d372480a
Take in account nfedera's review
2015-05-20 19:19:50 +02:00
Hardening
f8120919af
Add checks for some XXX_New and XXX_Add functions
...
Based on PR #2616
2015-05-18 11:28:00 +02:00
Norbert Federa
f9f59cd29b
Fix unchecked CreateDirectory calls
2015-05-07 13:28:13 +02:00
Norbert Federa
ef1fd12b15
Fix unchecked CreateEvent calls and misc fixes
...
1)
Added missing checks for CreateEvent which also required the
following related changes:
- changed freerdp_context_new API to BOOL
- changed freerdp_peer_context_new API to BOOL
- changed pRdpClientNew callback to BOOL
- changed pContextNew callback to BOOL
- changed psPeerAccepted callback to BOOL
- changed psPeerContextNew callback to BOOL
2)
Fixed lots of missing alloc and error checks in the
changed code's neighbourhood.
3)
Check freerdp_client_codecs_prepare result to avoid segfaults
caused by using non-initialized codecs.
4)
Fixed deadlocks in x11 caused by missing xf_unlock_x11() calls
in some error handlers
5)
Some fixes in thread pool:
- DEFAULT_POOL assignment did not match TP_POOL definition
- don't free the pool pointer if it points to the static DEFAULT_POOL
- added error handling and cleanup in InitializeThreadpool
2015-04-29 18:18:39 +02:00
Armin Novak
60de56e1bb
Fixed NULL dereference and double free
2015-04-16 21:56:57 +02:00
Bernhard Miklautz
a8c44f15c0
winpr: small fixes and cleanups
...
Update the pull request and integrate the latest comments and
suggestions.
* TestLibrary*: fix typo in error message
* TestPipeCreateNamedPipeOverlapped: free possibly allocated memory
* smartcard_pcsc.c: format fix
* process.c: add missing NULL check
* MessageQueue.c: delete possibly initialized critical section on error
2015-04-08 11:34:37 +02:00
Bernhard Miklautz
850de59b55
winpr: add checks for *alloc
...
Add missing checks if memory allocation was successful. Also adapt
caller(s) when possible.
2015-04-08 11:34:37 +02:00
Marc-André Moreau
cb002d91cd
channels/smartcard: fix pioRecvPci with cbExtraBytes > 0
2015-03-13 14:20:57 -04:00
Marc-André Moreau
6b6c368e3a
libwinpr-smartcard: stub new transaction system
2015-01-20 21:40:45 -05:00
Marc-André Moreau
344a1b52ca
libwinpr-smartcard: remove unused (and useless) pcsc-lite static link option
2015-01-20 20:15:10 -05:00
Marc-André Moreau
f0fc27f7bd
libwinpr-winscard: add WINPR_WINSCARD_LOCK_TRANSACTIONS environment variable, fix winpr_HexDump line feeds
2015-01-20 15:29:05 -05:00
Marc-André Moreau
73cfa920a9
libwinpr-smartcard: add SCARD_ATTR_CHANNEL_ID
2015-01-19 14:56:02 -05:00
Marc-André Moreau
51554ff16c
channels: patch rdpdr/smartcard valgrind leaks, fix hang on disconnect
2014-12-28 14:56:13 -05:00
Marc-André Moreau
9ebc67ba02
channels/smartcard: cleanup SCardControl
2014-12-22 16:25:59 -05:00
Marc-André Moreau
0625be2720
channels/smartcard: fix SCardGetAttrib SCARD_AUTOALLOCATE support
2014-12-22 13:28:16 -05:00
Vincent Sourin
719e5c9cdb
Determine OSX Version ... only on OSX
2014-12-14 15:15:33 +01:00
Vincent Sourin
8a028f78e2
* Determine OS X Version at runtime
2014-12-13 05:30:44 -08:00
Vincent Sourin
956cece54b
* Correct detection of Mac OS X Yosemite Version
2014-12-09 22:14:06 +01:00
Vincent Sourin
64ff9ee1b6
SmartCard
...
* Check for NULL parameters in PCSC_ConvertReaderNameToWinSCard (Issue #2184 )
* Remove masking of dwEventState as it is not needed under Linux and MacOSX and it helps in ThinLinc environment
* Workaround for Mac OS X Yosemite (10.10) SCardStatus Bug (Issue #2184 )
* Since Mac OS Tiger (10.5.6), Apple introduced new function for SCardControl calls named SCardControl132(), the old SCardControl doesn't work (cf. https://opensource.apple.com/source/SmartCardServices/SmartCardServices-55111/src/PCSC/winscard_clnt.c )
2014-12-09 20:14:57 +01:00
Armin Novak
55e455f1ab
Fixed memory leaks.
2014-11-16 22:50:50 +01:00
Armin Novak
b7d5bf49f8
Fixed NULL pointer dereference.
2014-11-16 16:53:55 +01:00
Marc-André Moreau
367ceff02c
libwinpr-smartcard: revert minor change from pull request #2195
2014-11-11 12:00:37 -05:00
Marc-André Moreau
d4bdf52b07
libwinpr-smartcard: re-enable SCardGetStatusChange status filtering
2014-11-11 11:46:59 -05:00
Vinche
d427faf5c6
Cleaning Code
2014-11-10 23:51:34 +01:00
Vinche
fdb95c712b
Implementation for Smartcard Reader with Pin Pad
2014-11-10 23:40:22 +01:00
Vinche
69766de29f
Add comments to modifications
2014-11-09 23:02:12 +01:00
Vinche
bbff8db75f
Add comments to modifications
2014-11-09 23:00:41 +01:00
Vinche
2708a8de5c
first commit
2014-11-09 22:42:35 +01:00
Marc-André Moreau
83ecddd6c1
xfreerdp: replace cliprdr to wire format conversion
2014-10-17 20:40:11 -04:00
Marc-André Moreau
334dec3c1f
winpr: add pragma pack, bitmap + clipboard definitions
2014-10-16 21:45:47 -04:00
Armin Novak
a15df299e9
Removed last remainig printf.
2014-09-09 16:32:23 +02:00
Armin Novak
b22b897389
Reformatted changed files.
2014-09-09 16:32:22 +02:00
Armin Novak
7e3a1b3073
Now using macro to generate module specific log tag.
2014-09-09 16:32:04 +02:00
Armin Novak
28ece6bb46
Replaced stdio logging with WLog
2014-09-09 16:31:46 +02:00
Armin Novak
ad3255354d
Added WITH_LIBRARY_VERSIONING, allowing to build shared libraries without
...
SOVERSION information. (required by Android)
2014-07-11 11:53:58 +02:00
Bernhard Miklautz
6a49bcfe40
winpr: always build "monolitic"
...
winpr is now always build as single library.
The build option MONOLITHIC_BUILD doesn't influence this behavior anymore.
The only exception is winpr-makecert-tool which is still build as extra
library.
This obsoletes complex_libraries for winpr.
2014-07-10 11:10:58 +02:00
Marc-André Moreau
659f80e172
libwinpr-smartcard: avoid using pcsc-lite's buggy transaction system
2014-06-02 21:49:49 -04:00
Marc-André Moreau
f5bfb98aca
channels/smartcard: experiment with multiple card contexts
2014-06-02 17:20:01 -04:00
Mike McDonald
ed8ea297e7
Modified SCardConnect/SCardDisconnect logic to prevent more than one card from being connected to a context. Trying to connect more than once to a context without doing a disconnect can cause a deadlock in the pcsclite daemon (pcscd).
2014-06-02 11:08:32 -04:00
Marc-André Moreau
af6fb83d3b
libwinpr-utils: extend wlog prefix format
2014-05-28 10:38:32 -04:00
Marc-André Moreau
ba5d84ee5c
libwinpr-smartcard: add logging for each calls in smartcard inspector
2014-05-26 17:54:39 -04:00
Marc-André Moreau
b6a8767b71
libwinpr-smartcard: start smartcard API inspector
2014-05-26 15:57:37 -04:00
Marc-André Moreau
003870157a
libwinpr-smartcard: remove some locks
2014-05-12 17:28:35 -04:00
Marc-André Moreau
2da6111972
channels/smartcard: fix clearing of rgSCardContextList
2014-05-12 10:17:49 -04:00
Marc-André Moreau
ae6c778eb7
libwinpr-smartcard: modifying threading
2014-05-11 05:23:30 -04:00
Marc-André Moreau
fda492c58d
libwinpr-smartcard: fix AccessStartedEvent
2014-05-11 01:53:47 -04:00
Marc-André Moreau
d04430cb02
channels/smartcard: implement usage of SCardAccessStartedEvent
2014-05-10 23:43:25 -04:00
Marc-André Moreau
ad9f73350e
libwinpr-smartcard: fix cmake script
2014-05-10 00:50:30 -04:00
Marc-André Moreau
fb3662c7e2
winpr: fix ranlib missing symbols warnings on OS X
2014-05-09 22:44:19 -04:00
Marc-André Moreau
b3114ff4d8
channels/smartcard: improve debug output, fix GetStatusChange SCARD_E_CANCELLED, fix SCardGetAttrib current protocol type
2014-05-06 10:00:44 -07:00
Marc-André Moreau
38c77eb57c
libwinpr-smartcard: fix SCardGetAttrib for friendly name (unicode)
2014-05-05 17:27:29 -04:00
Marc-André Moreau
9e407e6e22
libwinpr-smartcard: start handling SCardControl control code conversions
2014-05-03 19:02:17 -04:00
Marc-André Moreau
b51da6c6f4
libwinpr-smartcard: improve SCardGetAttrib, fix null SCARDCONTEXT usage in SCardListReaders
2014-05-03 17:07:30 -04:00
Marc-André Moreau
86b018ee21
libwinpr-smartcard: fix pcsc-lite SCARD_IO_REQUEST incompatibility
2014-05-03 14:20:17 -04:00
Marc-André Moreau
cd7e3151cd
libwinpr-smartcard: fix PCSC incompatible type definitions
2014-05-03 13:49:50 -04:00
Marc-André Moreau
32de7b6a77
libwinpr-smartcard: fix failing unit test
2014-04-27 22:23:42 -04:00
Marc-André Moreau
b1c0a68f55
client/common: honor RedirectSmartCards, RedirectPrinters
2014-04-27 21:29:44 -04:00
Marc-André Moreau
c9a223a06b
libwinpr-smartcard: return SCARD_NO_SERVICE when no internal callback is registered
2014-04-27 20:11:31 -04:00
Marc-André Moreau
5db851a154
libwinpr-smartcard: update PCSC-WinPR instructions (WIP)
2014-04-27 17:38:45 -04:00
Marc-André Moreau
103b7d4151
libwinpr-smartcard: fix workaround for lack of PnP Notification support on OS X
2014-04-27 16:43:09 -04:00
Marc-André Moreau
769502ec72
Merge branch 'master' of github.com:FreeRDP/FreeRDP
2014-04-26 13:47:01 -04:00
Marc-André Moreau
cee67b9c5f
libwinpr-smartcard: improve pcsc-lite wrapper robustness
2014-04-25 19:26:55 -07:00
Marc-André Moreau
237eb6140a
libwinpr-smartcard: fix for pcsc-lite SCardGetStatusChange
2014-04-25 20:07:29 -04:00
Marc-André Moreau
746e8a6929
libwinpr-smartcard: fix usage of native data types
2014-04-25 18:49:57 -04:00
Bernhard Miklautz
b817e92e5e
cmake: mark required libraries for export
2014-04-23 10:16:02 +02:00
Marc-André Moreau
19b9ed3bb0
channels/smartcard: some Mac OS X fixes
2014-04-16 14:03:22 -04:00
Marc-André Moreau
77a50401a7
channels/smartcard: fix autoallocate wrapper
2014-04-15 18:45:38 -04:00
Marc-André Moreau
6d7f3cd00c
libwinpr-smartcard: fix SCardGetAttrib SCARD_ATTR_CURRENT_PROTOCOL_TYPE
2014-04-15 18:01:26 -04:00
Marc-André Moreau
fc885dc4b7
libwinpr-smartcard: fix SCardGetAttrib
2014-04-15 17:51:39 -04:00
Marc-André Moreau
a675800d68
channels/smartcard: fix multi-line handling
2014-04-15 16:48:25 -04:00
Marc-André Moreau
38d05b48a0
channels/smartcard: fix reader name aliasing
2014-04-15 13:49:52 -04:00
Marc-André Moreau
62481e83ee
channels/smartcard: add more debug output
2014-04-13 16:48:32 -04:00
Marc-André Moreau
d699128a57
channels/smartcard: add more debug output
2014-04-13 15:50:51 -04:00
Marc-André Moreau
9afe63aa76
libwinpr-smartcard: improve GetStatusChange
2014-04-13 00:43:12 -04:00
Marc-André Moreau
a352044c7a
libwinpr-smartcard: implement PCSC/WinSCard reader name aliasing
2014-04-12 23:38:15 -04:00
Marc-André Moreau
2f3c3c4bb1
channels/smartcard: add pcsc-lite protocol value mapping
2014-04-12 18:13:18 -04:00
Marc-André Moreau
1d864fe9af
channels/smartcard: make PCSC implementation even closer to WinSCard
2014-04-12 16:45:06 -04:00
Marc-André Moreau
7ff1c984c2
channels/smartcard: add more debug output, make distinction between reader and card state
2014-04-12 14:31:54 -04:00
Marc-André Moreau
fd6052f348
channels/smartcard: add more debug output
2014-04-12 12:42:09 -04:00
Marc-André Moreau
ee9f44ce5a
libwinpr-smartcard: fix SCardConnectW deadlock
2014-04-12 12:15:04 -04:00
Marc-André Moreau
c106b62920
libwinpr-smartcard: fix deadlock in PCSC_SCardFreeMemory
2014-04-12 11:24:47 -04:00
Marc-André Moreau
727a4914f2
channels/smartcard: add more debug output
2014-04-11 18:57:04 -04:00
Marc-André Moreau
79453d1bb4
channels/smartcard: make handles completely opaque
2014-04-11 16:27:01 -04:00