summaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2021-09-18 16:45:08 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2021-09-18 16:45:08 +0000
commit627165aaa827747a14da2062fa3f5361aeffc9f6 (patch)
tree10d96227f3fca3300141b7b3c950f8d3c7dc2dd8 /sbin
parenta00d2d0bf8c75beb1fdcb3bf9af44b430bbfe3c4 (diff)
freezero() instead of free(), because the object may contain a password
ok tobhe
Diffstat (limited to 'sbin')
-rw-r--r--sbin/iked/config.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/iked/config.c b/sbin/iked/config.c
index 029ee2b5813..87047a1f326 100644
--- a/sbin/iked/config.c
+++ b/sbin/iked/config.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: config.c,v 1.80 2021/09/01 15:30:06 tobhe Exp $ */
+/* $OpenBSD: config.c,v 1.81 2021/09/18 16:45:07 deraadt Exp $ */
/*
* Copyright (c) 2019 Tobias Heider <tobias.heider@stusta.de>
@@ -455,7 +455,7 @@ config_new_user(struct iked *env, struct iked_user *new)
memcpy(old->usr_pass, new->usr_pass, IKED_PASSWORD_SIZE);
log_debug("%s: updating user %s", __func__, usr->usr_name);
- free(usr);
+ freezero(usr, sizeof *usr);
return (old);
}