summaryrefslogtreecommitdiffstats
path: root/ssh-sk-helper.c
diff options
context:
space:
mode:
authordtucker@openbsd.org <dtucker@openbsd.org>2022-04-29 05:16:48 +0200
committerDamien Miller <djm@mindrot.org>2022-04-29 05:26:24 +0200
commit3e26b3a6eebcee27be177207cc0846fb844b7a56 (patch)
treee0acf20e23056daa3b48b8cd0964a2c0b5ca5bbe /ssh-sk-helper.c
parentupstream: fix memleak on session-bind path; from Pedro Martelletto, ok (diff)
downloadopenssh-3e26b3a6eebcee27be177207cc0846fb844b7a56.tar.xz
openssh-3e26b3a6eebcee27be177207cc0846fb844b7a56.zip
upstream: Don't leak SK device. Patch from Pedro Martelletto via
github PR#316. ok djm@ OpenBSD-Commit-ID: 17d11327545022e727d95fd08b213171c5a4585d
Diffstat (limited to '')
-rw-r--r--ssh-sk-helper.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ssh-sk-helper.c b/ssh-sk-helper.c
index b1d22631f..bd9b410a6 100644
--- a/ssh-sk-helper.c
+++ b/ssh-sk-helper.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ssh-sk-helper.c,v 1.12 2021/10/28 02:54:18 djm Exp $ */
+/* $OpenBSD: ssh-sk-helper.c,v 1.13 2022/04/29 03:16:48 dtucker Exp $ */
/*
* Copyright (c) 2019 Google LLC
*
@@ -265,6 +265,7 @@ process_load_resident(struct sshbuf *req)
sshsk_free_resident_keys(srks, nsrks);
sshbuf_free(kbuf);
free(provider);
+ free(device);
if (pin != NULL)
freezero(pin, strlen(pin));
return resp;