Giter Club home page Giter Club logo

world-tree's Introduction

world-tree

WorldId is one of the core pillars of the Worldcoin Protocol, providing a privacy preserving identity primitive which enables a robust mechanism for proof of personhood. The protocol works by maintaining an onchain representation of a Semaphore set, with each identity in the set representing a verified human. With WorldId, users can create Zero Knowledge proofs proving that they are a unique member of the set. In order to create a ZKP, users need to generate a merkle proof for their identity in the set.

The world-tree is a service that syncs the state of the onchain merkle tree and delivers inclusion proofs for any given identity.

Installation

To install the world-tree, make sure you have Rust installed and run the following commands.

git clone https://github.com/worldcoin/world-tree.git &&
cargo install --path .

Usage

To run the world-tree, you can run the following command.

world-tree --config <path_to_config.toml>

To see an example configuration file, see bin/world_tree.toml. You can also specify the necessary configuration variables via environment variables.

Docker usage & local testing

To run this service for local testing, you can execute the following command.

docker compose up -d --build

This command will build the docker image locally and start the service itself along with an anvil instance to serve as a test blockchain.

Anvil will fork Ethereum mainnet and use the production WorldIdIdentityManager contract, but with only a few identities inserted.

To test that inclusion proofs work you can execute the following curl command:

curl -X POST http://localhost:8080/inclusionProof -H "Content-Type: application/json" -d '{ "identityCommitment": "0x3017972D13A39795AD0D1C3A670D3D36A399B4435E61A510C2D57713D4F5C3DE" }'

world-tree's People

Contributors

0xkitsune avatar dcbuild3r avatar dzejkop avatar dependabot[bot] avatar ewoolsey avatar samoht9277 avatar atlantis-for-worldcoin[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.