Home GnuPG
Diffusion GnuPG 9e3b7e26a9f9

scd:openpgp: Small speedup reading card properties.

Description

scd:openpgp: Small speedup reading card properties.

* scd/app-openpgp.c (struct app_local_s): Add new flag.
(get_cached_data): Force chace use if flag is set.
(app_select_openpgp): Avoid reading DO 6E multiple times.

The do not cache property of 6E was introduced so that we can change
for example key attributes without getting into with the cache.
However, for initial reading the cache makes a lot of sense and thus we
now use this hack to only temporary cache. A better strategy would be
to clear the cache when we change card data but that is more error
prone.

(cherry picked from commit d5fb5983232cf4d60cf6aa00d0ae5a16cf948e19)

  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Mar 19 2021, 1:43 PM
Parents
rG57bfad2c39f5: scd:openpgp: Allow reading and writing user certs for keys 1 and 2
Branches
Unknown
Tags
Unknown