bls-signatures icon indicating copy to clipboard operation
bls-signatures copied to clipboard

feat: zeorize support

Open palozano opened this issue 1 year ago • 2 comments

This PR adds specific support for the Zeroize crate.

In particular, it allows the PrivateKey struct to derive Zeroize.

This translates into having the possibility to have secure PrivateKeys since they won't leak any information if the memory address is accessed after the variable is dropped.

The functionality relies on the fact that the crate bls12_381 also implements Zeorize, so nothing in the API has changed.

Solves #74

palozano avatar Dec 11 '23 10:12 palozano

Looks like this doesn't actually compile yet. Given that zeroize is sth not everyone needs, I would also prefer this to be an optional feature.

dignifiedquire avatar Dec 13 '23 11:12 dignifiedquire

It does compile, but maybe you can indicate if there are some improvements in the code, @dignifiedquire

palozano avatar Dec 13 '23 18:12 palozano