diff options
author | Tobias Heider <tobhe@cvs.openbsd.org> | 2023-06-17 22:33:35 +0000 |
---|---|---|
committer | Tobias Heider <tobhe@cvs.openbsd.org> | 2023-06-17 22:33:35 +0000 |
commit | 1611344326e916b58f5a2ec86045e56c56907ade (patch) | |
tree | 2c496f5a239eda473ef86211356e6b5c6c8d2039 /sbin | |
parent | 0079e97eaaff67e9ba68b5f2fe161d8ad68edd0a (diff) |
Fix leak of key.id_buf in pubkey auth case.
from markus
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/iked/ca.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sbin/iked/ca.c b/sbin/iked/ca.c index cd10fca4dd6..7f7c8bee0d3 100644 --- a/sbin/iked/ca.c +++ b/sbin/iked/ca.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ca.c,v 1.92 2023/05/23 13:12:19 claudio Exp $ */ +/* $OpenBSD: ca.c,v 1.93 2023/06/17 22:33:34 tobhe Exp $ */ /* * Copyright (c) 2010-2013 Reyk Floeter <reyk@openbsd.org> @@ -560,9 +560,9 @@ ca_getcert(struct iked *env, struct imsg *imsg) iov[2].iov_base = ptr; iov[2].iov_len = len; - if (proc_composev(&env->sc_ps, PROC_IKEV2, cmd, iov, iovcnt) == -1) - return (-1); - return (0); + ret = proc_composev(&env->sc_ps, PROC_IKEV2, cmd, iov, iovcnt); + ibuf_free(key.id_buf); + return (ret); } static unsigned int |