Params.h 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #pragma once
  2. #include "openfhe/pke/scheme/gen-cryptocontext-params.h"
  3. #include "openfhe/pke/scheme/bfvrns/gen-cryptocontext-bfvrns-params.h"
  4. #include "openfhe/pke/scheme/bgvrns/gen-cryptocontext-bgvrns-params.h"
  5. #include "openfhe/pke/scheme/ckksrns/gen-cryptocontext-ckksrns-params.h"
  6. namespace openfhe
  7. {
  8. using SCHEME = lbcrypto::SCHEME;
  9. using SecretKeyDist = lbcrypto::SecretKeyDist;
  10. using ProxyReEncryptionMode = lbcrypto::ProxyReEncryptionMode;
  11. using MultipartyMode = lbcrypto::MultipartyMode;
  12. using ExecutionMode = lbcrypto::ExecutionMode;
  13. using DecryptionNoiseMode = lbcrypto::DecryptionNoiseMode;
  14. using KeySwitchTechnique = lbcrypto::KeySwitchTechnique;
  15. using ScalingTechnique = lbcrypto::ScalingTechnique;
  16. using SecurityLevel = lbcrypto::SecurityLevel;
  17. using EncryptionTechnique = lbcrypto::EncryptionTechnique;
  18. using MultiplicationTechnique = lbcrypto::MultiplicationTechnique;
  19. using COMPRESSION_LEVEL = lbcrypto::COMPRESSION_LEVEL;
  20. using Params = lbcrypto::Params;
  21. using ParamsBFVRNS = lbcrypto::CCParams<lbcrypto::CryptoContextBFVRNS>;
  22. using ParamsBGVRNS = lbcrypto::CCParams<lbcrypto::CryptoContextBGVRNS>;
  23. using ParamsCKKSRNS = lbcrypto::CCParams<lbcrypto::CryptoContextCKKSRNS>;
  24. // Generator functions
  25. [[nodiscard]] std::unique_ptr<Params> GenParamsByScheme(const SCHEME scheme);
  26. [[nodiscard]] std::unique_ptr<Params> GenParamsByVectorOfString(
  27. const std::vector<std::string>& vals);
  28. [[nodiscard]] std::unique_ptr<ParamsBFVRNS> GenParamsBFVRNS();
  29. [[nodiscard]] std::unique_ptr<ParamsBFVRNS> GenParamsBFVRNSbyVectorOfString(
  30. const std::vector<std::string>& vals);
  31. [[nodiscard]] std::unique_ptr<ParamsBGVRNS> GenParamsBGVRNS();
  32. [[nodiscard]] std::unique_ptr<ParamsBGVRNS> GenParamsBGVRNSbyVectorOfString(
  33. const std::vector<std::string>& vals);
  34. [[nodiscard]] std::unique_ptr<ParamsCKKSRNS> GenParamsCKKSRNS();
  35. [[nodiscard]] std::unique_ptr<ParamsCKKSRNS> GenParamsCKKSRNSbyVectorOfString(
  36. const std::vector<std::string>& vals);
  37. } // openfhe