X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/blobdiff_plain/55fb297890fbd83482db2d2516a9392befb3eb21..973612f5e86c9eaabc812a47d81c5cb14f672249:/ssh.c diff --git a/ssh.c b/ssh.c index 7e183880..aa619e3e 100644 --- a/ssh.c +++ b/ssh.c @@ -3222,7 +3222,7 @@ static int do_ssh1_login(Ssh ssh, unsigned char *in, int inlen, while (pktin->type == SSH1_SMSG_FAILURE) { s->pwpkt_type = SSH1_CMSG_AUTH_PASSWORD; - if (agent_exists() && !s->tried_agent) { + if (ssh->cfg.tryagent && agent_exists() && !s->tried_agent) { /* * Attempt RSA authentication using Pageant. */ @@ -6613,7 +6613,7 @@ static void do_ssh2_authconn(Ssh ssh, unsigned char *in, int inlen, s->nkeys = 0; s->agent_response = NULL; s->pkblob_in_agent = NULL; - if (agent_exists()) { + if (ssh->cfg.tryagent && agent_exists() && ssh->cfg.tryagent) { void *r;