forked from WeDPR-Team/MP-SPDZ
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Verifier.h
36 lines (27 loc) · 923 Bytes
/
Verifier.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#ifndef _Verifier
#define _Verifier
#include "Proof.h"
template <class FD>
bool Check_Decoding(const vector<Proof::bound_type>& AE, bool Diag, FD& FieldD);
/* Defines the Verifier */
template <class FD>
class Verifier
{
AddableVector<typename Proof::bound_type> z;
AddableMatrix<Int_Random_Coins::value_type::value_type> t;
Proof& P;
const FD& FieldD;
public:
Verifier(Proof& proof, const FD& FieldD);
void Stage_2(
AddableVector<Ciphertext>& c, octetStream& ciphertexts,
octetStream& cleartexts,const FHE_PK& pk);
/* This is the non-interactive version using the ROM
- Creates space for all output values
- Diag flag mirrors that in Prover
*/
void NIZKPoK(AddableVector<Ciphertext>& c,octetStream& ciphertexts,octetStream& cleartexts,
const FHE_PK& pk);
size_t report_size(ReportType type) { return z.report_size(type) + t.report_size(type); }
};
#endif