Skip to content

tbayan/PnR_DAO

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A Privacy-Preserving DAO Model Using NFT Authentication for the Punishment not Reward Blockchain Architecture

Prototype smart contract implementing the Punishment not Reward DAO model from blockchain governance research.

Overview

This prototype demonstrates a DAO governance mechanism using reputation-based deterrence instead of token rewards. The implementation explores:

  • Dual NFT Framework - Authentication and private interaction separation
  • Punishment Mechanisms - Graduated penalties from warnings to removal
  • Empirical Validation - Real blockchain data collection and analysis
  • Cost Analysis - Layer 1 vs Layer 2 comparison using live network data

Files Structure

pnr_dao.sol       - Main smart contract with governance logic
analysis.py       - Empirical data collection from Etherscan/Polygonscan APIs

ETH Historical Price Based Chart:

https://etherscan.io/chart/etherprice

On-Chain Data Collection

Access our complete dataset of 150 governance transactions:

  • Raw transaction data
  • MakerDAO: 25 transactions ($0.89 avg)
  • Compound: 25 transactions ($0.33 avg)
  • Uniswap: 25 transactions ($0.15 avg)
  • Arbitrum DAO: 25 transactions ($0.0061 avg)
  • Polygon: 50 transactions ($0.0037 avg)

Quick Deploy

Using Remix IDE

  1. Open remix.ethereum.org
  2. Paste pnr_dao.sol contract code
  3. Install dependency: @openzeppelin/contracts
  4. Compile with Solidity 0.8.19+
  5. Deploy to Polygon Mumbai testnet

Basic Usage

// Identity verification (simulation)
pnrDAO.simulateDKYC(userAddress);

// Join with commitments
pnrDAO.joinDAO(identityCommitment, privacyCommitment);

// Create proposal
pnrDAO.createProposal(targetMember, "behavior violation", 
                     ProposalType.REPUTATION_PENALTY, 
                     PunishmentSeverity.WARNING, evidenceRoot);

// Vote with evidence
pnrDAO.vote(proposalId, true, evidenceProof);

// Private deal
pnrDAO.createPrivateDeal(seller, "service description", deadline, 
                        SERVICE_DEALS, privacyCommitment);

Research Context

This prototype implementation supports the practical evaluation described in:

Chapter 5: "A Privacy-Preserving DAO Model Using NFT Authentication for the PnR Blockchain Architecture"

The implementation demonstrates:

  • Identity commitment schemes: C_i = com(ID_i; r_i)
  • Empirical cost analysis using real network data
  • Comparative performance with existing DAOs

Empirical Analysis

Generate validation data:

python analysis.py

The analysis tool collects real-time data from:

  • Etherscan API for Ethereum transaction costs
  • Polygonscan API for Layer 2 network data
  • CoinGecko API for current pricing

Outputs:

  • figure1_pnr_cost_analysis.png - Cost comparison with Compound, Uniswap, Aragon
  • figure2_efficiency_analysis.png - Batch operation efficiency models

Data Sources

All analysis uses verifiable blockchain data:

  • Transaction hashes from major DAOs
  • Real gas measurements from deployed contracts
  • Live network conditions with 95% confidence intervals
  • Mathematical models based on ERC-1155 specifications

Limitations

This is a prototype implementation with known constraints:

  • DKYC simulation (not production-ready verification)
  • Testnet deployment recommended
  • Requires further security auditing for production use

Citation

@article{bayan2024privacy,
  title={A Privacy-Preserving DAO Model Using NFT Authentication for the Punishment not Reward Blockchain Architecture},
  author={Bayan, Talgar and Banach, Richard},
  journal={arXiv preprint arXiv:2405.13156},
  year={2024},
  eprint={2405.13156},
  archivePrefix={arXiv},
  primaryClass={cs.CR},
  doi={10.48550/arXiv.2405.13156}
}

About

PnR DAO - Solidity contracts.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors