Re: [PATCH v3 2/2] rust: crypto: add synchronous RSA akcipher support

From: Miguel Ojeda

Date: Thu Aug 27 2026 - 11:04:11 EST


On Wed, Aug 26, 2026 at 6:30 PM Mike Lothian <mike@xxxxxxxxxxxxxx> wrote:
>
> +__rust_helper void rust_helper_aes_enckey_zero(struct aes_enckey *key)
> +{
> + memzero_explicit(key, sizeof(*key));
> +}

Hmm... why does this one need to be a Rust helper? i.e. why doesn't it
call the other helper from Rust?

(Same for the other calls I notice here in the context of the patch to
`memzero_explicit`.)

i.e. helpers are meant to be as minimal as possible -- just forwarders
to the same functions unless there is a good reason not to.

And then you can have a safe function abstracting the call and use
that from the different places you may need in Rust (e.g. from
`Secret` and `Aes128`).

Thanks!

Cheers,
Miguel