Function crypto::shamir::reconstruct
source · pub fn reconstruct<S: AsRef<[u8]>>(shares: &[S]) -> Vec<u8>
Expand description
This function attempts to reconstruct a secret from some amount of shares. Given that this function doesn’t know the number of shares required (), it will try to fit a polynomial in any case, thus providing an incorrect secret if there are fewer than shares provided or at least one of the provided shares is incorrect.