Skip to content

Since many of us facing security issues in elections so I have created some smart contractions which can be helpful for creating a defi app to increase the security.

License

Notifications You must be signed in to change notification settings

preeti13456/CryptoCast

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

58 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

CryptoCast - Blockchain Based Secure Voting System

CryptoCast is Ethereum Blockchain based decentralized application which ensures secure and transparent voting scheme for organizing public and private elections.

πŸ’‘ Features

▢️ Secure Voter Registration
▢️ Ballot Signing Support For Election Authority
▢️ Tamper-proof Ballots
▢️ Double Voting Prevention
▢️ Blind Signature Support using ECDSA

🎯 Purpose of Blockchain Based E-Voting

Physical election systems that are prevalent have several drawbacks -

  • Ballots can be internally tampered before or after vote casting
  • Election system does not ensure transparency and security
  • Voters need to trust election authority
  • Double voting issue can occur

CryptoCast, being a blockchain based E-Voting solution, addresses these issues by adpoting following schemes -

  • Each ballot is cryptographically signed using election authority's private key
  • Ballots are tamper-proof as those are digitally signed and verified by smart contract on the blockchain.
  • Double voting is addressed by keeping registered voters' data on Blockchain
  • Election authority does not have access to voter's ballot
  • Elligible voters can only register for the election with their National Identification Number.

πŸ”¨ Technology Stack

  1. Blockchain Tools
    1. Truffle
    2. Web3 JS
    3. Ganache
  2. Smart Contract Programming
    1. Solidity
  3. Front End
    1. HTML
    2. CSS
    3. Bootstrap
    4. JavaScript
  4. Dev Servers
    1. Node
    2. Lite-Server

πŸ’Ό Pre-requisites

  • Truffle = v5.1.10
  • Node.js >= v12.18.2
  • Solidity (Solc-js) = v0.4.23
  • Node.js >= v12.18.2
  • Web3 >= v1.2.11

πŸ“£ How to Build

Step-1 : Prepare Development Environment

  1. Install Node JS

    • Head into the website & download.
    • Tip: Use NVM version manager to flexibly install NodeJS)
    • $ npm install -g truffle
  2. Install Ganache GUI

    • Head into the website & download.
  3. Clone the repository

    • Download the repo to your local machine using $ git clone.
  4. Install Project Dependencies using NPM

    • Change directory into the project root by $ cd CryptoCast/ and run $ npm install
    • Install the extension based on your preferred web browser (Chrome/Edge/Firefox)
    • Based on your favorite text editor (Atom/Sublime Text/VSCode), install Solidity Syntax Highlighter Package to properly highlight the solidity sources.

Step-2 : Run the Project

  1. Compile & Test

    • Run '$ truffle compile' and make sure the source is successfully compiled.

    • Tip: Remove 'build/' folder and then compile for generating fresh new compilation artifacts of the sources.

  2. Fire Up Ganache

    • Open Ganace and start local blockchain workspace
    • Make sure the Ganache port ID is same as the port specified under 'development' network in truffle-config.js.
    • Copy the deployed 'contract address' and paste it on contractAddress variable on 'src/js/app.js' script
  3. Smart Contract Migration

    • Run $ truffle migrate --reset and wait for successful deployment of the contracts on the local blockchain.
  4. Start Dev Server

    • Start Lite-Server using $ npm run dev on project root.

Step-3 : Interact with the Dapp

  1. Open your preferred browser in http://localhost:3000, with MetaMask activated and logged in
  2. Connect MetaMax with running Ganache using 'Local RPC Server'option in settings.
  3. Take any fake account from ganache.
  4. Register as a voter with NID, wait for transaction to be mined, and then refresh the page
  5. Now you can vote and interact with the contract.

Enabling version updates on your fork

If you wish, you can enable dependency version updates on fork. For that, follow this guide to enable dependabot on your fork.

🀝 Contribution

Contributions are welcome!

Feel free to submit a pull request, with anything from small fixes, to full new sections. See the issues for topics that need to be covered or updated. If you have an idea you'd like to discuss, please open up an issue.

πŸ† Contributors

Name πŸŽ–οΈ Social Media πŸ“± GitHub :octocat:

Anjum Rashid
🐦 Twitter
πŸŽ“ LinkedIn
πŸ’» Commits
@bijoy26

Manasir Jisam
🐦 Twitter
πŸŽ“ LinkedIn
@manasir66

⭐ ⭐ This project is a part of SCI-2020 ⭐ ⭐

OPEN SOURCE CONTEST - STUDENT CODE-IN

About SCI

Student Code-In is a global program that helps students grow with Open Source. It is a 2 months long Open-Source initiative which provides you the best platform to improve your skills and abilities by contributing to vast variety of Open Source Projects. In this, all the registered participants would get an exquisite opportunity to interact with the mentors and the Organizing Team.

About

Since many of us facing security issues in elections so I have created some smart contractions which can be helpful for creating a defi app to increase the security.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published