ABY Framework
1.0
Arithmetic Bool Yao Framework
|
#include <circuit.h>
Public Member Functions | |
Circuit (ABYCircuit *aby, e_sharing context, e_role myrole, uint32_t bitlen, e_circuit circ) | |
virtual | ~Circuit () |
void | Init () |
void | Cleanup () |
void | Reset () |
uint32_t | GetShareBitLen () |
uint32_t | GetMaxDepth () |
deque< uint32_t > | GetLocalQueueOnLvl (uint32_t lvl) |
deque< uint32_t > | GetInteractiveQueueOnLvl (uint32_t lvl) |
uint32_t | GetNumLocalLayers () |
uint32_t | GetNumInteractiveLayers () |
uint32_t | GetNumInputBitsForParty (e_role party) |
uint32_t | GetNumOutputBitsForParty (e_role party) |
deque< uint32_t > | GetInputGatesForParty (e_role party) |
deque< uint32_t > | GetOutputGatesForParty (e_role party) |
e_sharing | GetContext () |
uint32_t | GetNumGates () |
UGATE_T * | GetOutputGateValue (uint32_t gateid) |
uint32_t | GetOutputGateValue (uint32_t gateid, UGATE_T *&outval) |
template<class T > | |
void | GetOutputGateValue (uint32_t gateid, T &val) |
uint32_t | GetNumVals (uint32_t gateid) |
virtual share * | PutCONSGate (uint32_t nvals, UGATE_T val, uint32_t bitlen)=0 |
virtual share * | PutCONSGate (uint32_t nvals, uint32_t *val, uint32_t bitlen)=0 |
virtual share * | PutCONSGate (uint32_t nvals, uint8_t *val, uint32_t bitlen)=0 |
virtual uint32_t | PutConstantGate (UGATE_T val, uint32_t nvals=1)=0 |
virtual share * | PutINGate (uint32_t nvals, uint64_t val, uint32_t bitlen, e_role role)=0 |
virtual share * | PutINGate (uint32_t nvals, uint32_t *val, uint32_t bitlen, e_role role)=0 |
virtual share * | PutINGate (uint32_t nvals, uint8_t *val, uint32_t bitlen, e_role role)=0 |
virtual share * | PutADDGate (share *ina, share *inb)=0 |
virtual share * | PutSUBGate (share *ina, share *inb)=0 |
virtual share * | PutANDGate (share *ina, share *inb)=0 |
virtual share * | PutXORGate (share *ina, share *inb)=0 |
virtual share * | PutMULGate (share *ina, share *inb)=0 |
virtual share * | PutGEGate (share *ina, share *inb)=0 |
virtual share * | PutEQGate (share *ina, share *inb)=0 |
virtual share * | PutMUXGate (share *ina, share *inb, share *sel)=0 |
virtual share * | PutY2BGate (share *ina)=0 |
virtual share * | PutB2AGate (share *ina)=0 |
virtual share * | PutB2YGate (share *ina)=0 |
virtual share * | PutA2YGate (share *ina)=0 |
virtual share * | PutANDVecGate (share *ina, share *inb)=0 |
virtual share * | PutCallbackGate (share *in, uint32_t rounds, void(*callback)(GATE *, void *), void *infos, uint32_t nvals)=0 |
share * | PutCombinerGate (share *ina) |
share * | PutSplitterGate (share *ina) |
share * | PutRepeaterGate (uint32_t nvals, share *ina) |
template<class T > | |
uint32_t | PutINGate (uint32_t nvals, T val) |
template<class T > | |
uint32_t | PutINGate (uint32_t nvals, T val, e_role role) |
virtual share * | PutOUTGate (share *parent, e_role dst)=0 |
virtual uint32_t | PutINVGate (uint32_t parentid)=0 |
e_circuit | GetCircuitType () |
Protected Member Functions | |
virtual void | UpdateInteractiveQueue (uint32_t gateid)=0 |
virtual void | UpdateLocalQueue (uint32_t gateid)=0 |
void | UpdateInteractiveQueue (share *gateid) |
void | UpdateLocalQueue (share *gateid) |
Protected Attributes | |
ABYCircuit * | m_cCircuit |
GATE * | m_pGates |
e_sharing | m_eContext |
e_circuit | m_eCirctype |
e_role | m_eMyRole |
uint32_t | m_nShareBitLen |
uint32_t | m_nMaxDepth |
vector< deque< uint32_t > > | m_vLocalQueueOnLvl |
vector< deque< uint32_t > > | m_vInteractiveQueueOnLvl |
vector< deque< uint32_t > > | m_vInputGates |
vector< deque< uint32_t > > | m_vOutputGates |
vector< uint32_t > | m_vInputBits |
vector< uint32_t > | m_vOutputBits |
uint32_t | m_nMULs |
uint32_t | m_nCONVGates |
uint32_t | m_nGates |
uint32_t | m_nRoundsAND |
uint32_t | m_nRoundsXOR |
vector< uint32_t > | m_nRoundsIN |
vector< uint32_t > | m_nRoundsOUT |
const deque< uint32_t > | EMPTYQUEUE |
Circuit class
|
inline |
Constructor of the class.
|
inlinevirtual |
Destructor of the class.
void Circuit::Cleanup | ( | ) |
Incomplete method
|
inline |
It is a getter method which returns the Input Gates provided for the given party
party | Party role based on which the Input gates are returned. |
|
inline |
It is a getter method which returns the Interactive queue based on the inputed level.
lvl | Required level of interactive queue. |
|
inline |
It is a getter method which returns the Local queue based on the inputed level.
lvl | Required level of local queue. |
|
inline |
It is a getter method which will return the value of Maximum Depth.
|
inline |
It is a getter method which returns the number of Input bits provided for the given party
party | Party role based on which the number of Input bits are returned. |
|
inline |
It is a getter method which returns the number of levels/layers in the Interactive queue.
|
inline |
It is a getter method which returns the number of levels/layers in the Local queue.
|
inline |
It is a getter method which returns the number of Output bits provided for the given party
party | Party role based on which the number of Output bits are returned. |
|
inline |
It is a getter method which returns the Output Gates provided for the given party
party | Party role based on which the Output gates are returned. |
|
inline |
void Circuit::Init | ( | ) |
Method performs the initialization of member objects of the Circuit class. It is called from Constructor of the class [Circuit(ABYCircuit* aby, e_sharing context, e_role myrole, uint32_t bitlen, e_circuit circ)]
void Circuit::Reset | ( | ) |
It will reset all the member objects to zero/clear them.
|
protected |
Gates vector which stores the
|
protected |
ABYCircuit Object