Skip to content

INITIALIZING FHE RUNTIME

Loading TFHE-rs WebAssembly…

Generating your key pair in-browser (~10–15s). Your secret key never leaves this device.

Blind Oracle

FHE · TFHE-rs · programmable bootstrapping

Encrypt two numbers in your browser, let an untrusted Oracle add the ciphertexts it can never read, then decrypt the sum locally.

THE QUESTIONER

Your keys. Your values. Your world.

HOW THIS DEMO WORKS

  1. Your browser generates keys and encrypts your numbers.
  2. Only ciphertext is sent over the wire to the Oracle.
  3. The Oracle adds ciphertexts and returns ciphertext.
  4. Your browser decrypts locally and reveals the sum.

This is Fully Homomorphic Encryption (TFHE-rs, programmable bootstrapping bootstrapping = noise reset). The “plaintext world vs ciphertext world” panel below shows why the encrypted result decrypts to the right answer.

Same numbers, fresh randomness → different ciphertext bytes every time. Watch the fingerprints on the Oracle side change.

DECRYPTION KEY: LOCAL ONLY

ENCRYPTED WIRE

TFHE-rs · Programmable Bootstrapping · True FHE

The secret key stays pinned in your browser. Only ct_a, ct_b and the (non-decrypting) serverKey travel out; ct_result travels back.

RESPONSE TIME: --ms

PROGRAMMABLE BOOTSTRAPPING & THE NOISE BUDGET

Every TFHE ciphertext hides its value under random noise. Each operation grows that noise; too much and decryption fails. Programmable bootstrapping (PBS) resets the noise on every operation so you can keep computing — but each reset is expensive, which is why real FHE programs stay small.

rise = operation adds noise · drop = bootstrapping refreshes it

THE BLIND ORACLE

Evaluation key only. Cannot decrypt. evaluation key = can transform ciphertext, cannot decrypt

ct_a preview

awaiting ciphertext A...

ct_b preview

awaiting ciphertext B...

PLAINTEXT WORLD vs CIPHERTEXT WORLD

Homomorphism means the same computation runs in both worlds and the answers match: Enc(a) ⊞ Enc(b) decrypts to a + b. Both worlds use the same 8-bit type, so both wrap at 256 — the plaintext track adds as a u8 and FheUint8 does the same. Encrypt and compute above, then watch both tracks fill in.

PLAINTEXT (what you know)

a = ? + b = ? = ?

CIPHERTEXT (what the Oracle sees)

Enc(a) Enc(b) = Enc(sum)

decrypt locally with your key → ?

WHY ADDING NOISE STILL ADDS: PEEK INSIDE ONE CIPHERTEXT

A TFHE ciphertext is not a locked box holding your number — it is your number plus a pile of random noise. The Oracle can add two of these piles without ever separating value from noise, which is exactly why it computes but cannot read. Open the peek to see one small value buried under that noise.

LOCAL MULTIPLY BENCH — SPEND THE NOISE BUDGET YOURSELF

The Oracle above does the addition, because Zama's browser build of TFHE-rs ships key generation, encryption and decryption only — it exposes no evaluation operations at all, so the homomorphic step has to run where that API exists. This bench needs no oracle and no network. It runs a second, much smaller homomorphic scheme entirely in this tab, and it will do the multiplication the button above only describes.

Toy scale, stated plainly. This is DGHV (van Dijk–Gentry–Halevi–Vaikuntanathan, 2010) in its symmetric form: Enc(m) = m + 256r + qp, Dec(c) = (c mod p) mod 256, with a 48-bit secret p. The original scheme needs a modulus of millions of bits before its hardness assumption means anything, so this is not secure encryption and must never be used as such. What is exactly right about it is the arithmetic: addition adds the noise, multiplication multiplies it, and when the noise passes p/2 decryption stops being correct. That ceiling is the reason TFHE bootstraps.

Bench idle. Press an operation to encrypt a and start a chain.

No chain yet.
# Expression Noise / budget Ciphertext size Decrypts to Should be Verdict
STATE: BOOTING

WHAT THE ORACLE SAW

PLAINTEXT VALUES PROCESSED BY ORACLE: 0

What is Fully Homomorphic Encryption?

FHE lets a server compute on your encrypted data without ever decrypting it.

TFHE-rs uses programmable bootstrapping (PBS): every operation refreshes the ciphertext noise, so you can keep computing without hitting a fixed circuit-depth wall — unlike leveled schemes that budget for a preset number of operations.

But bootstrapping is not free. Each block-level operation pays a real bootstrapping cost, so in practice FHE programs stay small and slow — the response time shown for even a single add is the price you are watching. FHE removes the depth limit; it does not remove the cost.

The subtle part: the server holds only an evaluation key. It can transform ciphertexts (including bootstrapping) but has no path to the plaintext — that requires the client secret key, which never leaves your browser.

This is the real thing — with real limits, honestly shown.

◆ OPEN DEVTOOLS → NETWORK TAB

Watch the real ciphertext blobs travel over the wire.

POST /compute/add ← your two encrypted values

← ctResult → encrypted sum the server cannot read