aboutsummaryrefslogtreecommitdiffstats
path: root/scd/app-common.h
diff options
context:
space:
mode:
authorNIIBE Yutaka <[email protected]>2019-04-25 05:49:49 +0000
committerNIIBE Yutaka <[email protected]>2019-04-25 05:49:49 +0000
commit874bc970ba6ec243ff474ef090242e0f7be6a7bc (patch)
treeb4c9814832ad8a1438ed708616a0c6671a05480f /scd/app-common.h
parentpo: Update Japanese Translation. (diff)
downloadgnupg-874bc970ba6ec243ff474ef090242e0f7be6a7bc.tar.gz
gnupg-874bc970ba6ec243ff474ef090242e0f7be6a7bc.zip
scd: Add new command: KEYINFO.
* scd/app-common.h (struct app_ctx_s): Add with_keygrip function. * scd/app-openpgp.c (do_with_keygrip): New. * scd/app.c (app_do_with_keygrip): New. * scd/command.c (cmd_keyinfo): New. (send_keyinfo): New. -- KEYGRIP_ACTION_LOOKUP is not yet used. It will be used for directly asking PK* action to determine an APP. Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'scd/app-common.h')
-rw-r--r--scd/app-common.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/scd/app-common.h b/scd/app-common.h
index 6bb8eba50..8a25cda55 100644
--- a/scd/app-common.h
+++ b/scd/app-common.h
@@ -126,9 +126,18 @@ struct app_ctx_s {
gpg_error_t (*check_pin) (app_t app, const char *keyidstr,
gpg_error_t (*pincb)(void*, const char *, char **),
void *pincb_arg);
+ int (*with_keygrip) (app_t app, ctrl_t ctrl, int action,
+ const char *keygrip_str);
} fnc;
};
+enum
+ {
+ KEYGRIP_ACTION_SEND_DATA,
+ KEYGRIP_ACTION_WRITE_STATUS,
+ KEYGRIP_ACTION_LOOKUP
+ };
+
/*-- app-help.c --*/
unsigned int app_help_count_bits (const unsigned char *a, size_t len);
gpg_error_t app_help_get_keygrip_string_pk (const void *pk, size_t pklen,
@@ -206,6 +215,7 @@ gpg_error_t app_change_pin (app_t app, ctrl_t ctrl,
gpg_error_t app_check_pin (app_t app, ctrl_t ctrl, const char *keyidstr,
gpg_error_t (*pincb)(void*, const char *, char **),
void *pincb_arg);
+app_t app_do_with_keygrip (ctrl_t ctrl, int action, const char *keygrip_str);
/*-- app-openpgp.c --*/