From 17dea476e3158b9e02b47a58e0b853373d1e66cf Mon Sep 17 00:00:00 2001 From: Emil Lerch Date: Thu, 1 Feb 2024 08:42:55 -0800 Subject: [PATCH] secureZero the account key on deinit of the account --- src/Account.zig | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Account.zig b/src/Account.zig index d19c404..20fe4d7 100644 --- a/src/Account.zig +++ b/src/Account.zig @@ -24,6 +24,7 @@ pub fn accountForId(allocator: std.mem.Allocator, account_id: []const u8) !Self } pub fn deinit(self: Self) void { + std.crypto.utils.secureZero(u8, self.root_account_key); self.allocator.free(self.root_account_key); }