[Pcsclite-muscle] index in PC/SC lite reader names may change
Sebastien Lorquet
sebastien at lorquet.fr
Wed May 13 01:14:33 PDT 2026
Hello,
I suggest that nothing is made to change how readers are named and numbered.
Unplugging/replugging a badly behaved reader is a very common operation,
and if that mundane operation changes the reader name it could lead to a
lot of unexpected breakage.
Is this change absolutely required?
Thanks,
Sebastien
On 5/11/26 16:14, Ludovic Rousseau wrote:
> Hello,
>
> I am working on a potential change to pcsc-lite and I would like to
> get your feedback on it.
> What do you think about making the number in the reader name cycle
> instead of always restarting at 0?
>
> Currently, the PC/SC reader names are something like this (for 2
> connected readers):
> "reader A 00 00"
> "reader B 01 00"
>
> The first number is the reader "index".
> The second number is the slot index (for mutti-slot readers)
> See "What is in a PC/SC reader name?"
> https://blog.apdu.fr/posts/2010/05/what-is-in-pcsc-reader-name/ for
> more details.
>
> If "reader A" is unplugged and plugged in again, it will be named
> "reader A 00 00" again.
>
> My proposal is to name the reader "reader A 02 00" instead (or
> whatever the next available number is).
> After 99 readers have been plugged in, we go back to number 00 (if available).
>
> The number in the reader name should NOT be interpreted by the
> application. Therefore, the proposed change should not break existing
> code.
> However, I know that developers can be very creative when using APIs
> and undocumented behaviours :-)
>
> Do you foresee any problems with my proposal?
> Any comments?
>
> Thanks
>
More information about the pcsclite-muscle
mailing list