Package viff :: Module paillier :: Class PaillierRuntime
[hide private]
[frames] | no frames]

Class PaillierRuntime

source code


Two-player runtime based on the Paillier crypto system.

Instance Methods [hide private]
 
add_player(self, player, protocol) source code
 
prss_share_random(self, field)
Generate a share of a uniformly random element.
source code
 
input(self, inputters, field, number=None)
Input *number* to the computation.
source code
 
share(self, inputters, field, number=None)
Share *number* additively.
source code
 
output(self, share, receivers=None)
Open share to receivers (defaults to all players).
source code
 
open(self, share, receivers=None)
Open *share* to *receivers* (defaults to both players).
source code
 
add(self, share_a, share_b)
Addition of shares.
source code
 
mul(self, share_a, share_b)
Multiplication of shares.
source code

Inherited from runtime.Runtime: __init__, abort, activate_reactor, fork_pc, handle_deferred_data, increment_pc, preprocess, print_transferred_data, process_deferred_queue, process_queue, schedule_callback, schedule_complex_callback, shutdown, synchronize, unfork_pc, wait_for

Static Methods [hide private]

Inherited from runtime.Runtime: add_options

Instance Variables [hide private]

Inherited from runtime.Runtime: activation_counter, deferred_queue, depth_counter, depth_limit, id, num_players, players, program_counter, protocols, threshold, using_viff_reactor

Inherited from runtime.Runtime (private): _needed_data, _pool

Method Details [hide private]

add_player(self, player, protocol)

source code 
Overrides: runtime.Runtime.add_player

input(self, inputters, field, number=None)

source code 

Input *number* to the computation.

The input is shared using the :meth:`share` method.

Overrides: runtime.Runtime.input

output(self, share, receivers=None)

source code 

Open share to receivers (defaults to all players).

Returns a Share to players with IDs in receivers and None to the remaining players.

Overrides: runtime.Runtime.output
(inherited documentation)

add(self, share_a, share_b)

source code 

Addition of shares.

Communication cost: none.

Overrides: runtime.Runtime.add

mul(self, share_a, share_b)

source code 

Multiplication of shares.

Overrides: runtime.Runtime.mul