Checkpoint the party/runtime stack before share-program and malicious-mode work.
Ship the TLS mesh, composer, Beaver/Yao/leaf MPC, prep/online paths, apps, and docs so the tree is pushable before elevating share_expr, security_mode, and prep resume. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
695f8e84f7
commit
0d22946a0e
1835 changed files with 170291 additions and 2849 deletions
|
|
@ -439,3 +439,41 @@ TEST(KPpvc, RejectsASharedHiddenIndex)
|
|||
EXPECT_EQ(st.copies[0].i, st.copies[1].i);
|
||||
EXPECT_FALSE(scheme::check_well_formed(pp, com, st));
|
||||
}
|
||||
|
||||
TEST(Ppvc, AuditedReplicaReexpandsFromCopath)
|
||||
{
|
||||
using scheme = dpf::ppvc<std::uint8_t, 2, 8>;
|
||||
using input_t = std::uint8_t;
|
||||
constexpr input_t live = 1;
|
||||
constexpr input_t audited = 3;
|
||||
constexpr input_t pool[] = {0, 1, 2, 3};
|
||||
|
||||
const auto pp = scheme::setup_from_seed(seed_block(90, 91));
|
||||
auto master = dpf::make_pprf_master<input_t>();
|
||||
|
||||
std::array<scheme::commitment, 4> commitments{};
|
||||
std::array<scheme::state, 4> states{};
|
||||
std::array<block, 4> seeds{};
|
||||
for (std::size_t i = 0; i < 4; ++i)
|
||||
{
|
||||
seeds[i] = dpf::pprf_eval(master, pool[i]);
|
||||
auto made = scheme::commit_from_seed(pp, seeds[i]);
|
||||
commitments[i] = std::move(made.first);
|
||||
states[i] = std::move(made.second);
|
||||
ASSERT_TRUE(scheme::check_well_formed(pp, commitments[i], states[i]));
|
||||
}
|
||||
|
||||
const input_t hidden[] = {live};
|
||||
auto copath = dpf::puncture(master, std::begin(hidden), std::end(hidden),
|
||||
/*program_hidden=*/false);
|
||||
|
||||
EXPECT_THROW((void)dpf::pprf_eval(copath, live), std::invalid_argument);
|
||||
|
||||
const auto opened = dpf::pprf_eval(copath, audited);
|
||||
EXPECT_TRUE(same_root(opened, seeds[3]));
|
||||
|
||||
auto [com_again, st_again] = scheme::commit_from_seed(pp, opened);
|
||||
EXPECT_TRUE(scheme::check_well_formed(pp, com_again, st_again));
|
||||
EXPECT_TRUE(scheme::audit(pp, commitments[3], opened));
|
||||
EXPECT_EQ(st_again.i, states[3].i);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue