-
Notifications
You must be signed in to change notification settings - Fork 76
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
Add support for TFHE.decrypt() #89
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dartdart26
requested review from
immortal-tofu,
mortendahl and
tremblaythibaultl
July 21, 2023 21:09
dartdart26
force-pushed
the
petar/decrypt
branch
2 times, most recently
from
July 21, 2023 21:23
4da3ee5
to
bc806cc
Compare
immortal-tofu
approved these changes
Jul 22, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
tremblaythibaultl
approved these changes
Jul 22, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm 👍
dartdart26
force-pushed
the
petar/decrypt
branch
from
July 22, 2023 12:21
ade5d14
to
c3d6de8
Compare
The decrypt() function decrypts the given euint value. There are a few considerations when doing decryption: * if a transaction is reverted due to a failed TFHE.optimisticReq(), then any decryptions would leak information as they would already have been decrypted when the txn is reverted at the end (due to the nature of TFHE.optimistiReq()) * gas estimation might be more imprecise, because control flow can now depend on decrypted values (that gas estimation doesn't know of as it always uses 0)
dartdart26
force-pushed
the
petar/decrypt
branch
from
August 1, 2023 07:57
c3d6de8
to
70f2f84
Compare
dartdart26
force-pushed
the
petar/decrypt
branch
from
August 1, 2023 08:06
70f2f84
to
e97541e
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The decrypt() function decrypts the given euint value. There are a few
considerations when doing decryption:
then any decryptions would leak information as they would already
have been decrypted when the txn is reverted at the end (due to the
nature of TFHE.optimistiReq())
depend on decrypted values (that gas estimation doesn't know of as it
always uses 0)