Home GnuPG
Diffusion GPGME 3da06d1096ee

cpp: Allow export of secret keys

Description

cpp: Allow export of secret keys

* lang/cpp/src/context.h (class Context): New member functions
exportSecretKeys, startSecretKeyExport, exportKeys, startKeyExport.
(Context::exportPublicKeys, Context::startPublicKeyExport): Rename
argument flags/export_mode to mode.
* lang/cpp/src/context.cpp (Context::exportPublicKeys): Return error if
ExportSecret mode flag is set. Call exportKeys().
(Context::startPublicKeyExport): Return error if
ExportSecret mode flag is set. Call startKeyExport().
(Context::exportSecretKeys, Context::startSecretKeyExport,
Context::exportKeys, Context::startKeyExport): Implement.

This adds export functions for secret key exports and generic export
functions that can be used for any key export supported by
gpgme_op_export[_ext][_start].

  • GnuPG-bug-id: T5757

Details

Provenance
ikloeckerAuthored on Jan 4 2022, 3:23 PM
Parents
rM4888191014c2: cpp: Mark ExportNoUID flag as obsolete
Branches
Unknown
Tags
Unknown
Tasks
Unknown Object (Maniphest Task)