MOTION
0.01
Framework for mixed-protocol multi-party computation
|
Namespaces | |
communication | |
curve25519 | |
detail | |
primitives | |
proto | |
Classes | |
class | AccumulatedCommunicationStatistics |
class | AccumulatedRunTimeStatistics |
class | AcOtReceiver |
class | AcOtSender |
class | Aes128CtrRng |
struct | AlgorithmDescription |
class | ArithmeticGmwToBmrGate |
class | Backend |
struct | BaseOtData |
class | BaseOtMessageHandler |
class | BaseOtProvider |
struct | BaseOtReceiverData |
struct | BaseOtSenderData |
class | BaseProvider |
class | BasicOtReceiver |
class | BasicOtSender |
class | BasicSynchronizedQueue |
struct | BinaryMtVector |
class | BitMatrix |
class | BitSpan |
Non-owning non-resizeable BitVector. More... | |
class | BitVector |
Class representing a series of bits and providing single bit access. More... | |
struct | Block128 |
Block of aligned 128 bit / 16 B. More... | |
struct | Block128Vector |
Vector of 128 bit / 16 B blocks. More... | |
class | BmrToBooleanGmwGate |
class | BooleanGmwToBmrGate |
class | BooleanShare |
class | BooleanWire |
class | Condition |
Wraps a std::condition_variable with a std::mutex and a condition checking function. More... | |
class | Configuration |
class | FiberCondition |
Wraps a boost::fibers::condition_variable with a boost::fibers::mutex and a condition checking function. More... | |
class | FiberThreadPool |
class | FixedXcOt128Receiver |
class | FixedXcOt128Sender |
class | Gate |
class | GateExecutor |
class | GmwToArithmeticGate |
class | GOt128Receiver |
class | GOt128Sender |
class | GOtBitReceiver |
class | GOtBitSender |
class | GOtReceiver |
class | GOtSender |
struct | HelloMessageHandler |
class | InputGate |
struct | IntegerMtVector |
struct | is_specialization |
struct | is_specialization< Ref< Args... >, Ref > |
class | LockedFiberQueue |
class | LockedQueue |
class | Logger |
class | MtProvider |
class | MtProviderFromOts |
class | NInputGate |
class | OneGate |
class | OpenSslRng |
class | Ot |
struct | OtExtensionData |
class | OtExtensionMessageHandler |
struct | OtExtensionReceiverData |
struct | OtExtensionSenderData |
class | OtHL17 |
class | OtProvider |
class | OtProviderFromBaseOTs |
class | OtProviderFromFile |
class | OtProviderFromMultipleThirdParties |
class | OtProviderFromOtExtension |
class | OtProviderFromThirdParty |
class | OtProviderManager |
class | OtProviderReceiver |
class | OtProviderSender |
class | OtVector |
class | OutputGate |
class | OutputMessageHandler |
class | Party |
struct | PrimitiveOperation |
class | RandomOt |
struct | ReceiverMessage |
class | Register |
class | ReusableFuture |
class | ReusablePromise |
class | Rng |
class | ROtReceiver |
class | ROtSender |
struct | RunTimeStatistics |
class | SbMessageHandler |
class | SbProvider |
class | SbProviderFromSps |
class | SecureUnsignedInteger |
struct | SenderMessage |
class | Share |
struct | SharedBitsData |
class | ShareWrapper |
class | SimdifyGate |
yields a share that constitutes a concatenation of the parent in terms of their SIMD values, e.g., if 3 parents contain 1, 3, and 2 SIMD values, respectively, the output will contain 1 share with 6 SIMD values and the same number of wires as parents. The output SIMD values will be ordered as [parent_0[simd_0], parent_1[simd_0, simd_1, simd_2], parent_2[simd_0, simd_1]]. More... | |
class | SpProvider |
class | SpProviderFromOts |
struct | SpVector |
class | SubsetGate |
obtains a subset of SIMD values of a share at provided position ids. Repeated position ids are allowed, meaning that the number of SIMD values of the output share may be greater than the number of SIMD values of the parent share. Each of the position ids must be smaller than the number of SIMD values of the parent share. More... | |
class | ThreeGate |
class | TwoGate |
class | UnsimdifyGate |
yields a set of shares that correspond to single "SIMD layers" of the parent, e.g., if parent contains 10 SIMD values, the output will contain 10 shares with 1 SIMD value and the same number of wires as parent. More... | |
class | Wire |
class | XcOtBitReceiver |
class | XcOtBitSender |
class | XcOtReceiver |
class | XcOtSender |
Typedefs | |
using | GatePointer = std::shared_ptr< Gate > |
using | InputGatePointer = std::shared_ptr< InputGate > |
using | LoggerPointer = std::shared_ptr< Logger > |
using | ConfigurationPointer = std::shared_ptr< Configuration > |
using | RegisterPointer = std::shared_ptr< Register > |
using | BackendPointer = std::shared_ptr< Backend > |
using | PartyPointer = std::unique_ptr< Party > |
using | WirePointer = std::shared_ptr< Wire > |
using | BaseOtMessages = std::array< std::array< std::byte, 16 >, kKappa > |
using | Blake2bCtx = std::unique_ptr< EVP_MD_CTX, std::function< void(EVP_MD_CTX *)> > |
using | DefaultRng = Aes128CtrRng |
using | SharePointer = std::shared_ptr< Share > |
using | OutputGatePointer = std::shared_ptr< OutputGate > |
using | BooleanSharePointer = std::shared_ptr< BooleanShare > |
using | BooleanWirePointer = std::shared_ptr< BooleanWire > |
using | StatId = RunTimeStatistics::StatisticsId |
using | StdAllocator = std::allocator< std::byte > |
using | AlignedAllocator = boost::alignment::aligned_allocator< std::byte, kAlignment > |
using | AlignedBitVector = BitVector< AlignedAllocator > |
using | LoggerType = boost::log::sources::severity_channel_logger< boost::log::trivial::severity_level, std::size_t > |
template<template< typename > class Value, typename... Ts> | |
using | TypeMap = decltype(detail::MakeTypeMap< Value, Ts... >()) |
template<typename R > | |
using | ReusableFiberFuture = ReusableFuture< R, boost::fibers::mutex, boost::fibers::condition_variable > |
template<typename R > | |
using | ReusableFiberPromise = ReusablePromise< R, boost::fibers::mutex, boost::fibers::condition_variable > |
template<typename T > | |
using | SynchronizedQueue = BasicSynchronizedQueue< T, std::mutex, std::condition_variable > |
template<typename T > | |
using | SynchronizedFiberQueue = BasicSynchronizedQueue< T, boost::fibers::mutex, boost::fibers::condition_variable > |
template<typename T > | |
using | IsUnsignedInt = std::enable_if_t< std::conjunction_v< std::is_integral< T >, std::is_unsigned< T >, std::negation< std::is_same< T, bool > >> > |
Functions | |
std::vector< std::unique_ptr< Party > > | MakeLocallyConnectedParties (const std::size_t number_of_parties, std::uint16_t port, const bool logging=false) |
constructs number_of_parties motion::Party's locally connected via TCP. More... | |
static void | GenerateRandomTriplesBool (BinaryMtVector &bit_mts, std::size_t number_of_bit_mts) |
template<typename T > | |
static void | GenerateRandomTriples (IntegerMtVector< T > &mts, std::size_t number_of_mts) |
static void | RegisterHelperBool (OtProvider &ot_provider, std::unique_ptr< XcOtBitSender > &ots_sender, std::unique_ptr< XcOtBitReceiver > &ots_receiver, const BinaryMtVector &bit_mts, std::size_t number_of_bit_mts) |
template<typename T > | |
static void | RegisterHelper (OtProvider &ot_provider, std::list< std::unique_ptr< AcOtSender< T >>> &ots_sender, std::list< std::unique_ptr< AcOtReceiver< T >>> &ots_receiver, std::size_t max_batch_size, const IntegerMtVector< T > &mts, std::size_t number_of_mts) |
static void | ParseHelperBool (std::unique_ptr< XcOtBitSender > &ots_sender, std::unique_ptr< XcOtBitReceiver > &ots_receiver, BinaryMtVector &bit_mts) |
template<typename T > | |
static void | ParseHelper (std::list< std::unique_ptr< AcOtSender< T >>> &ots_sender, std::list< std::unique_ptr< AcOtReceiver< T >>> &ots_receiver, std::size_t max_batch_size, IntegerMtVector< T > &mts, std::size_t number_of_mts) |
template<typename T > | |
static constexpr auto | GetByteSize (const std::vector< T > &v) |
static std::vector< std::uint8_t > | Gather (const std::vector< std::uint16_t > &ds_8, const std::vector< std::uint32_t > &ds_16, const std::vector< std::uint64_t > &ds_32, const std::vector< __uint128_t > &ds_64) |
static std::vector< std::uint8_t > | Scatter (std::vector< std::uint16_t > &ds_8, std::vector< std::uint32_t > &ds_16, std::vector< std::uint64_t > &ds_32, std::vector< __uint128_t > &ds_64, const std::vector< std::uint8_t > &buffer) |
static void | ReconstructionHelper (std::vector< std::uint16_t > &xs_8, std::vector< std::uint32_t > &xs_16, std::vector< std::uint64_t > &xs_32, std::vector< __uint128_t > &xs_64, std::size_t number_of_parties, std::function< void(const std::vector< uint8_t > &)> broadcast_function, std::vector< ReusableFuture< std::vector< std::uint8_t >>> &futures) |
template<typename T > | |
static void | GenerateRandomPairs (SpVector< T > &sps, std::size_t number_of_sps) |
template<typename T > | |
static void | RegisterHelperSend (OtProvider &ot_provider, std::list< std::unique_ptr< AcOtSender< T >>> &ots_sender, std::size_t max_batch_size, const SpVector< T > &sps, std::size_t number_of_sps) |
template<typename T > | |
static void | RegisterHelperReceptor (OtProvider &ot_provider, std::list< std::unique_ptr< AcOtReceiver< T >>> &ots_receiver, std::size_t max_batch_size, const SpVector< T > &sps, std::size_t number_of_sps) |
template<typename T > | |
static void | ParseHelperSend (std::list< std::unique_ptr< AcOtSender< T >>> &ots_sender, std::size_t max_batch_size, SpVector< T > &sps, std::size_t number_of_sps) |
template<typename T > | |
static void | ParseHelperReceive (std::list< std::unique_ptr< AcOtReceiver< T >>> &ots_receiver, std::size_t max_batch_size, SpVector< T > &sps, std::size_t number_of_sps) |
void | HashPoint (curve25519::ge_p3 &output, const curve25519::ge_p3 &input) |
Blake2bCtx | NewBlakeCtx () |
void | Blake2b (std::uint8_t *message, std::uint8_t digest[64], std::size_t length, EVP_MD_CTX *context) |
void | Blake2b (std::uint8_t *message, std::uint8_t digest[64], std::size_t length, Blake2bCtx &b) |
template<typename WireType > | |
void | ArithmeticSimdifyOnlineImplementation (std::span< WirePointer > parent_wires, WirePointer output_wire) |
template<typename T > | |
void | ArithmeticGmwSimdifyOnline (std::span< WirePointer > parent_wires, WirePointer output_wire) |
template<typename T > | |
void | ArithmeticConstantSimdifyOnline (std::span< WirePointer > parent_wires, WirePointer output_wire) |
template<typename Allocator > | |
void | BitVectorSubsetImplementation (const BitVector< Allocator > &in, BitVector< Allocator > &out, std::span< const std::size_t > position_ids) |
template<typename WireType > | |
void | ArithmeticSubsetOnlineImplementation (WirePointer parent_wire, WirePointer output_wire, std::span< const std::size_t > position_ids) |
template<typename T > | |
void | ArithmeticGmwSubsetOnline (WirePointer parent_wire, WirePointer output_wire, std::span< const std::size_t > position_ids) |
template<typename T > | |
void | ArithmeticConstantSubsetOnline (WirePointer parent_wire, WirePointer output_wire, std::span< const std::size_t > position_ids) |
template<typename WireType > | |
void | ArithmeticUnsimdifyOnlineImplementation (WirePointer parent_wire, std::span< WirePointer > output_wires) |
template<typename T > | |
void | ArithmeticGmwUnsimdifyOnline (WirePointer parent_wire, std::span< WirePointer > output_wires) |
template<typename T > | |
void | ArithmeticConstantUnsimdifyOnline (WirePointer parent_wire, std::span< WirePointer > output_wires) |
template ShareWrapper | ShareWrapper::Convert< MpcProtocol::kArithmeticGmw > () const |
template ShareWrapper | ShareWrapper::Convert< MpcProtocol::kBooleanGmw > () const |
template ShareWrapper | ShareWrapper::Convert< MpcProtocol::kBmr > () const |
template ShareWrapper | ShareWrapper::Add< std::uint8_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Add< std::uint16_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Add< std::uint32_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Add< std::uint64_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Sub< std::uint8_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Sub< std::uint16_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Sub< std::uint32_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Sub< std::uint64_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Mul< std::uint8_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Mul< std::uint16_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Mul< std::uint32_t > (SharePointer share, SharePointer other) const |
template ShareWrapper | ShareWrapper::Mul< std::uint64_t > (SharePointer share, SharePointer other) const |
static double | ComputeDuration (const RunTimeStatistics::TimePointPair &tpp) |
template<typename C > | |
static C::value_type | At (const C &container, RunTimeStatistics::StatisticsId id) |
static std::string | FormatLine (std::string name, std::string unit, AccumulatedRunTimeStatistics::AccumulatorType accumulator, std::size_t field_width) |
std::string | PrintMotionInfo () |
std::string | PrintStatistics (const std::string &experiment_name, const AccumulatedRunTimeStatistics &execution_statistics, const AccumulatedCommunicationStatistics &communication_statistics) |
static double | ToMilliseconds (const RunTimeStatistics::TimePointPair &tpp) |
template<typename C > | |
C::value_type | At (const C &container, RunTimeStatistics::StatisticsId id) |
constexpr auto | NumberOfBitsToNumberOfBytes (std::size_t number_of_bits) |
void | TruncateToFitImplementation (std::byte *pointer, const std::size_t bit_size) |
void | SetImplementation (std::byte *pointer, const bool value, const std::size_t bit_size) noexcept |
void | SetAtImplementation (std::byte *pointer, const bool value, const std::size_t position) noexcept |
bool | GetImplementation (const std::byte *pointer, const std::size_t position) noexcept |
template<typename T , typename U > | |
bool | EqualImplementation (const T *pointer1, const U *pointer2, const std::size_t byte_size) |
template<typename T , typename U > | |
bool | AlignedEqualImplementation (const T *pointer1, const U *pointer2, const std::size_t byte_size) |
template<typename T , typename U > | |
void | XorImplementation (const T *input, U *result, const std::size_t byte_size) |
template<typename T , typename U > | |
void | AlignedXorImplementation (const T *input, U *result, const std::size_t byte_size) |
template<typename T , typename U > | |
void | AndImplementation (const T *input, U *result, const std::size_t byte_size) |
template<typename T , typename U > | |
void | AlignedAndImplementation (const T *input, U *result, const std::size_t byte_size) |
template<typename T , typename U > | |
void | OrImplementation (const T *input, U *result, const std::size_t byte_size) |
template<typename T , typename U > | |
void | AlignedOrImplementation (const T *input, U *result, const std::size_t byte_size) |
void | CopyImplementation (const std::size_t from, const std::size_t to, std::byte *source, std::byte *destination) |
template<> | |
std::vector< BitVector< StdAllocator > > | ToInput< float, std::true_type, StdAllocator > (float t) |
template<> | |
std::vector< BitVector< StdAllocator > > | ToInput< double, std::true_type, StdAllocator > (double t) |
template<> | |
std::vector< BitVector< StdAllocator > > | ToInput< float, std::true_type, StdAllocator > (const std::vector< float > &vector_of_floats) |
template<> | |
std::vector< BitVector< StdAllocator > > | ToInput< double, std::true_type, StdAllocator > (const std::vector< double > &vector_of_doubles) |
template<typename IntegralType , typename , typename Allocator > | |
std::vector< BitVector< Allocator > > | ToInput (IntegralType integral_value) |
template std::vector< BitVector< StdAllocator > > | ToInput (std::uint8_t) |
template std::vector< BitVector< StdAllocator > > | ToInput (std::uint16_t) |
template std::vector< BitVector< StdAllocator > > | ToInput (std::uint32_t) |
template std::vector< BitVector< StdAllocator > > | ToInput (std::uint64_t) |
template<typename IntegralType , typename , typename Allocator > | |
std::vector< BitVector< Allocator > > | ToInput (const std::vector< IntegralType > &input_vector) |
template std::vector< BitVector< StdAllocator > > | ToInput (const std::vector< std::uint8_t > &) |
template std::vector< BitVector< StdAllocator > > | ToInput (const std::vector< std::uint16_t > &) |
template std::vector< BitVector< StdAllocator > > | ToInput (const std::vector< std::uint32_t > &) |
template std::vector< BitVector< StdAllocator > > | ToInput (const std::vector< std::uint64_t > &) |
std::ostream & | operator<< (std::ostream &os, const BitSpan &bit_span) |
Output string representation of BitVector to std::ostream. More... | |
template<typename Allocator > | |
std::ostream & | operator<< (std::ostream &os, const BitVector< Allocator > &bit_vector) |
Output string representation of BitVector to std::ostream. More... | |
template<typename T , typename = std::enable_if_t<std::is_floating_point_v<T> || std::is_unsigned_v<T>>, typename Allocator = std::allocator<std::byte>> | |
std::vector< BitVector< Allocator > > | ToInput (const std::vector< T > &vector) |
Converts a vector of an unsigned integer type or a floating point type to a vector of BitVector. More... | |
template<typename UnsignedIntegralType , typename = std::enable_if_t<std::is_unsigned_v<UnsignedIntegralType>>, typename Allocator = std::allocator<std::byte>> | |
UnsignedIntegralType | ToOutput (std::vector< BitVector< Allocator >> bit_vectors) |
Converts a vector of BitVectors to a value of UnsignedIntegralType. More... | |
template<typename StackAllocator > | |
static void | worker_fctn (std::shared_ptr< pool_ctx > pool_ctx, boost::fibers::buffered_channel< FiberThreadPool::task_t > &task_queue, boost::fibers::barrier &barrier) |
std::size_t | DivideAndCeil (std::size_t dividend, std::size_t divisor) |
Divides two size_t and returns the ceiled quotient. More... | |
template<typename UnsignedIntegralType , typename = std::enable_if_t<std::is_unsigned_v<UnsignedIntegralType>>> | |
std::vector< UnsignedIntegralType > | RandomVector (std::size_t length) |
Returns a vector of length random unsigned integral values. More... | |
template<typename UnsignedIntegralType , typename = std::enable_if_t<std::is_unsigned_v<UnsignedIntegralType>>> | |
std::vector< std::uint8_t > | ToByteVector (const std::vector< UnsignedIntegralType > &values) |
Converts a vector of unsigned integral values to a vector of uint8_t. More... | |
template<typename UnsignedIntegralType , typename = std::enable_if_t<std::is_unsigned_v<UnsignedIntegralType>>> | |
std::vector< UnsignedIntegralType > | FromByteVector (const std::vector< std::uint8_t > &buffer) |
Converts a vector of uint8_t to a vector of unsigned integral values. More... | |
template<typename UnsignedIntegralType , typename = std::enable_if_t<std::is_unsigned_v<UnsignedIntegralType>>> | |
std::vector< UnsignedIntegralType > | FromByteVector (const flatbuffers::Vector< std::uint8_t > &buffer) |
Converts a flatbuffer vector of uint8_t to a vector of unsigned integral values. More... | |
template<typename T > | |
std::vector< T > | AddVectors (const std::vector< T > &a, const std::vector< T > &b) |
Adds each element in a and b and returns the result. More... | |
template<typename T > | |
std::vector< T > | SubVectors (const std::vector< T > &a, const std::vector< T > &b) |
Subtracts each element in a and b and returns the result. More... | |
template<typename T > | |
std::vector< T > | MultiplyVectors (std::vector< T > a, std::vector< T > b) |
Multiplies each element in a and b and returns the result. More... | |
template<typename T > | |
std::vector< T > | AddVectors (std::vector< std::vector< T >> &vectors) |
Performs the AddVectors operation on an arbitrary number of vectors. More... | |
template<typename T > | |
std::vector< T > | AddVectors (std::vector< std::vector< T >> &&vectors) |
Performs the AddVectors operation on an arbitrary number of vectors. More... | |
template<typename T > | |
std::vector< T > | RestrictAddVectors (const std::vector< T > &a, const std::vector< T > &b) |
Adds each element in a and b and returns the result. It is assumed that the vectors do not overlap. More... | |
template<typename T > | |
std::vector< T > | RestrictSubVectors (const std::vector< T > &a, const std::vector< T > &b) |
Subtracts each element in a and b and returns the result. It is assumed that the vectors do not overlap. More... | |
template<typename T > | |
std::vector< T > | RestrictMulVectors (const std::vector< T > &a, const std::vector< T > &b) |
Mulitiplies each element in a and b and returns the result. It is assumed that the vectors do not overlap. More... | |
template<typename T > | |
T | SumReduction (const std::vector< T > &values) |
Returns the sum of each element in values . More... | |
template<typename T > | |
T | SubReduction (const std::vector< T > &values) |
Returns the difference of each element in values . More... | |
template<typename T > | |
T | MulReduction (const std::vector< T > &values) |
Returns the product of each element in values . More... | |
template<typename T > | |
std::vector< T > | RowSumReduction (const std::vector< std::vector< T >> &values) |
Returns the sum of each row in a matrix. More... | |
template<typename T > | |
std::vector< T > | RowSubReduction (const std::vector< std::vector< T >> &values) |
Returns the difference of each row in a matrix. More... | |
template<typename T > | |
std::vector< T > | RowMulReduction (const std::vector< std::vector< T >> &values) |
Returns the product of each row in a matrix. More... | |
template<typename UnsignedIntegralType , typename = std::enable_if_t<std::is_unsigned_v<UnsignedIntegralType>>> | |
bool | IsPowerOfTwo (UnsignedIntegralType x) |
Check if unisgned integral value is a power of two. More... | |
std::string | Hex (const std::uint8_t *values, std::size_t n) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
std::string | Hex (const std::byte *values, std::size_t n) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
template<std::size_t N> | |
std::string | Hex (const std::array< std::byte, N > &values) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
template<std::size_t N> | |
std::string | Hex (const std::array< std::uint8_t, N > &values) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
std::string | Hex (const std::vector< std::uint8_t > &values) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
std::string | Hex (const std::vector< std::byte > &values) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
std::string | Hex (const std::vector< std::uint8_t > &&values) |
Returns a hexadecimal string representation of the bytes stored in values . More... | |
template<typename T > | |
std::string | to_string (std::vector< T > values) |
Returns a string representation of the std::vector values . More... | |
template<typename T > | |
bool | Vectors (const std::vector< T > &a, const std::vector< T > &b) |
XXX the std library implements operators for vector comparisions. More... | |
template<typename T > | |
bool | Dimensions (const std::vector< std::vector< T >> &values) |
Checks if all the vectors have the same size. More... | |
constexpr std::size_t | BitsToBytes (const std::size_t bits) |
Returns the number of bytes necessary to store bits bits. More... | |
template<typename R , typename MutexType , typename ConditionVariableType > | |
void | swap (ReusablePromise< R, MutexType, ConditionVariableType > &lhs, ReusablePromise< R, MutexType, ConditionVariableType > &rhs) noexcept |
std::string | GetCmdLine () |
std::size_t | GetPid () |
std::string | GetHostname () |
std::string | GetUsername () |
void | ThreadSetName (std::thread &thread, const std::string &name) |
std::string | to_string (PrimitiveOperationType t) |
std::string | to_string (IntegerOperationType p) |
std::string | to_string (MpcProtocol p) |
const char * | GetGitVersion () |
const char * | GetGitCommit () |
const char * | GetGitBranch () |
Variables | |
constexpr std::byte | kSetBitMask [] |
constexpr std::byte | kUnsetBitMask [] |
constexpr std::byte | TruncationBitMask [] |
constexpr bool | kDebug {false} |
constexpr float | kVersion {0.01} |
constexpr std::string_view | kRootDir {"/root/MOTION"} |
constexpr std::size_t | kAlignment {16} |
constexpr std::string_view | kFrameworkName {"MOTION"} |
constexpr std::size_t | kMb {1024 * 1024} |
constexpr bool | kVerboseDebugWish {false} |
constexpr bool | kVerboseDebug {kDebug && kVerboseDebugWish} |
constexpr std::size_t | kAesKeySize {16} |
constexpr std::size_t | kAesBlockSize {16} |
constexpr std::size_t | kAesIvSize {kAesBlockSize / 2} |
constexpr std::size_t | kMessageSizeBytelen {sizeof(std::uint32_t)} |
constexpr std::uint32_t | kMaxMessageSize {std::numeric_limits<std::uint32_t>::max() / 2} |
constexpr std::size_t | kKappa {128} |
constexpr std::size_t | kFiberStackSize = kDebug ? 32 * 1024 : 14 * 1024 |
constexpr FiberStackAllocator | kFiberStackAllocator {FiberStackAllocator::kFixedSize} |
using encrypto::motion::AlignedAllocator = typedef boost::alignment::aligned_allocator<std::byte, kAlignment> |
using encrypto::motion::AlignedBitVector = typedef BitVector<AlignedAllocator> |
typedef std::shared_ptr< Backend > encrypto::motion::BackendPointer |
using encrypto::motion::BaseOtMessages = typedef std::array<std::array<std::byte, 16>, kKappa> |
using encrypto::motion::Blake2bCtx = typedef std::unique_ptr<EVP_MD_CTX, std::function<void(EVP_MD_CTX*)> > |
using encrypto::motion::BooleanSharePointer = typedef std::shared_ptr<BooleanShare> |
using encrypto::motion::BooleanWirePointer = typedef std::shared_ptr<BooleanWire> |
typedef std::shared_ptr< Configuration > encrypto::motion::ConfigurationPointer |
using encrypto::motion::DefaultRng = typedef Aes128CtrRng |
typedef std::shared_ptr< Gate > encrypto::motion::GatePointer |
typedef std::shared_ptr< InputGate > encrypto::motion::InputGatePointer |
using encrypto::motion::IsUnsignedInt = typedef std::enable_if_t<std::conjunction_v<std::is_integral<T>, std::is_unsigned<T>, std::negation<std::is_same<T, bool> >> > |
typedef std::shared_ptr< Logger > encrypto::motion::LoggerPointer |
using encrypto::motion::LoggerType = typedef boost::log::sources::severity_channel_logger<boost::log::trivial::severity_level, std::size_t> |
using encrypto::motion::OutputGatePointer = typedef std::shared_ptr<OutputGate> |
using encrypto::motion::PartyPointer = typedef std::unique_ptr<Party> |
typedef std::shared_ptr< Register > encrypto::motion::RegisterPointer |
using encrypto::motion::ReusableFiberFuture = typedef ReusableFuture<R, boost::fibers::mutex, boost::fibers::condition_variable> |
using encrypto::motion::ReusableFiberPromise = typedef ReusablePromise<R, boost::fibers::mutex, boost::fibers::condition_variable> |
typedef std::shared_ptr< Share > encrypto::motion::SharePointer |
using encrypto::motion::StatId = typedef RunTimeStatistics::StatisticsId |
using encrypto::motion::StdAllocator = typedef std::allocator<std::byte> |
using encrypto::motion::SynchronizedFiberQueue = typedef BasicSynchronizedQueue<T, boost::fibers::mutex, boost::fibers::condition_variable> |
using encrypto::motion::SynchronizedQueue = typedef BasicSynchronizedQueue<T, std::mutex, std::condition_variable> |
using encrypto::motion::TypeMap = typedef decltype(detail::MakeTypeMap<Value, Ts...>()) |
typedef std::shared_ptr< Wire > encrypto::motion::WirePointer |
enum encrypto::motion::BaseOtDataType : unsigned int |
|
strong |
|
strong |
|
strong |
|
strong |
|
strong |
enum encrypto::motion::OtExtensionDataType : unsigned int |
|
strong |
enum encrypto::motion::OtProtocol : unsigned int |
|
strong |
|
strong |
enum encrypto::motion::SharedBitsMessageType : std::uint8_t |
|
inline |
Adds each element in a
and b
and returns the result.
T | type of the elements in the vectors. T must provide the += operator. |
a | |
b |
a
and b
must be of equal size.
|
inline |
Performs the AddVectors operation on an arbitrary number of vectors.
T | type of the elements in the vectors. T must provide the += operator. |
vectors | A vector of vectors. |
vectors
must be of equal size.
|
inline |
Performs the AddVectors operation on an arbitrary number of vectors.
T | type of the elements in the vectors. T must provide the += operator. |
vectors | A vector of vectors. |
vectors
must be of equal size.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
void encrypto::motion::ArithmeticConstantSimdifyOnline | ( | std::span< WirePointer > | parent_wires, |
WirePointer | output_wire | ||
) |
void encrypto::motion::ArithmeticConstantSubsetOnline | ( | WirePointer | parent_wire, |
WirePointer | output_wire, | ||
std::span< const std::size_t > | position_ids | ||
) |
void encrypto::motion::ArithmeticConstantUnsimdifyOnline | ( | WirePointer | parent_wire, |
std::span< WirePointer > | output_wires | ||
) |
void encrypto::motion::ArithmeticGmwSimdifyOnline | ( | std::span< WirePointer > | parent_wires, |
WirePointer | output_wire | ||
) |
void encrypto::motion::ArithmeticGmwSubsetOnline | ( | WirePointer | parent_wire, |
WirePointer | output_wire, | ||
std::span< const std::size_t > | position_ids | ||
) |
void encrypto::motion::ArithmeticGmwUnsimdifyOnline | ( | WirePointer | parent_wire, |
std::span< WirePointer > | output_wires | ||
) |
void encrypto::motion::ArithmeticSimdifyOnlineImplementation | ( | std::span< WirePointer > | parent_wires, |
WirePointer | output_wire | ||
) |
void encrypto::motion::ArithmeticSubsetOnlineImplementation | ( | WirePointer | parent_wire, |
WirePointer | output_wire, | ||
std::span< const std::size_t > | position_ids | ||
) |
void encrypto::motion::ArithmeticUnsimdifyOnlineImplementation | ( | WirePointer | parent_wire, |
std::span< WirePointer > | output_wires | ||
) |
C::value_type encrypto::motion::At | ( | const C & | container, |
RunTimeStatistics::StatisticsId | id | ||
) |
|
static |
|
constexpr |
Returns the number of bytes necessary to store bits
bits.
bits |
void encrypto::motion::BitVectorSubsetImplementation | ( | const BitVector< Allocator > & | in, |
BitVector< Allocator > & | out, | ||
std::span< const std::size_t > | position_ids | ||
) |
void encrypto::motion::Blake2b | ( | std::uint8_t * | message, |
std::uint8_t | digest[64], | ||
std::size_t | length, | ||
Blake2bCtx & | b | ||
) |
void encrypto::motion::Blake2b | ( | std::uint8_t * | message, |
std::uint8_t | digest[64], | ||
std::size_t | length, | ||
EVP_MD_CTX * | context | ||
) |
|
static |
|
inline |
|
inline |
Checks if all the vectors have the same size.
values | A vector of vectors. |
std::size_t encrypto::motion::DivideAndCeil | ( | std::size_t | dividend, |
std::size_t | divisor | ||
) |
Divides two size_t and returns the ceiled quotient.
dividend | |
divisor |
|
inline |
|
static |
|
inline |
Converts a flatbuffer vector of uint8_t to a vector of unsigned integral values.
UnsignedIntegralType |
buffer |
|
inline |
Converts a vector of uint8_t to a vector of unsigned integral values.
UnsignedIntegralType |
buffer |
|
static |
|
static |
|
static |
|
static |
|
staticconstexpr |
std::string encrypto::motion::GetCmdLine | ( | ) |
const char* encrypto::motion::GetGitBranch | ( | ) |
const char* encrypto::motion::GetGitCommit | ( | ) |
const char* encrypto::motion::GetGitVersion | ( | ) |
std::string encrypto::motion::GetHostname | ( | ) |
|
inlinenoexcept |
std::size_t encrypto::motion::GetPid | ( | ) |
std::string encrypto::motion::GetUsername | ( | ) |
void encrypto::motion::HashPoint | ( | curve25519::ge_p3 & | output, |
const curve25519::ge_p3 & | input | ||
) |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values | |
n | Number of bytes. |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values | |
n | Number of bytes. |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values |
|
inline |
Returns a hexadecimal string representation of the bytes stored in values
.
values |
bool encrypto::motion::IsPowerOfTwo | ( | UnsignedIntegralType | x | ) |
Check if unisgned integral value is a power of two.
UnsignedIntegralType |
x |
std::vector< std::unique_ptr< Party > > encrypto::motion::MakeLocallyConnectedParties | ( | const std::size_t | number_of_parties, |
std::uint16_t | port, | ||
const bool | logging = false |
||
) |
constructs number_of_parties motion::Party's locally connected via TCP.
number_of_parties | Number of motion::Party's to construct. |
port | TCP port offset. |
logging | Enables/disables logging completely. |
|
inline |
Returns the product of each element in values
.
T | type of the elements in the vectors. T must provide the *= operator. |
values |
|
inline |
Multiplies each element in a
and b
and returns the result.
T | type of the elements in the vectors. T must provide the *= operator. |
a | |
b |
a
and b
must be of equal size. Blake2bCtx encrypto::motion::NewBlakeCtx | ( | ) |
|
constexpr |
std::ostream & encrypto::motion::operator<< | ( | std::ostream & | os, |
const BitSpan & | bit_span | ||
) |
Output string representation of BitVector to std::ostream.
std::ostream& encrypto::motion::operator<< | ( | std::ostream & | os, |
const BitVector< Allocator > & | bit_vector | ||
) |
Output string representation of BitVector to std::ostream.
|
inline |
|
static |
|
static |
|
static |
|
static |
std::string encrypto::motion::PrintMotionInfo | ( | ) |
std::string encrypto::motion::PrintStatistics | ( | const std::string & | experiment_name, |
const AccumulatedRunTimeStatistics & | execution_statistics, | ||
const AccumulatedCommunicationStatistics & | communication_statistics | ||
) |
|
inline |
Returns a vector of length
random unsigned integral values.
UnsignedIntegralType |
length |
|
static |
|
static |
|
static |
|
static |
|
static |
|
inline |
Adds each element in a
and b
and returns the result. It is assumed that the vectors do not overlap.
T | type of the elements in the vectors. T must provide the binary + operator. |
a | |
b |
a
and b
must be of equal size.
|
inline |
Mulitiplies each element in a
and b
and returns the result. It is assumed that the vectors do not overlap.
T | type of the elements in the vectors. T must provide the binary * operator. |
a | |
b |
a
and b
must be of equal size.
|
inline |
Subtracts each element in a
and b
and returns the result. It is assumed that the vectors do not overlap.
T | type of the elements in the vectors. T must provide the binary - operator. |
a | |
b |
a
and b
must be of equal size.
|
inline |
Returns the product of each row in a matrix.
T | type of the elements in the vectors. T must provide the *= operator. |
values | A vector of vectors. |
vectors
must be of equal size.
|
inline |
Returns the difference of each row in a matrix.
T | type of the elements in the vectors. T must provide the -= operator. |
values | A vector of vectors. |
vectors
must be of equal size.
|
inline |
Returns the sum of each row in a matrix.
T | type of the elements in the vectors. T must provide the += operator. |
values | A vector of vectors. |
vectors
must be of equal size.
|
static |
|
inlinenoexcept |
|
inlinenoexcept |
template ShareWrapper encrypto::motion::ShareWrapper::Add< std::uint16_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Add< std::uint32_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Add< std::uint64_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Add< std::uint8_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Convert< MpcProtocol::kArithmeticGmw > | ( | ) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Convert< MpcProtocol::kBmr > | ( | ) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Convert< MpcProtocol::kBooleanGmw > | ( | ) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Mul< std::uint16_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Mul< std::uint32_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Mul< std::uint64_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Mul< std::uint8_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Sub< std::uint16_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Sub< std::uint32_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Sub< std::uint64_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
template ShareWrapper encrypto::motion::ShareWrapper::Sub< std::uint8_t > | ( | SharePointer | share, |
SharePointer | other | ||
) | const |
|
inline |
Returns the difference of each element in values
.
T | type of the elements in the vectors. T must provide the -= operator. |
values |
|
inline |
Subtracts each element in a
and b
and returns the result.
T | type of the elements in the vectors. T must provide the -= operator. |
a | |
b |
a
and b
must be of equal size.
|
inline |
Returns the sum of each element in values
.
T | type of the elements in the vectors. T must provide the += operator. |
values |
|
noexcept |
void encrypto::motion::ThreadSetName | ( | std::thread & | thread, |
const std::string & | name | ||
) |
|
inline |
|
inline |
|
inline |
|
inline |
Returns a string representation of the std::vector values
.
T | Type of the element in the std::vector. Must provide an overload of to_string. |
values |
|
inline |
Converts a vector of unsigned integral values to a vector of uint8_t.
UnsignedIntegralType |
values |
std::vector<BitVector<Allocator> > encrypto::motion::ToInput | ( | const std::vector< IntegralType > & | input_vector | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | const std::vector< std::uint16_t > & | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | const std::vector< std::uint32_t > & | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | const std::vector< std::uint64_t > & | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | const std::vector< std::uint8_t > & | ) |
std::vector<BitVector<Allocator> > encrypto::motion::ToInput | ( | const std::vector< T > & | vector | ) |
Converts a vector of an unsigned integer type or a floating point type to a vector of BitVector.
A vector of BitVectors allows to interleave multiple arithmetic values intended to be used in a SIMD way. Let x be an arithmetic value, with x0,...,xn being its little-endian bit representation. This value is then represented by a value v of type std::vector<BitVector> with v[j][0] == xj. Now, if we interleave x with y and z of the same bit representation, then: v[j][0] == xj, v[j][1] == yj, v[j][2] == zj.
unsigned_integral_vector.size()
.UnsignedIntegralType
. T |
vector |
std::vector<BitVector<Allocator> > encrypto::motion::ToInput | ( | IntegralType | integral_value | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | std::uint16_t | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | std::uint32_t | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | std::uint64_t | ) |
template std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput | ( | std::uint8_t | ) |
std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput< double, std::true_type, StdAllocator > | ( | const std::vector< double > & | vector_of_doubles | ) |
std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput< double, std::true_type, StdAllocator > | ( | double | t | ) |
std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput< float, std::true_type, StdAllocator > | ( | const std::vector< float > & | vector_of_floats | ) |
std::vector<BitVector<StdAllocator> > encrypto::motion::ToInput< float, std::true_type, StdAllocator > | ( | float | t | ) |
|
static |
UnsignedIntegralType encrypto::motion::ToOutput | ( | std::vector< BitVector< Allocator >> | bit_vectors | ) |
Converts a vector of BitVectors to a value of UnsignedIntegralType.
A vector of BitVectors allows to interleave multiple arithmetic values intended to be used in a SIMD way. Let x be an arithmetic value, with x0,...,xn being its little-endian bit representation. This value is then represented by a value v of type std::vector<BitVector> with v[j][0] == xj. Now, if we interleave x with y and z of the same bit representation, then: v[j][0] == xj, v[j][1] == yj, v[j][2] == zj.
bit_vectors
is equal to number of bits in UnsignedIntegralType
.bit_vectors
has size equal 1. UnsignedIntegralType |
bit_vectors |
|
inline |
|
inline |
XXX the std library implements operators for vector comparisions.
|
static |
|
inline |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |