[Pcsclite-muscle] How to find out which process is accessing the card?

Ludovic Rousseau ludovic.rousseau
Tue Oct 24 04:32:34 PDT 2017


2017-10-24 10:28 GMT+02:00 Franti?ek ?ez?? <frantisek.rezac at calavera.info>:

> I was surprised by your solution based on proc/maps, I expected something
> more specific to the pcsc stack, but I gave it a try and I think I have
> found what I'm looking for. But it wasn't straightforward so I'm sending
> some notes back.
>
> Most importantly I was surprised how many processes are running with pcsc
> lib all the time. For example I definitely wasn't expecting wpasupplicant.
>

wpasupplicant has support of EAP-SIM authentication scheme. To read the SIM
card it needs to use PC/SC.

Those processes however were not accessing smart card at all so I had to
> conduct a better analysis looking at those processes found by your tool for
> a longer time and I found a behavior pattern which pointed to the final
> offender (gdm-session-worker). So although it wasn't as simple as I would
> like, your tool helped a lot, thanks.
>

libpcsclite can be loaded by a chain of library. My tool [1] will only give
you the name of the process.
I don't think it it possible to tell which library loaded libpcsclite.so.1
just at looking at the /proc/*/maps files.

I am happy my (simple) tool helped you.

Bye

[1]
https://github.com/LudovicRousseau/contrib/blob/master/list_pcsc_applications.sh

-- 
 Dr. Ludovic Rousseau
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pcsclite-muscle/attachments/20171024/7e6b1da7/attachment.html>



More information about the pcsclite-muscle mailing list