From 3a739424e1f5a39d55e0ed7cb9fb754aa67e24c0 Mon Sep 17 00:00:00 2001 From: Tobias Brunner Date: Thu, 30 Sep 2021 15:33:40 +0200 Subject: [PATCH] pem: Clear possibly unencrypted key file from memory --- src/libstrongswan/plugins/pem/pem_builder.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libstrongswan/plugins/pem/pem_builder.c b/src/libstrongswan/plugins/pem/pem_builder.c index 9ca96a4d21..bdf0aec9ae 100644 --- a/src/libstrongswan/plugins/pem/pem_builder.c +++ b/src/libstrongswan/plugins/pem/pem_builder.c @@ -450,7 +450,7 @@ static void *load_from_file(char *file, credential_type_t type, int subtype, return NULL; } cred = load_from_blob(*chunk, type, subtype, subject, flags); - chunk_unmap(chunk); + chunk_unmap_clear(chunk); return cred; } -- 2.47.2