IBM-HElib / HElib

HElib is an open-source software library that implements homomorphic encryption. It supports the BGV scheme with bootstrapping and the Approximate Number CKKS scheme. HElib also includes optimizations for efficient homomorphic evaluation, focusing on effective use of ciphertext packing techniques and on the Gentry-Halevi-Smart optimizations.
https://ibm-helib.github.io/HElib/
Other
21 stars 5 forks source link

Optimal parameter generation #14

Open taqtiqa-mark opened 7 months ago

taqtiqa-mark commented 7 months ago

I'm hoping the issue of "optimal" parameter generation is of interest to the HELayers project.

Specifically, the results implemented in fhegen.

If so, you'll notice the parameters for the BGV implementation in HELib are not produced.

I'm having some difficulty in working out the mapping for the HELib configuration, and was hoping the maintainers here may have some insight they are able to share. A particular issue I see is accommodating the different configuration in the binary and packed arithmetic examples.

My hope/intention is to make a PR to the fhegen project adding the HELib settings, so it will help if there is an authoritative opinion on what the mapping is from the fhegen parameters to the HELib settings for BGV.

Appreciate any hints or tips.

boland25 commented 7 months ago

I see what you are saying, the BGV config settings on HElib are different than what you are doing with the other schemes. Specifically you are looking to map these settings

 p The prime modulos.
 m Cyclotomic polynomial, defines phi(m).
 r Hensel lifting.
 L Number of bits of the modulus chain.

To settings like this...

     polynomial degree
     coefficient modulus
 plaintext modulus
 multiplication depth

I wonder if any of my colleagues can speak to this better than me. @aehud @omri-so Do you know anyone who has experience trying to understand these settings?