Skip to main content

Decryption Request Flow

The process of requesting decryption through Smart Contracts starts the same as every other FHE Operation Request πŸ“Œsteps 1-4
Here we'll continue from FheOS server handling such request as follows:

Flow Diagram​

The following diagram illustrates the complete flow of an FHE Decryption request in the CoFHE ecosystem: Diagram Figure 1: End-to-end flow of an FHE Decryption request through the CoFHE system components

πŸ“Œ Step 1-4​

Bullet Bullet Bullet Bullet Bullet Bullet

πŸ“Œ Step 5: FheOS server - Decryption Execution​

The FheOS server handles decryption requests:

  1. Create execution thread on the fheOS server

  2. FheOS server calls the threshold network with:

    • The ciphertext to be decrypted
    • Transaction hash from the host chain
    • Original operation handle

πŸ“Œ Step 6: Threshold network security protocol​

  • Verify the host chain requested the desired decryption
  • Retrieve the actual ciphertext hash from private storage
  • Validate ciphertext hash integrity
  • Perform secure decryption

πŸ“Œ Step 7: FheOS Notifies the Aggregator with the decrypt result​

  • Call appropriate callback function on the Aggregator
  • The Aggregator calls the TaskManager with relevant result

πŸ“Œ Step 8: TaskManager emit event with decryption result​

  • Provide decrypted result by emitting an event DecryptionResult
  • The event consists of ciphertext handle, result, requestor (of that decrypt operation)