| Home | Trees | Indices | Help |
|
|---|
|
|
Basic VIFF runtime with no crypto.
This runtime contains only the most basic operations needed such as the program counter, the list of other players, etc.
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
_needed_data Description of needed preprocessed data. |
|||
|
_pool Pool of preprocessed data. |
|||
|
activation_counter Counter for calls of activate_reactor(). |
|||
|
deferred_queue Queue of deferreds and data. |
|||
|
depth_counter Record the recursion depth. |
|||
|
depth_limit Recursion depth limit by experiment, including security margin. |
|||
|
id ID of this player. |
|||
|
num_players Number of known players. |
|||
|
players Information on players. |
|||
|
program_counter Current program counter. |
|||
|
protocols Connections to the other players. |
|||
|
threshold Shamir secret sharing threshold. |
|||
|
using_viff_reactor Use deferred queues only if the ViffReactor is running. |
|||
|
|||
Initialize runtime. Initialized a runtime owned by the given, the threshold, and optionally a set of options. The runtime has no network connections and knows of no other players -- the create_runtime function should be used instead to create a usable runtime. |
Exchange shares with another player. We send the player our share and record a Deferred which will trigger when the share from the other side arrives. |
Abort the execution due to an exception. The protocol received bad data which resulted in exc being raised when unpacking. |
Activate the reactor to do actual communcation. This is where the recursion happens. |
Secure addition. At least one of the arguments must be a Share, the other can be a FieldElement or a (possible long) Python integer. |
|
Input number to the computation. The players listed in inputters must provide an input number, everybody will receive a list with Share objects, one from each inputter. If only a single player is listed in inputters, then a Share is given back directly. |
Secure multiplication. At least one of the arguments must be a Share, the other can be a FieldElement or a (possible long) Python integer. |
Open share to receivers (defaults to all players). Returns a Share to players with IDs in receivers and None to the remaining players. |
Generate preprocess material. The program specifies which methods to call and with which arguments. The generator methods called must adhere to the following interface:
The ActiveRuntime.generate_triples method is an example of a method fulfilling this interface. |
Execute the callbacks of the deferreds in the queue. If this function is not called via activate_reactor(), also complex callbacks are executed. |
Schedule a callback on a deferred with the correct program counter. If a callback depends on the current program counter, then use this method to schedule it instead of simply calling addCallback directly. Simple callbacks that are independent of the program counter can still be added directly to the Deferred as usual. Any extra arguments are passed to the callback as with addCallback. |
Schedule a complex callback, i.e. a callback which blocks a long time. Consider that the deferred is forked, i.e. if the callback returns something to be used afterwards, add further callbacks to the returned deferred. |
Shutdown the runtime. All connections are closed and the runtime cannot be used again after this has been called. |
Introduce a synchronization point. Returns a Deferred which will trigger if and when all other players have made their calls to synchronize. By adding callbacks to the returned Deferred, one can divide a protocol execution into disjoint phases. |
Make the runtime wait for the variables given. The runtime is shut down when all variables are calculated. |
|
|||
num_playersNumber of known players. Equal to len(self.players), but storing it here is more direct. |
playersInformation on players. Mapping from Player ID to Player objects. |
protocolsConnections to the other players. Mapping from from Player ID to ShareExchanger objects. |
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Mon Oct 19 16:43:45 2009 | http://epydoc.sourceforge.net |