nucypher / protocol

Upstream research, development and discussion relating to the NuCypher protocol and economic design
GNU General Public License v3.0
14 stars 5 forks source link

A skeleton-logic proposal for another economic model of grant (probabilistic micropayments) #15

Open arjunhassard opened 4 years ago

arjunhassard commented 4 years ago

Note: this conversation originally took place on NuCypher's forum.

@jMyles [Sep 19] When Ursula joins, she commits a sequence of hidden lottery numbers.

Alice creates KFrags, a TreasureMap, and a lottery punch. Gives the map and punch to Bob.

Alice proposes Arrangement, providing unsigned (and thus not yet valid) lottery ticket

Ursula checks contract to see how much funding Alice has for that ticket

Ursula says sure

Alice gives Ursula KFrag and signs lottery ticket

Bob seeks retrieval:

Every block, every punch hole has a 1/1000 chance of winning for Ursula’s hidden numbers. If it’s a winner, Ursula reveals and receives the money from the contract.


@arjunhassard [Sep 19] This is a really interesting idea, and also stimulates some broader thoughts about our payment channel(s) and fee structure. I’ve argued previously that compensating Ursulas (= workers, stakers, nodes, proxies) based on only one of a. policy duration or b. re-encryption requests, leads to various problems – see https://github.com/nucypher/mint-paper/issues/7. In short, there is a risk of abuse if Alice and Bob are separate end-users with distinct, discretionary economic motives, and there isn’t a prevailing application layer channeling funds between users. Moreover:

  1. If Ursula is only paid when re-encrypting (or some % of them), but Bob issues very few or no requests over the course of the policy duration, then they will spend resources (the vast majority of overheads, in fact) maintaining an available policy/state, but receive little or no compensation.
  2. If Ursula is only paid for holding a policy, then this doesn’t help address the uptime problem. The infrequency with which an Alice would pay for a 3 or 6 or 12 month policy also makes probabilistic micropayments unnecessary and unsuitable.

Therefore a hybrid approach, where Alice pays once for the persistence of the policy, and Bob probabilistically pays for each re-encryption, might be a happy medium.

In this flow, Ursula accepts an Arrangement based on the (standardised) cost of being online for the policy’s duration, which is entirely covered by Alice’s deposit up front.

Later, Bob pings Ursula. Ursula checks he has sufficient funds (see verification point below), then commits to some random numbers. The rest of the process mirrors jMyles’s proposal above. This disentangles Bob from Alice, where he is no longer restricted by the ‘punch’ bestowed to him, and can request re-encryptions as many times as he is willing to pay for (and collateralise).

Some general points about probabilistic micropayments applied to the NuCypher network, regardless of the viability of this counter-proposal:


@michwill [Oct 19] Let’s define a protocol. How about this.

We have Bob, and we have someone who pays (could be Alice, or Bob, or some third party - let’s call him Patrick). The protocol looks like the following:

Patrick escrows in some money;

In this protocol, no one knows, what hash Ursula will get (except for Ursula) before she actually calculates and broadcasts it. Neither can anyone guess, what Bob will produce (because no one can forge his signature). True randomness isn’t required.

Patrick makes tickets for Bob and for specific Ursulas (so that Bob can spend tickets only for the n Ursulas).

Does it work, or am I missing something?


@cygnusv [Oct 19] Two things: