Coin Voting / Shielded Airdrop / Proof of Balance

Here’s a proposal for a Proof of Balance protocol. It can be used to organize shielded coin voting and airdrops too.

Explainer Video: https://www.youtube.com/watch?v=8o1pr99qVpU

Thanks
–h

Edit: Added YT link

30 Likes

This looks very cool. A clever solution to show that you hold coins without having to send them to a T address.

I would be interested in some sort of feedback from ECC, ZF or an independent auditor about the security of this method = that it can’t be gamed somehow by shifting funds around.

Or what happens if only a small % of ZEC in circulation are measured at the time of vote, is that “enough” for a valid data point?

Overall, love the concept, this could be a solution for things like the Namada airdrop.

9 Likes

very nice. did you develop this for the ycash fork?

Amazing work.

@hanh single handedly saving the namada airdrop for ZEC holders

2 Likes

Sure. The first milestone is to write up a ZIP.
Essentially, a double vote would be detected as a double spend.

No, ycash is not involved in this proposal at the moment.

8 Likes

@hanh Thanks for the YT link :heart:. Thinking out loud below.

  1. Do we need to worry about a DOS against the cost of receipts? Could an actor with 10,000s of micro wallets conceivably attack/drive-up-costs for every election? Do we required a min voting balance to solve this?
  2. This solution doesn’t include a proof of age? Could/should it?
1 Like
  1. The protocol considers that. Though there is no cost associated with receipts.
    The voter:
  • sends a p2p message to the organizer
  • makes a payment to cover the fees. The memo must contain a hash commitment to the message.

The organizer will only emit a receipt if both conditions are met. This ensures that the organizer cannot omit ballots and the voter cannot claim the organizer did.

  1. This solution doesn’t include a proof of age? Could/should it?

No proof of age. IMO, it shouldn’t, because for me, new money is as good as old money.

3 Likes

Can “elections” be bought with flash (or short timeframe) loans?

2 Likes

Might be a good idea for vote organizers to allow vote for those who held $ZEC prior to the voting announcement. Say, announcing a vote on Jan 10th. This vote will accept $ZEC held on Jan 2nd and it will be closed on Jan 20th.

So in this example, a valid vote needs to fulfill 2 conditions:

  1. Held on Jan 2nd
  2. Vote submitted before end of Jan 20th

I personally would like to see the ability to weight the length of time $ZEC held in shielded pools. For example, 1 ZEC held in shielded pools for 1 million blocks before voting starts has the same voting power as 1000 ZEC held for 1000 blocks. I understand that it’s out of scope in this proposal.

1 Like

This could be made difficult by setting a “flexible” start date. The organizer could say that the freeze height will be some time between A & B. An honest voter would have his coins ready by A. A dishonest voter would have to borrow coins for the duration of [A, B], or he could miss the actual freeze height.

5 Likes

This would likely require new ZKP circuits. For Orchard, it could be done but for Sapling it would mean another trusted setup.

3 Likes
  • Delegation of not supported.
  • Once the vote is over and the results are published. Anyone can audit the election.
  • This doesn’t change the core protocol. It uses p2p messages and standard transactions with memos. Neither zebra nor zcashd need modification.
3 Likes

Yes, something like that should work.

Edit: I thought you meant delegating and then not having to vote at all.

2 Likes

But this only works for a single election right? It doesn’t work across elections assuming freeze height changes?

1 Like

You can only prove that you held X ZEC today. Not that you’ll still have those funds in 6 months time for some future election.

Edit: It might be better if long term delegations are a voting client thing (e.g. repeat delegation button for each vote). Need to be super careful with delegated transactions/memo as they might be hard to undo.

1 Like

You would be giving spending authority as well. You could reduce the risk somewhat with multisig.

3 Likes

without proof of age, this would not be interesting for projects like namada that are doing an airdrop for ZEC holders or other projects that are planning to do something similar.

all the projects that i have seen doing airdrops, take a snapshot at a certain block or date.

2 Likes

My understanding is “freeze height” is the block height which is used by voting clients to prove a balance. I imagine Namada would pick some arbitrary block in the past (not too far) as the freeze height and if you were lucky enough to hold ZEC at that time you can claim the airdrop.

1 Like

There is a snapshot.
But the age of a coin does not have an impact. For ex: 1 ZEC = 1 NAM as long as it is in possession before the snapshot (freeze height).

5 Likes