mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
gpg: Handle the agent's NEW_PASSPHRASE inquiry.
* g10/call-agent.c (default_inq_cb): Take care of NEW_PASSPHRASE.
This commit is contained in:
parent
2838385e76
commit
baee681d24
@ -336,7 +336,7 @@ default_inq_cb (void *opaque, const char *line)
|
||||
gpg_error_t err = 0;
|
||||
struct default_inq_parm_s *parm = opaque;
|
||||
|
||||
if (!strncmp (line, "PINENTRY_LAUNCHED", 17) && (line[17]==' '||!line[17]))
|
||||
if (has_leading_keyword (line, "PINENTRY_LAUNCHED"))
|
||||
{
|
||||
err = gpg_proxy_pinentry_notify (parm->ctrl, line);
|
||||
if (err)
|
||||
@ -344,7 +344,8 @@ default_inq_cb (void *opaque, const char *line)
|
||||
"PINENTRY_LAUNCHED");
|
||||
/* We do not pass errors to avoid breaking other code. */
|
||||
}
|
||||
else if (!strncmp (line, "PASSPHRASE", 10) && (line[10]==' '||!line[10])
|
||||
else if ((has_leading_keyword (line, "PASSPHRASE")
|
||||
|| has_leading_keyword (line, "NEW_PASSPHRASE"))
|
||||
&& opt.pinentry_mode == PINENTRY_MODE_LOOPBACK)
|
||||
{
|
||||
if (have_static_passphrase ())
|
||||
|
Loading…
x
Reference in New Issue
Block a user