and2352000 / Capstone_Real_Estate_Marketplace

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Udacity Blockchain Capstone

The capstone will build upon the knowledge you have gained in the course in order to build a decentralized housing product.

Version

  • Truffle v5.0.6 (core: 5.0.6)
  • Solidity v0.5.2 (solc-js)
  • Node v12 (Use v14 at first, however it can not migrate to rinkeby, so I downgrade to v12)
  • Web3.js v1.5.3

Contract Addresses, Contract Abi's, OpenSea MarketPlace Storefront link's.

Contract Addresses

  1. Deploying Migrations
  2. ERC721MintableComplete
  3. SquareVerifier
  4. SolnSquareVerifier

Contract ABI's

  1. ERC721MintableComplete: eth-contracts/build/contracts/ERC721MintableComplete.json
  2. SquareVerifier: eth-contracts/build/contracts/SquareVerifier.json
  3. SolnSquareVerifier: eth-contracts/build/contracts/SolnSquareVerifier.json

OpenSea MarketPlace Storefront link

Project requirements

ERC721

  • Completes the boilerplate ERC721 Mintable Contract in ERC721Mintable.sol - πŸŽ‰
  • Writes and passes the test cases in TestERC721Mintable.js - πŸŽ‰
  • Writes and passes the test cases in 'TestSquareVerifier.js' - πŸŽ‰
  • Writes and passes the test cases in TestSolnSquareVerifier.js - πŸŽ‰

Notes: SquareVerifier - A Contract to verify tx generate by zokrates

Notes: SolnSquareVerifier - A Contract to make sure a solution can be added and can mint

Zokrates

  • Completes the Zokrates proof in square.code by adding the variable names in square.code - πŸŽ‰
    zokrates compile -i square.code
    zokrates setup
    zokrates compute-witness -a 337 113569
    zokrates generate-proof
    zokrates export-verifier
  • Completes test contract in SolnSquareVerifier.sol - πŸŽ‰
  • Writes and passes the test cases in 'TestSolnSquareVerifier.js' - πŸŽ‰

OpenSea Marketplace

  • List ERC721/ ZoKrates tokens & complete transactions on market place - πŸŽ‰

Deployment

  • Deploys ERC721 contracts with Zokrates integration - πŸŽ‰

How to tutiorial

How to test the code

npm install
cd eth-contracts
truffle test

How to deploy to Rinkeby network

truffle migrate --network rinkeby

How to create a new Zokrates solution

~/zokrates compute-witness -a {num_1} {num_1 * num_1}
~/zokrates generate-proof
  • get proof.json and witness file

Project Resources

About


Languages

Language:Solidity 88.9%Language:JavaScript 11.1%