nucypher / rust-umbral

Umbral implementation in Rust
52 stars 20 forks source link

Make it impossible to create less than `threshold` kfrags in `generate_kfrags()`? #48

Open fjarri opened 3 years ago

fjarri commented 3 years ago

Currently the user can supply num_kfrags < threshold, rendering the resulting kfrags useless. We can pass overhead (or some other name) instead of num_kfrags, and return threshold + overhead kfrags. If both threshold and overhead are unsigned, it will be impossible to create a set of useless kfrags.

fjarri commented 3 years ago

Following the discussion in https://github.com/nucypher/nucypher/pull/2774, we're renaming num_kfrags to shares instead, while keeping the relation between it and threshold.

fjarri commented 2 years ago

This is related to #85 - should we just panic if threshold > shares?