Home GnuPG
Diffusion GPGME 3f297387bf40

qt: Allow specifying user IDs to use when refreshing keys via WKD

Description

qt: Allow specifying user IDs to use when refreshing keys via WKD

* lang/qt/src/wkdrefreshjob.h, lang/qt/src/wkdrefreshjob.cpp
(WKDRefreshJob::start): New overload.
* lang/qt/src/wkdrefreshjob_p.h (WKDRefreshJobPrivate): Add field
m_userIds.
* lang/qt/src/qgpgmewkdrefreshjob.cpp (toEmailAddresses): New.
(locate_external_keys): Change return type and arguments.
(refresh_keys): Remove.
(QGpgMEWKDRefreshJobPrivate::startIt): Get emails from keys or user IDs.
Remove duplicates. Call locate_external_keys instead of refresh_keys.
* lang/qt/tests/run-wkdrefreshjob.cpp (CommandLineOptions,
parseCommandLine): New.
(main): Support new option --all-userids.

The new start() overload allows to specify the user IDs to use for the
WKD lookup explicitly. This allows updating user IDs via WKD which were
originally not retrieved via WKD.

Details

Provenance
ikloeckerAuthored on Aug 23 2023, 12:00 PM
Parents
rMaee18a2ab249: qt,tests: Fix build in source directory, part 2
Branches
Unknown
Tags
Unknown
Tasks
T6672: gpgme: Add support for refreshing OpenPGP keys via WKD