Re: High CPU load with pcscd and Kerkey security Module

Ludovic Rousseau <[email protected]> Tue, 22 Nov 2016 18:32:43 +0100
Newsgroups gmane.comp.lib.muscle
Message-ID <CAGstE8DyBDsGjow1__HVYemZ-AXfpwdoo9=CQrEx8G6MVwNvsA@mail.gmail.com>
2016-11-22 17:41 GMT+01:00 Oliver Graute <[email protected]>:
>
> The load is high the first 5-10 min after booting of our system.
> In this time we start two instances of apache webserver and our
> application. Then its settle down and spike up if a TLS session
> is build up. The TLS Handshake always causes a bit load on
> pcscd and the Kerkey SM. With one TLS session its usable
> but not with more.
>
> I don't understand why so many SCardStatus operations and
> SCardTransmit are needed and where their come from.
> Probably their caused from the closed ST Kerkey lib or above
> from mod_nss or nss.

The high number of SCardTransmit() calls is not really surprising for me.

The driver should just wait after the "card" to respond. Maybe the
/usr/lib/pcsc/drivers/kerkey/libccidkerkey.so driver is not efficient
and uses busy loops or other CPU intensive code.
I guess you do not have the source code of this part either?

Bye

-- 
 Dr. Ludovic Rousseau