/* * SimpleDistDecrypt.cpp * */ #include template void SimpleDistDecrypt::intermediate_step() { for (unsigned int i = 0; i < this->vv.size(); i++) this->vv[i] += this->f.coeff(i); } template void SimpleDistDecrypt::reshare(Plaintext& m, const Ciphertext& cm, EncCommitBase& EC) { (void)EC; m = reshare(cm); } template Plaintext_ SimpleDistDecrypt::reshare(const Ciphertext& cm) { PRNG G; G.ReSeed(); this->f.randomize(G, Full); // Step 3 this->run(cm); // Step 4 Plaintext_ m(this->f.get_field()); if (this->P.my_num()==0) { sub(m,this->mf,this->f); } else { m=this->f; m.negate(); } return m; } template class SimpleDistDecrypt; template class SimpleDistDecrypt;