gpg: New command --quick-addkey.
authorWerner Koch <wk@gnupg.org>
Thu, 2 Jun 2016 13:54:48 +0000 (15:54 +0200)
committerWerner Koch <wk@gnupg.org>
Thu, 2 Jun 2016 14:01:48 +0000 (16:01 +0200)
commit8f2a053a0ffa0430d01a53b4d491a3f0fff683eb
tree0251344b7eb7b579016fbaf393de014cf19daa33
parentd837f6b0eadb14ea08c1c6030b4d6adaaee8778e
gpg: New command --quick-addkey.

* g10/keygen.c (DEFAULT_STD_SUBKEYUSE): New.
(ask_keysize): Factor code out to ...
(get_keysize_range, fixup_keysize): new.
(parse_parameter_usage): Factor parsing out to  ...
(parse_usagestr): new.  Allow use of "encr" as alias for "encrypt".
(parse_subkey_algostr_usagestr): New.
(generate_subkeypair): Add new args.  Implement unattended mode.

* g10/keyedit.c (keyedit_quick_sign): Factor some code out to ...
(find_by_primary_fpr): new.
(keyedit_quick_addkey): New.
* g10/gpg.c (aQuickAddKey): New.
(opts): Add --quick-addkey.
(main): Implement.

Signed-off-by: Werner Koch <wk@gnupg.org>
doc/gpg.texi
g10/gpg.c
g10/keyedit.c
g10/keygen.c
g10/main.h