Template Class KeySwitchBase
Defined in File keyswitch-base.h
Page Contents
Template Parameter Order
class Element
Class Documentation
-
template<class Element>
class lbcrypto::KeySwitchBase Abstract class for LBC keyswitching.
- Template Parameters
Element – a secret key type instantiation
Public Functions
-
inline KeySwitchBase()
-
inline virtual ~KeySwitchBase()
-
inline virtual EvalKey<Element> KeySwitchGenInternal(const PrivateKey<Element> oldPrivateKey, const PrivateKey<Element> newPrivateKey) const
Method for KeySwitchGen
- Parameters
&originalPrivateKey – Original private key used for encryption.
&newPrivateKey – New private key to generate the keyswitch hint.
*KeySwitchHint – is where the resulting keySwitchHint will be placed.
-
inline virtual EvalKey<Element> KeySwitchGenInternal(const PrivateKey<Element> oldPrivateKey, const PrivateKey<Element> newPrivateKey, const EvalKey<Element> evalKey) const
-
inline virtual EvalKey<Element> KeySwitchGenInternal(const PrivateKey<Element> oldPrivateKey, const PublicKey<Element> newPublicKey) const
-
virtual Ciphertext<Element> KeySwitch(ConstCiphertext<Element> ciphertext, const EvalKey<Element> evalKey) const
-
inline virtual void KeySwitchInPlace(Ciphertext<Element> &ciphertext, const EvalKey<Element> evalKey) const
-
inline virtual Ciphertext<Element> KeySwitchExt(ConstCiphertext<Element> ciphertext, bool addFirst) const
-
inline virtual Ciphertext<Element> KeySwitchDown(ConstCiphertext<Element> ciphertext) const
-
inline virtual Element KeySwitchDownFirstElement(ConstCiphertext<Element> ciphertext) const
-
inline virtual std::shared_ptr<std::vector<Element>> KeySwitchCore(const Element &a, const EvalKey<Element> evalKey) const