mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
gpg: Re-enable the "Passphrase" parameter for batch key generation.
* agent/command.c (cmd_genkey): Add option --inq-passwd. * agent/genkey.c (agent_genkey): Add new arg override_passphrase. * g10/call-agent.c (inq_genkey_parms): Handle NEWPASSWD keyword. (agent_genkey): Add arg optional arg "passphrase". * g10/keygen.c (common_gen, gen_elg, gen_dsa, gen_ecc) (gen_rsa, do_create): Add arg "passphrase" and pass it through. (do_generate_keypair): Make use of pPASSPHRASE. (release_parameter_list): Wipe out a passphrase parameter. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
2a8fe0448d
commit
aa99ebde77
9 changed files with 128 additions and 57 deletions
|
@ -1134,6 +1134,13 @@ The @option{--no-protection} option may be used to prevent prompting for a
|
|||
passphrase to protect the secret key while leaving the secret key unprotected.
|
||||
The @option{--preset} option may be used to add the passphrase to the cache
|
||||
using the default cache parameters.
|
||||
|
||||
The @option{--inq-passwd} option may be used to create the key with a
|
||||
supplied passphrase. When used the agent does an inquiry with the
|
||||
keyword @code{NEWPASSWD} to retrieve that passphrase. This option
|
||||
takes precedence over @option{--no-protection}; however if the client
|
||||
sends a empty (zero-length) passphrase, this is identical to
|
||||
@option{--no-protection}.
|
||||
@end ifset
|
||||
|
||||
@node Agent IMPORT
|
||||
|
|
10
doc/gpg.texi
10
doc/gpg.texi
|
@ -3341,17 +3341,13 @@ ignored and instead the usual passphrase dialog is used. This does
|
|||
not make sense for batch key generation; however the unattended key
|
||||
generation feature is also used by GUIs and this feature relinquishes
|
||||
the GUI from implementing its own passphrase entry code. These are
|
||||
global control statements and affect all future key genrations.
|
||||
global control statements and affect all future key generations.
|
||||
@end ifclear
|
||||
@ifset gpgtwoone
|
||||
This option is a no-op for GnuPG 2.1 and later.
|
||||
@end ifset
|
||||
|
||||
|
||||
@item %no-protection
|
||||
Since GnuPG version 2.1 it is not anymore possible to specify a
|
||||
passphrase for unattended key generation. The passphrase command is
|
||||
simply ignored and @samp{%ask-passpharse} is thus implicitly enabled.
|
||||
Using this option allows the creation of keys without any passphrase
|
||||
protection. This option is mainly intended for regression tests.
|
||||
|
||||
|
@ -3409,8 +3405,8 @@ by running the command @samp{gpg2 --gpgconf-list}".
|
|||
Key usage lists for a subkey; similar to @samp{Key-Usage}.
|
||||
|
||||
@item Passphrase: @var{string}
|
||||
If you want to specify a passphrase for the secret key,
|
||||
enter it here. Default is not to use any passphrase.
|
||||
If you want to specify a passphrase for the secret key, enter it here.
|
||||
Default is to use the Pinentry dialog to ask for a passphrase.
|
||||
|
||||
@item Name-Real: @var{name}
|
||||
@itemx Name-Comment: @var{comment}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue