SCALE-MAMBA FHE Parameters Generation for Large Primes

62 views
Skip to first unread message

Ryan Deng

unread,
Sep 2, 2019, 11:14:13 PM9/2/19
to SPDZ/SCALE-MAMBA Discussion Group
When I try to run ./Setup.x and setup parameters for a Full-Threshold scheme with a prime that is longer than ~230 bits, I get the error message: 
"terminate called after throwing an instance of "FHE_Params
what(): FHE parameters cannot be computed"

Is there any modifications I need to make so that larger primes can be used? I am looking to use a prime field of about 256 bits.

I tried modifying the MAX_MOD_SZ variable, but it didn't change anything.

Nigel Smart

unread,
Sep 3, 2019, 2:13:59 AM9/3/19
to sp...@googlegroups.com
Hi

This is because the table in

src/FHE/FHE_Params.cpp

does not include values big enough for you.  This corresponds
to the table in the FHE section in the Documentation. You
basically will need to compute a new line of this table and add
it in corresponding to degree 65536

Cheers

Nigel
--
You received this message because you are subscribed to the Google Groups "SPDZ/SCALE-MAMBA Discussion Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to spdz+uns...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/spdz/0d5760bc-bcc3-48c8-80be-15ae15790cd2%40googlegroups.com.

signature.asc

Davide Ferrari

unread,
Feb 18, 2022, 5:58:44 AM2/18/22
to SPDZ/SCALE-MAMBA Discussion Group
Hi, could you please elaborate a bit more?
I am also facing the same issue and I don't quite understand how to use the sage code in the documentation.

Thanks

Nigel Smart

unread,
Feb 18, 2022, 8:52:48 AM2/18/22
to sp...@googlegroups.com
Not tested this on a recent download of the lwe-estimator

But basically you are going to need a huge value of N,
2^17 say. So change the range of n in the code on
page 117 of the manual to run from (17,18) just
to get the data for this N size.

Nigel
>> <https://groups.google.com/d/msgid/spdz/0d5760bc-bcc3-48c8-80be-15ae15790cd2%40googlegroups.com?utm_medium=email&utm_source=footer>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "SPDZ/SCALE-MAMBA Discussion Group" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to spdz+uns...@googlegroups.com
> <mailto:spdz+uns...@googlegroups.com>.
> To view this discussion on the web, visit
> https://groups.google.com/d/msgid/spdz/1d7ad1b8-c60e-4f2f-b8d5-e196dc6928e4n%40googlegroups.com
> <https://groups.google.com/d/msgid/spdz/1d7ad1b8-c60e-4f2f-b8d5-e196dc6928e4n%40googlegroups.com?utm_medium=email&utm_source=footer>.
OpenPGP_signature

Nigel Smart

unread,
Feb 18, 2022, 8:53:09 AM2/18/22
to sp...@googlegroups.com
Not tested this on a recent download of the lwe-estimator

But basically you are going to need a huge value of N,
2^17 say. So change the range of n in the code on
page 117 of the manual to run from (17,18) just
to get the data for this N size.

Nigel

On 18/02/2022 11:58, Davide Ferrari wrote:
>> <https://groups.google.com/d/msgid/spdz/0d5760bc-bcc3-48c8-80be-15ae15790cd2%40googlegroups.com?utm_medium=email&utm_source=footer>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "SPDZ/SCALE-MAMBA Discussion Group" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to spdz+uns...@googlegroups.com
> <mailto:spdz+uns...@googlegroups.com>.
> To view this discussion on the web, visit
> https://groups.google.com/d/msgid/spdz/1d7ad1b8-c60e-4f2f-b8d5-e196dc6928e4n%40googlegroups.com
> <https://groups.google.com/d/msgid/spdz/1d7ad1b8-c60e-4f2f-b8d5-e196dc6928e4n%40googlegroups.com?utm_medium=email&utm_source=footer>.
OpenPGP_signature

titouan...@gmail.com

unread,
Feb 18, 2022, 10:26:13 AM2/18/22
to SPDZ/SCALE-MAMBA Discussion Group
Hi,

Maybe section 7 ("Selection of FHE parameters" part) of https://eprint.iacr.org/2019/1300.pdf can be of some help to understand the output of the code we have in the manual.
(Notations there should be consistent with the ones in the manual)
Best,
Titouan
Reply all
Reply to author
Forward
0 new messages