diff options
| author | Thomas Huth <thuth@redhat.com> | 2026-09-16 11:50:08 +0200 |
|---|---|---|
| committer | Eric Biggers <ebiggers@kernel.org> | 2026-09-30 09:33:54 -0700 |
| commit | e2b5aa03d6f42d2e4fb9c20a4eeb9ba1a9cac8cb (patch) | |
| tree | 24df71ad571a912530552efc69988cfcf738f94f /tools/perf/scripts/python | |
| parent | 91b4ebff7a88ee3a0570b0058b054ecf527cefa2 (diff) | |
| download | linux-e2b5aa03d6f42d2e4fb9c20a4eeb9ba1a9cac8cb.tar.gz linux-e2b5aa03d6f42d2e4fb9c20a4eeb9ba1a9cac8cb.zip | |
lib/crypto: sm3: Provide a function for zeroizing the sm3_ctx structure
In certain cases crypto code functions need to zeroize their local
sm3_ctx structure after use to avoid leaking sensitive material. Provide
a sm3_zeroize_ctx() helper function that e.g. can be used with __cleanup()
to automatically zeroize the structure when it goes out of scope.
While we're at it, replace the related memzero_explicit() call in
lib/crypto/sm3.c with a call to the new helper function.
Signed-off-by: Thomas Huth <thuth@redhat.com>
Link: https://patch.msgid.link/20260916095022.604354-7-thuth@redhat.com
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
