← Back to home

Commit-Reveal Schema Exploration

This is an educational projects to learn more about the sharing secrets on a blockchain.

Screenshots

Commit-Reveal Schema Exploration screenshot 1
Commit-Reveal Schema Exploration screenshot 2
Commit-Reveal Schema Exploration screenshot 3

Problem Statement

How to simultaneously broadcast secrets on a public blockchain?The difficulty on the blockchain is that participants can't share their values at the same time, the first participant must broadcat their value, meaning other participants can act accordingly.SOLUTION__ Commitment Scheme Cryptographic algorithm that allows someone to commit to a value while keep it hidden from others with the ability to reveal it later. Phase 1: commit Phase 2: revealThe following contract implements commit-and-reveal for a game of rock-paper-scissors.

Solution

This commit-and-reveal exploratory project uses solidity to implement rock-paper-scissors game logic. A simple React interface was built to manage connecting and deploying to the replit testnet, as well as providing an interface to invoke the rock-paper-scissors slidity contract.

Hackathon

ETHGlobal Tokyo

2024