Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/33bits-xyz/app

React frontend for 33bits
https://github.com/33bits-xyz/app

farcaster noir react zero-knowledge

Last synced: 2 days ago
JSON representation

React frontend for 33bits

Awesome Lists containing this project

README

        

# 33bits React application

33bits is a Farcaster-based application, which uses the zero knowledge proofs to provide a way for anonymous casting.

## Working with zero-knowledge proofs

Current version uses Noir DSL for writing ZK circuits.

```
bash-3.2$ nargo --version
nargo 0.17.0 (git version hash: 86704bad3af19dd03634cbec0d697ff8159ed683, is dirty: false)
```

To compile circuits locally, first install nargo ([docs](https://noir-lang.org/)), then run the following command:

```
cd circuits/
nargo compile
```

## Why not use storage proofs?

First version of the application was made to work with storage proofs. We've used [noir-trie-proofs](https://github.com/aragonzkresearch/noir-trie-proofs), a library made by Aragon and Noir with the support of Nouns DAO. Unfortunatelly, the implementation resulted in almost 2m gates,
which means that proofs can't be generated in browser due to the RAM limitations.

## Why use MiMC hash instead of EDDSA public key?

The main reason for that is user experience - generating proofs for EDDSA operations such as public key derivation, would take longer
then verifiying MiMC hash function.

Another reason is security. Since signer's public key is not a "real" public key, then it can't be used for signing messages.
So even if private key is stolen, attacker still can't use it to cast messages on user's behalf.

## Start locally

First, install the environment variables

```
cp .env.template .env
```

Next, install NodeJS dependencies and run the application

```
yarn
yarn dev
```