Home GnuPG
Diffusion GnuPG f7e00dc73dd0

scd: On a Yubikey re-select the last app after the use of APDU.

Description

scd: On a Yubikey re-select the last app after the use of APDU.

* scd/app-common.h (struct card_ctx_s): Add maybe_check_aid flag.
* scd/command.c (cmd_apdu): Set it.
* scd/app.c (check_external_interference): Consult this flag.
(maybe_switch_app): Do a re-select if this flag is set.

After the gpg-card tool has issued a Yubikey specific command the
current application is not anymore correctly selected. This then
results in all kind of errors. We detect this now and try to
re-select the last app.

Details

Provenance
wernerAuthored on Apr 18 2023, 12:04 PM
Parents
rG98b8c518fa0b: ssh: Allow to prefer on-disk keys over active card keys.
Branches
Unknown
Tags
Unknown