Skip to content

Commit

Permalink
crypt: Zeroize initialized and reserved data members after computation.
Browse files Browse the repository at this point in the history
Fixes #204.
besser82 committed Jan 16, 2025
1 parent 0cada50 commit ac2fea3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/crypt.c
Original file line number Diff line number Diff line change
@@ -181,6 +181,8 @@ do_crypt (const char *phrase, const char *setting, struct crypt_data *data)
cint->alg_specific, sizeof cint->alg_specific);

explicit_bzero (data->internal, sizeof data->internal);
explicit_bzero (data->reserved, sizeof data->reserved);
data->initialized = 0;
}

#if INCLUDE_crypt_rn

0 comments on commit ac2fea3

Please sign in to comment.