diff options
Diffstat (limited to 'src/engine-gpgsm.c')
| -rw-r--r-- | src/engine-gpgsm.c | 12 | 
1 files changed, 11 insertions, 1 deletions
| diff --git a/src/engine-gpgsm.c b/src/engine-gpgsm.c index 710bf14a..8ec15985 100644 --- a/src/engine-gpgsm.c +++ b/src/engine-gpgsm.c @@ -1551,7 +1551,7 @@ gpgsm_keylist (void *engine, const char *pattern, int secret_only,       the agent.  However on a fresh installation no public keys are       available and thus there is no need for gpgsm to ask the agent       whether a secret key exists for the public key.  */ -  if (secret_only) +  if (secret_only || (mode & GPGME_KEYLIST_MODE_WITH_SECRET))      gpgsm_assuan_simple_command (gpgsm->assuan_ctx, "GETINFO agent-check",                                   NULL, NULL); @@ -1580,6 +1580,11 @@ gpgsm_keylist (void *engine, const char *pattern, int secret_only,                                 "OPTION with-ephemeral-keys=1":                                 "OPTION with-ephemeral-keys=0" ,                                 NULL, NULL); +  gpgsm_assuan_simple_command (gpgsm->assuan_ctx, +                               (mode & GPGME_KEYLIST_MODE_WITH_SECRET)? +                               "OPTION with-secret=1": +                               "OPTION with-secret=0" , +                               NULL, NULL);    /* Length is "LISTSECRETKEYS " + p + '\0'.  */ @@ -1645,6 +1650,11 @@ gpgsm_keylist_ext (void *engine, const char *pattern[], int secret_only,                                 "OPTION with-validation=1":                                 "OPTION with-validation=0" ,                                 NULL, NULL); +  gpgsm_assuan_simple_command (gpgsm->assuan_ctx, +                               (mode & GPGME_KEYLIST_MODE_WITH_SECRET)? +                               "OPTION with-secret=1": +                               "OPTION with-secret=0" , +                               NULL, NULL);    if (pattern && *pattern) | 
