X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=pageant.c;h=c008f008030b8619092f7eac3e74acf36decfe45;hb=bf00bcd2a4fee0855567b62cff83a0006c7c3232;hp=da320681ff138feddb5d85bf6f4769e583cf1ee2;hpb=ef3959992e3c7b5226da66505881fe2f73479c28;p=PuTTY.git diff --git a/pageant.c b/pageant.c index da320681..c008f008 100644 --- a/pageant.c +++ b/pageant.c @@ -674,7 +674,7 @@ void *pageant_handle_msg(const void *msg, int msglen, int *outlen, } bloblen = msgend - p; - key->data = key->alg->openssh_createkey(&p, &bloblen); + key->data = key->alg->openssh_createkey(key->alg, &p, &bloblen); if (!key->data) { sfree(key); fail_reason = "key setup failed"; @@ -1100,6 +1100,7 @@ static int pageant_listen_accepting(Plug plug, struct pageant_listen_state *pl = (struct pageant_listen_state *)plug; struct pageant_conn_state *pc; const char *err; + char *peerinfo; pc = snew(struct pageant_conn_state); pc->fn = &connection_fn_table; @@ -1116,8 +1117,13 @@ static int pageant_listen_accepting(Plug plug, sk_set_frozen(pc->connsock, 0); - /* FIXME: can we get any useful peer id info? */ - plog(pl->logctx, pl->logfn, "%p: new connection", pc); + peerinfo = sk_peer_info(pc->connsock); + if (peerinfo) { + plog(pl->logctx, pl->logfn, "%p: new connection from %s", + pc, peerinfo); + } else { + plog(pl->logctx, pl->logfn, "%p: new connection", pc); + } return 0; }