mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
agent: New option --pinentry-invisible-char.
* agent/gpg-agent.c (oPinentryInvisibleChar): New. (opts): Add option. (parse_rereadable_options): Set option. * agent/agent.h (opt): Add field pinentry_invisible_char. * agent/call-pinentry.c (start_pinentry): Pass option to pinentry. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
9e65bbd255
commit
93d257c819
4 changed files with 39 additions and 3 deletions
|
@ -475,6 +475,21 @@ start_pinentry (ctrl_t ctrl)
|
|||
}
|
||||
}
|
||||
|
||||
/* Tell the pinentry that we would prefer that the given character
|
||||
is used as the invisible character by the entry widget. */
|
||||
if (opt.pinentry_invisible_char)
|
||||
{
|
||||
char *optstr;
|
||||
if ((optstr = xtryasprintf ("OPTION invisible-char=%s",
|
||||
opt.pinentry_invisible_char)))
|
||||
{
|
||||
assuan_transact (entry_ctx, optstr, NULL, NULL, NULL, NULL, NULL,
|
||||
NULL);
|
||||
/* We ignore errors because this is just a fancy thing and
|
||||
older pinentries do not support this feature. */
|
||||
xfree (optstr);
|
||||
}
|
||||
}
|
||||
|
||||
/* Tell the pinentry the name of a file it shall touch after having
|
||||
messed with the tty. This is optional and only supported by
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue