1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

scd: New option --pcsc-shared.

* scd/scdaemon.h (opt): Add field opcsc_shared.
* scd/scdaemon.c (opcscShared): New.
(opts): Add "--pcsc-shared".
(main): Set flag.
* scd/apdu.c (connect_pcsc_card): Use it.
(pcsc_get_status): Take flag in account.
* scd/app-openpgp.c (verify_chv2): Do not auto verify chv1 in shared
mode.
--

This option should in general not be used.  The patch tries to limit
bad effects but using shared mode is somewhat dangerous depending on
the other PC/SC users.

(cherry picked from commit 5732e7a8e9)
This commit is contained in:
Werner Koch 2021-03-12 09:21:57 +01:00
parent 96577e2e46
commit 5eec40f3d8
No known key found for this signature in database
GPG key ID: E3FDFF218E45B72B
5 changed files with 14 additions and 3 deletions

View file

@ -2397,7 +2397,7 @@ verify_chv2 (app_t app,
return rc;
app->did_chv2 = 1;
if (!app->did_chv1 && !app->force_chv1 && pinvalue)
if (!app->did_chv1 && !app->force_chv1 && pinvalue && !opt.pcsc_shared)
{
/* For convenience we verify CHV1 here too. We do this only if
the card is not configured to require a verification before