Combining FHE and PRE
Previously, we discussed how we used PRE to encrypt transactions. Alice’s account began at a value of 1,000,000 when she initiates a transaction with Bob. Then Alice and node as well as bob and the node generates a private key and a signing key. We use PRE in this phase to pass the value of Alice’s and Bob’s account to the node.
Once in the node we were able to decrypt the value of both accounts and then process the transaction amount. The node was then able to write back to both accounts using both alice and bob’s public key indicating that the transaction was a success.
This week we took this a step further. Prior to passing, Alice’s account state using PRE which was stated above at 1,000,000. We used the Paillier scheme a predecessor of FHE. We used this scheme to encrypt the value of Alices account. We then converted this encrypted object into a byte stream. The byte-stream was passed to the PRE encryption which passed the data to the node. After some conversion from bytes back to a HFE object within the node, the node receives 2 Pailler scheme encrypted objects. The significance of this is that the node is able to complete the financial transaction without ever seeing Alice or Bobs’ account state.
Next we will look to research and add multi-key encryption in combination with the Paillier. We believe that we can make the protocol even more resilient by adding multiple encryption keys in order to further secure the account states for our blockchain. We look forward to updating this content with more helpful images.
It is important to note during this process we have had several realizations. While many FHE libraries showed inconsistencies in additive operations past a certain number of digits. The addition and subtraction specific Pailler scheme proved to be resilient. We were able to perform addition operations on 1 e^20 integers
Thanks to the team @ zama.ai for the insight in helping us solve this problem.