Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The running results of " Test Funshade single fully correct" & "Test Funshade single fully correct" are sometimes right and sometimes wrong, but the result of "Test Funshade batched fully correct" is always false #6

Open
ThankUYou opened this issue May 16, 2024 · 5 comments

Comments

@ThankUYou
Copy link

Test AES fully correct: true

  • Avg. time G_ni: 347 (ns)
  • Avg. time G_tiny: 1014 (ns)

Test DCF fully correct: true

  • Avg. time DCF_gen: 14166 (ns)
  • Avg. time DCF_eval: 5168 (ns)

Test IC fully correct: true

  • Avg. time IC_gen: 15540 (ns)
  • Avg. time IC_eval: 9818 (ns)

Test Funshade single fully correct: false

  • Avg. time funshade_setup: 23430 (ns)
  • Avg. time funshade_share: 26 (ns)
  • Avg. time funshade_eval_dist: 29 (ns)
  • Avg. time funshade_eval_sign: 9978 (ns)

Test Funshade single fully correct: false

  • Avg. time funshade_setup: 97538 (ns)
  • Avg. time funshade_share: 200 (ns)
  • Avg. time funshade_eval_dist: 447 (ns)
  • Avg. time funshade_eval_sign: 10145 (ns)

Test Funshade batched fully correct: false

  • Avg. time funshade_setup: 447948578 (ns)
  • Avg. time funshade_share: 2771095 (ns)
  • Avg. time funshade_eval_dist: 4690969 (ns)
  • Avg. time funshade_eval_sign: 51246996 (ns)

Tests failed.

@ShokofehVS
Copy link
Contributor

One question, how did you get the test running for either Funshade (test_funshade or test_fss) or gates (IC, DCF)?
I believe that test_funshade is accompanied with the paper and acts correctly. However, Alberto can specify this actually better.

@ThankUYou
Copy link
Author

Thank you for your reply. I did not use python. I just compiled the C code under the funshade/c directory, and the following error occurred when executing it.
funshade-error

@ibarrond
Copy link
Owner

Hmmm, this requires some debugging to fix. Based on previous errors, I'd guess it might be a +-1 in a corner case (Might be the twos complement for signed integer types in the gates). I'll take a look at it as soon as I can.

In the meanwhile, you can give it a try with int16_t or uint32_t on this line:

#define R_t int32_t // Ring data type for all the constructions

@ThankUYou
Copy link
Author

If I change uint32_t to uint_16, I can pass the test. Neither int16_t nor uint32_t could.
image

@ThankUYou
Copy link
Author

That's a strange question. Once I execute the command ./test_fss many times, there will be the same problem as before. But there will be no problem after recompiling and then executing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants