toposware / frost

A fork of frost-dalek, made WASM compatible, and upgraded to Static ICE-FROST
BSD 3-Clause "New" or "Revised" License
14 stars 2 forks source link

Change AES mode of operation to CTR in share encryption #19

Closed Nashtare closed 3 years ago

Nashtare commented 3 years ago

The default implementation relies on ECB which isn't safe (see here for more info). Switches to counter mode with a nonce of 128bits randomly sampled (relies on OsRng internally during encrypt_share() to match other methods in KeyGen, would probably be better to have rng passed as parameter, as suggested in #13, which can be done later on).