chore: eq-neq bool support and bitwise scalar support
chore: overloads for fheEq and fheNe
fix: reverts onchain when rhs is 0 in fheDiv-fheRem
feat: added support for scalar and,or,xor
chore: cleanup codegen
feat: adds euint128 and euint256 types
chore: removes ebool fheRandBounded and adds manual tests
feat: adds new types for fheRand
feat: adds trivialEncrypt for ebytesXXX
feat: adds fheEq fheNe ifThenElse for new types
chore: rename asyncDecrypt() to initGateway()
docs: payment-limit docs
docs: blind auction
docs: improved the comments on example contracts, use of @dev, @params and @notice
docs: readme is updated
docs: imporved readme for examples
docs: improve README
docs: prettier
docs: commit suggestions
docs: shortended readme
This PR is rebasing original fhevm repository to include last async
decrypt api.
The old oracle has been refatored to Gateway plus related changes
A fix in ACL. sol has been done.
The async decrypt test is successfully triggering an event.
The missing part to have the full test is the signatures part in
KMSVerifier.sol.
Check setup-local-fhevm.sh script to see the steps needed to have a
working configuration. Deployment is as follows:
1. Deploy ACL + write deployed @ to lib/.env.acl
2. Deploy TFHEExecutor + write deployed @ to lib/.env.exec
3. Deploy KMSVerifier + write deployed @ to lib/.env.kmsverifier
4. Deploy Gateway + write deployed @ to gateway/.env.gateway
Purpose of this commit is to establish a baseline for a working fhEVM
using the ACL and TFHEExecutor contracts. More tests and a rewrite of
examples will come in a future commit.
The ACL contract manages ciphertext permissions, removing the need for
privileged storage and memory in fhEVM.
The TFHEExecutor contract checks ciphertext permissions in the ACL
contract. Only TFHEExecutor is allowed to call FHE precompiles in the
fhEVM.
Not all tests are passing at that point. Only the Rand and the
EncryptedERC20 ones work.
Tests don't use the KMS for decryption. Instead, we load the secret FHE
key and pass it to fhevmjs for decryption.
Update to fhevmjs 0.5.0-1 and tfhe-rs 0.6.1