HelibBitwiseBgvContext#
Currently, this API is unsupported in Python
-
class HelibBitwiseBgvContext : public helayers::HelibBitwiseContext#
HeContext used to initilize classes working on bitwise ciphertexts under Helib’s library and BGV scheme.
This is a beta, not tested version. Currently there is no support for bootstrapping.
Public Functions
-
inline HelibBitwiseBgvContext()#
A constructor.
-
inline HelibBitwiseBgvContext(int numBits)#
A constructor.
- Parameters:
numBits – The number of bits held by ciphertexts created by this context.
-
inline virtual ~HelibBitwiseBgvContext()#
-
void init(unsigned long m, unsigned long r, unsigned long L, unsigned long c)#
Initializes the underlying helib BGV scheme with the given “m”, “r” and “l”.
2 used as the modolus of the BGV scheme.
- Parameters:
m – Cyclotomic polynomial, defines phi(m).
r – Hensel lifting.
L – Number of bits of the modulus chain.
c – Number of columns of Key-Switching matix.
-
virtual void init(const HelibConfig &conf) override#
Initializes context with given configuration.
- Parameters:
conf – [in] user’s configuration
-
void initWithBootStrapping(unsigned long m, unsigned long r, unsigned long L, unsigned long c, const std::vector<long> &mvec, const std::vector<long> &gens, const std::vector<long> &ords)#
Initializes this HelibBitwiseBgvContext such that the ciphertexts created with it will be bootstrapable.
- Parameters:
m – Cyclotomic polynomial, defines phi(m).
r – Hensel lifting.
L – Number of bits of the modulus chain.
c – Number of columns of Key-Switching matix.
mvec – Factorisation of m.
gens – Generating set of Zm* group.
ords – Orders of the generators in gens vector.
-
virtual std::shared_ptr<AbstractCiphertext> createAbstractCipher() const override#
Returns a pointer to HelibBitwseBgvCiphertext, initialized with this HelibBitwseBgvCiphertext.
-
virtual std::shared_ptr<AbstractPlaintext> createAbstractPlain() const override#
Returns a pointer to HelibBitwseBgvCiphertext, initialized with this HelibBitwseBgvCiphertext.
-
virtual std::shared_ptr<AbstractEncoder> getEncoder() const override#
Returns a pointer to HelibBitwseBgvCiphertext, initialized with this HelibBitwseBgvCiphertext.
-
virtual std::shared_ptr<AbstractBitwiseEvaluator> getBitwiseEvaluator() const override#
Returns a pointer to HelibBitwseBgvCiphertext, initialized with this HelibBitwseBgvCiphertext.
-
std::shared_ptr<AbstractEncoder> getEncoder(int scale)#
Returns a pointer to HelibBitwseBgvCiphertext, initialized with this HelibBitwseBgvCiphertext and the given scale.
- Parameters:
scale – [in] The default scale for ciphertexts and plaintexts created with the returned AbstractEncoder.
-
virtual void printSignature(std::ostream &out) const override#
Prints a message summarizing the configuration of this HelibBitwseBgvCiphertext.
-
inline virtual const helib::EncryptedArray &getEncryptedArray() const#
Returns the EncryptedArray used to perform operation on ciphertexts and plaintexts that are initialized with this scheme.
-
inline virtual std::string getSchemeName() const override#
Returns the name of this scheme (i.e. “BitwiseBGV”).
-
inline HelibBitwiseBgvContext()#