Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save learner-long-life/cbe3c12eafc1d57e2201980ee6a2946c to your computer and use it in GitHub Desktop.
Save learner-long-life/cbe3c12eafc1d57e2201980ee6a2946c to your computer and use it in GitHub Desktop.
Proposed Decentralized Cloud Server
Let's say you have a serverless cloud function system which reproducible, stateless, only operates on its immutable inputs and produces immutable output all the functional things.
```
F(x) = y
```
You also have an on-chain verifier function (I know, unrealistic, but we'll try and fix this later) that you can run, much faster than `F`, that you publish on a ledger tied to
```
G(x,y) = true for all x, y=F(x)
false otherwise with overwhelming probability
```
We also know how to do encryption homomorphism `F(E(x)) = E(y)` and `G(E(x),E(y)) = true` and can compile any function / gate into an EH version
Let's say `F_123` a versioned Rust function for a particular compiler version, package dependencies, etc. and also stored immutably along with `x` and `y` in say, IPFS. The actual language doesn't matter. You submit `F_123`,`x`,`G_123` to a relay network with a reward fee `r` and a timeout `t`. These are published in a contract that only releases the reward for the first proposed answer `y'` which verifies on-chain with `G` within time `t`. If `x` is encrypted then `y'` is also encrypted.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment