Open aramikm opened 3 months ago
Thanks for spotting this! Note that you're referring to a test in a PR that's still WIP, we're currently on a deep overhauling of the refresh & recovery process. The Spongebob PR (#186 ) in fact is refactoring all the code and tests related to this with a new design. The original test in the current main branch seems OK to me: https://github.com/nucypher/ferveo/blob/2fe875373ca7f9c3032346568b9a8f9b10cb1429/ferveo/src/lib.rs#L525
Having said that, this is a great issue. I recall we had a similar problem in the past with other refresh & recovery tests. I'll keep this issue open and see that #186 closes it.
Description
test_dkg_simple_tdec_share_recovery doesn't seem to use the
new_decryption_share
when combining shares to getnew_shared_secret
.This is evident in following code section which always uses the old shares.
If we modify the test as below to use to use the
new_decryption_share
3 of the test cases fail with following message
Shared secret reconstruction failed', ferveo/src/api.rs:1257:9
which might be an indication that the share recovery at a random point doesn't work as expected.