25 : m_threshold (0), m_channelsReady(0), m_channelsFinished(0)
28 unsigned int GetThreshold()
const {
return m_threshold;}
29 void AddOutputChannel(word32 channelId);
30 void ChannelData(word32 channelId,
const byte *inString,
size_t length,
bool messageEnd);
31 lword InputBuffered(word32 channelId)
const;
34 size_t ChannelPut2(
const std::string &channel,
const byte *begin,
size_t length,
int messageEnd,
bool blocking)
38 ChannelData(StringToWord<word32>(channel), begin, length, messageEnd != 0);
43 virtual void FlushOutputQueues();
44 virtual void OutputMessageEnds();
46 unsigned int InsertInputChannel(word32 channelId);
47 unsigned int LookupInputChannel(word32 channelId)
const;
48 void ComputeV(
unsigned int);
49 void PrepareInterpolation();
50 void ProcessInputQueues();
52 typedef std::map<word32, unsigned int> InputChannelMap;
53 InputChannelMap m_inputChannelMap;
54 InputChannelMap::iterator m_lastMapPosition;
55 std::vector<MessageQueue> m_inputQueues;
56 std::vector<word32> m_inputChannelIds, m_outputChannelIds, m_outputToInput;
57 std::vector<std::string> m_outputChannelIdStrings;
58 std::vector<ByteQueue> m_outputQueues;
60 unsigned int m_channelsReady, m_channelsFinished;
61 std::vector<SecBlock<word32> > m_v;
81 size_t Put2(
const byte *begin,
size_t length,
int messageEnd,
bool blocking);
82 bool Flush(
bool hardFlush,
int propagation=-1,
bool blocking=
true) {
return m_ida.Flush(hardFlush, propagation, blocking);}
105 void FlushOutputQueues();
106 void OutputMessageEnds();
122 : m_ida(new
OutputProxy(*this, true)), m_pad(false), m_nextChannel(0)
129 size_t Put2(
const byte *begin,
size_t length,
int messageEnd,
bool blocking);
130 bool Flush(
bool hardFlush,
int propagation=-1,
bool blocking=
true) {
return m_ida.Flush(hardFlush, propagation, blocking);}
135 unsigned int m_nextChannel;
147 :
RawIDA(attachment), m_pad(false)
153 void FlushOutputQueues();
154 void OutputMessageEnds();
164 : m_possiblePadding(
false), m_zeroCount(0) {
Detach(attachment);}
167 {CRYPTOPP_UNUSED(parameters); m_possiblePadding =
false;}
168 size_t Put2(
const byte *begin,
size_t length,
int messageEnd,
bool blocking);
171 bool GetPossiblePadding()
const {
return m_possiblePadding;}
174 bool m_possiblePadding;
void IsolatedInitialize(const NameValuePairs ¶meters)
Initialize or reinitialize this object, without signal propagation.
Utility functions for the Crypto++ library.
Secret sharing and information dispersal base class.
Filter class that is a proxy for a sink.
Abstract base classes that provide a uniform interface to this library.
size_t ChannelPut2(const std::string &channel, const byte *begin, size_t length, int messageEnd, bool blocking)
Input multiple bytes for processing on a channel.
Interface for random number generators.
bool Flush(bool hardFlush, int propagation=-1, bool blocking=true)
Flush buffered input and/or output, with signal propagation.
Interface for custom flush signals propagation.
Classes for multiple named channels.
Classes and functions for secure memory allocations.
void Detach(BufferedTransformation *newAttachment=NULL)
Replace an attached transformation.
AlgorithmParameters MakeParameters(const char *name, const T &value, bool throwIfNotUsed=true)
Create an object that implements NameValuePairs.
SecretSharing(RandomNumberGenerator &rng, int threshold, int nShares, BufferedTransformation *attachment=NULL, bool addPadding=true)
Construct a SecretSharing.
size_t Put2(const byte *begin, size_t length, int messageEnd, bool blocking)
Input multiple bytes for processing.
Data structure used to store byte strings.
Implementation of BufferedTransformation's attachment interface.
const NameValuePairs g_nullNameValuePairs
An empty set of name-value pairs.
Base class for unflushable filters.
Provides auto signaling support.
Implementation of BufferedTransformation's attachment interface.
void IsolatedInitialize(const NameValuePairs ¶meters=g_nullNameValuePairs)
Initialize or reinitialize this object, without signal propagation.
SecretRecovery(int threshold, BufferedTransformation *attachment=NULL, bool removePadding=true)
Construct a SecretRecovery.
Crypto++ library namespace.
Shamir's Secret Sharing Algorithm.
Multiple channels support for custom signal processing.
Shamir's Secret Sharing Algorithm.
Interface for retrieving values given their names.