Page MenuHome GnuPG

Speed up the X.509 key listings
Closed, ResolvedPublic

Description

On large keyrings with a lot of X.509 certificates the validated key listing is not very fast. It scan's the keyrings far too often. With a certain 37 MiB keyring having about 1200 PGP and 900 X.509 certificates a

gpgsm --disable-dirmngr --with-validation -k >/dev/null

takes about 11 seconds on a i7-1370P and a fast NVME.

Event Timeline

werner created this task.
werner created this object with edit policy "Contributor (Project)".

With that patch we are down to about 6 seconds.

Now we are at 4 seconds. Available in master and 2.2.

Note that when using --list-chain instead of k, we actually cache all certificates. This could be improved by modifying the walk_chain function to take an depth arg.

werner claimed this task.

Will be available in 2.2.45 and 2.5.2

Overall effect of these changes tested on a small Windows VM is only 47 -> 26 seconds. Did also tests with --kbx-buffer-size but that does not make it better than the default, either.

Test on a dedicated Windows box (T 460, i5-6300U@2.40GHz, harddisk):

VSD Versiongpg versionLoad time
3.1.262.2.411:59
3.2.4 beta-22.2.45 beta 250:46

Load time from the start of the Kleopatra progressbar until the cert list is shown.