1. 25 Mar, 2019 1 commit
  2. 24 Mar, 2019 1 commit
  3. 22 Mar, 2019 2 commits
  4. 16 Jan, 2019 1 commit
    • Ludovic Rousseau's avatar
      Doc: more explicit documentation for −−auto−exit · e641eaa7
      Ludovic Rousseau authored
      pcscd does not exit after 60 seconds but after 60 seconds of inactivity
      after the release of the last PC/SC context.
      If you start pcscd with −−auto−exit but do run any PC/SC application
      then pcscd will NOT exit after 60 seconds.
      
      Thanks to Matthias Apitz for the bug report.
      e641eaa7
  5. 14 Jan, 2019 2 commits
    • vegaMato's avatar
      Remove usage of function chmod(2) to use fchmod(2) · 36c8eae8
      vegaMato authored
      Race condition possibility; CWE-362: Concurrent Execution using Shared
      Resource with Improper Synchronization ('Race Condition')
      
      Thanks to PA193 project
      https://github.com/vegaMato/PCSC-lite-project-tasks
      36c8eae8
    • St4lkerino's avatar
      Fix realloc(3) error handling · 43004384
      St4lkerino authored
      From realloc(3) manpage:
             The realloc() function returns a pointer to the newly allocated memory,
             which  is  suitably  aligned for any built-in type and may be different
             from ptr, or NULL if the request fails.  If size was equal to 0, either
             NULL  or  a  pointer  suitable  to be passed to free() is returned.  If
             realloc() fails, the original block is left untouched; it is not  freed
             or moved.
      
      If realloc() fails then the memory that was previously allocated needs
      to be freed, or it will create a memory leak.
      
      It was not a real problem because if realloc(3) failed then pcscd would
      exit immediatly and the memory would not leak for a long time.
      
      Thanks to PA193 project
      https://github.com/vegaMato/PCSC-lite-project-tasks
      43004384
  6. 03 Jan, 2019 1 commit
  7. 15 Dec, 2018 1 commit
  8. 12 Dec, 2018 1 commit
  9. 07 Dec, 2018 1 commit
  10. 26 Nov, 2018 1 commit
    • Ludovic Rousseau's avatar
      MSGRemoveContext: remove dead code · 53ab2bc8
      Ludovic Rousseau authored
      Issue found by Coverity:
      >>>     CID 1441490:  Code maintainability issues  (UNUSED_VALUE)
      >>>     Assigning value "2148532329L" to "rv" here, but that stored value is overwritten before it can be used.
      53ab2bc8
  11. 15 Nov, 2018 1 commit
  12. 12 Oct, 2018 5 commits
    • Ludovic Rousseau's avatar
      Release 1.8.23 · 73d95ada
      Ludovic Rousseau authored
      73d95ada
    • Ludovic Rousseau's avatar
      Fix compiler warning: output may be truncated · eaaf8eda
      Ludovic Rousseau authored
      winscard_msg.c: In function ‘ClientSetupSession’:
      winscard_msg.c:134:2: warning: ‘strncpy’ output may be truncated copying 108 bytes from a string of length 109 [-Wstringop-truncation]
        strncpy(svc_addr.sun_path, socketName, sizeof(svc_addr.sun_path));
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      
      The source was sizeof(struct sockaddr_un) bytes long.
      But the destination was sizeof(svc_addr.sun_path) bytes long only.
      
      svc_addr is a struct sockaddr_un but the sun_path field is shorter (1
      byte shorter according to the compiler) than the complete struct
      sockaddr_un.
      eaaf8eda
    • Ludovic Rousseau's avatar
      Fix compiler warning: cast between incompatible function · 2bef0948
      Ludovic Rousseau authored
      hotplug_libudev.c: In function ‘HPRegisterForHotplugEvents’:
      hotplug_libudev.c:769:3: warning: cast between incompatible function types from ‘void (*)(void *)’ to ‘void * (*)(void *)’ [-Wcast-function-type]
         (PCSCLITE_THREAD_FUNCTION( )) HPEstablishUSBNotifications, udev_monitor))
         ^
      2bef0948
    • Ludovic Rousseau's avatar
      Fix compiler warning: cast between incompatible function · 3c80087b
      Ludovic Rousseau authored
      eventhandler.c: In function ‘EHSpawnEventHandler’:
      eventhandler.c:234:3: warning: cast between incompatible function types from ‘void (*)(READER_CONTEXT *)’ {aka ‘void (*)(struct ReaderContext *)’} to ‘void * (*)(void *)’ [-Wcast-function-type]
         (PCSCLITE_THREAD_FUNCTION( ))EHStatusHandlerThread, (LPVOID) rContext);
         ^
      3c80087b
    • Ludovic Rousseau's avatar
      Fix compiler warning: cast between incompatible function · d6ba979b
      Ludovic Rousseau authored
      winscard_svc.c: In function ‘CreateContextThread’:
      winscard_svc.c:237:3: warning: cast between incompatible function types from ‘void (*)(void *)’ to ‘void * (*)(void *)’ [-Wcast-function-type]
         (PCSCLITE_THREAD_FUNCTION( )) ContextThread, (LPVOID) newContext);
         ^
      d6ba979b
  13. 09 Oct, 2018 1 commit
  14. 08 Oct, 2018 3 commits
  15. 04 Oct, 2018 3 commits
  16. 02 Oct, 2018 2 commits
  17. 15 Sep, 2018 1 commit
  18. 27 Jul, 2018 3 commits
    • Ludovic Rousseau's avatar
      Fix compiler warning: missing field 'rv' initializer · ded26af3
      Ludovic Rousseau authored
      winscard_svc.c:814:44: warning: missing field 'rv' initializer
            [-Wmissing-field-initializers]
              struct wait_reader_state_change waStr = {0};
                                                        ^
      ded26af3
    • Ludovic Rousseau's avatar
      Fix compiler warning missing field 'rv' initializer · e632d595
      Ludovic Rousseau authored
      winscard_svc.c:428:47: warning: missing field 'rv' initializer
            [-Wmissing-field-initializers]
                                      struct wait_reader_state_change waStr = {0};
      e632d595
    • Ludovic Rousseau's avatar
      Fix SCardGetStatusChange() broken in a previous patch 984f84df · 54224a4c
      Ludovic Rousseau authored
      The patch in 984f84df broke the
      execution of SCardGetStatusChange() when SCardCancel() is used.
      
      The client was waiting for a message that was never sent by the server.
      
      Fortunately the broken code was never released in a stable version of
      pcsc-lite.
      
      Thanks to Sam Van Den Berge for the bug report
      "[Pcsclite-muscle] SCardCancel broken"
      http://lists.infradead.org/pipermail/pcsclite-muscle/2018-July/001096.html
      
      Hello,
      
      It seems like SCardGetStatusChange is currently broken.
      This can be tested with UnitaryTests/SCardCancel.
      
      Before commit 984f84df:
      
      $ LD_LIBRARY_PATH=../src/.libs/ ./SCardCancel
      SCardEstablishContext:[0x00000000] Command successful.
      Press Enter to cancel within 3 seconds
      Entering blocking call
      
      Calling SCardCancel...
      SCardGetStatusChange:[0x80100002] Command cancelled.
      Blocking call canceled
      Good
      SCardCancel:[0x00000000] Command successful.
      SCardReleaseContext:[0x00000000] Command successful.
      Waiting thread...
      
      After commit 984f84df:
      
      $ LD_LIBRARY_PATH=../src/.libs/ ./SCardCancel
      SCardEstablishContext:[0x00000000] Command successful.
      Press Enter to cancel within 3 seconds
      Entering blocking call
      
      Calling SCardCancel...
      SCardCancel:[0x00000000] Command successful.
      
      <<<<<<<<< SCardGetStatusChange hangs here >>>>>>>>>
      
      I don't have a fix but I just wanted to report this. Besides this big
      thank you for all your great work!
      
      Kr,
      Sam.
      54224a4c
  19. 29 Jun, 2018 5 commits
    • Ludovic Rousseau's avatar
      Doxygen: documentation moved to pcsclite.apdu.fr · ddf72587
      Ludovic Rousseau authored
      Update the update.sh script to update the Doxygen documentation pages.
      ddf72587
    • Ludovic Rousseau's avatar
      Allow "=" in serial driver filenames · 01677078
      Ludovic Rousseau authored
      For example the configuration:
      LIBPATH       /tmp/lib/pcsc/drivers/lib=ccid.dylib
      failed with:
      00000057 configfile.l:165:evaluatetoken() Error with library /tmp/lib/pcsc/drivers/lib: No such file or directory
      
      The problem was detected on Android 8.0 with file names such as:
      /data/app/com.baimobile.android.enterprise.credential.service-4wM9GBtoaS74ZiA0Y25YuQ==/lib/arm64/lib_some_reader_driver.so
      
      Thanks to Alan Kozlay for the bug report and patch.
      01677078
    • Ludovic Rousseau's avatar
      Doxygen: fix warning · 08664ae6
      Ludovic Rousseau authored
      PCSC/src/PCSC/ifdhandler.h:84: warning: Unsupported xml/html tag
      <string> found
      08664ae6
    • Ludovic Rousseau's avatar
      Doxygen: do not document disabled functions · d412c4bb
      Ludovic Rousseau authored
      If USE_LIBSYSTEMD is not defined then ListenExistingSocket() is not
      implemented and the associated Doxygen documentation should not be
      present.
      
      Fix Doxygen warning:
      PCSC/src/winscard_msg_srv.c:193: warning: argument 'fd' of command @param is not found in the argument list of ProcessEventsServer(uint32_t *pdwClientID)
      d412c4bb
    • Ludovic Rousseau's avatar
      Doxygen: Use " " for FRIENDLYNAME · e4f50dc1
      Ludovic Rousseau authored
      The FRIENDLYNAME declaration for reader.conf files must use " " if space
      characters are present in the name.
      e4f50dc1
  20. 28 May, 2018 1 commit
  21. 21 May, 2018 3 commits