[PATCH] Add ability to specify a subkey.

Ben Kibbey bjk at luxsci.net
Sat Feb 4 04:23:37 CET 2017

On Thu, Feb 02, 2017 at 09:29:48AM +0100, Werner Koch wrote:
> On Sun,  1 Jan 2017 01:04, bjk at luxsci.net said:
> > a keyid or fingerprint. It's up to the user to set the .exact member of
> > gpgme_subkey_t to have the '!' appended before calling gpg otherwise it
> The struct returned by GPGME need to be considered read-only for a user
> of GPGME:
>    Those structures shall be considered read-only and an application
>    must not allocate such a structure on its own.
> (in the section Result Management).  Thus a different way to specify
> this is required.
> Given that this is will be a rarely used feature, what about a
> gpgme_key_set_flag function which could works similar to the
> gpgme_data_set_flag function.  That would be more flexible than to add
> dedicated functions for marking a subkey or to provide extra versions of
> the encrypt and sign functions to take a selection criteria for the
> subkey.

Attached is a patch to add gpgme_subkey_set_flag(). Is this what you had
in mind?

Ben Kibbey
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Add-gpgme_subkey_set_flag.patch
Type: text/x-diff
Size: 6716 bytes
Desc: not available
URL: </pipermail/attachments/20170203/29b257e6/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: </pipermail/attachments/20170203/29b257e6/attachment.sig>

More information about the Gnupg-devel mailing list