All Projects → yfgeek → Blockvotes

yfgeek / Blockvotes

Licence: gpl-3.0
An e-voting system based on blockchain using ring signature

Projects that are alternatives of or similar to Blockvotes

Solana
Web-Scale Blockchain for fast, secure, scalable, decentralized apps and marketplaces.
Stars: ✭ 1,383 (+659.89%)
Mutual labels:  blockchain, bitcoin, ledger
Basic Blockchain Programming
Sample code from my blog series "Basic blockchain programming".
Stars: ✭ 282 (+54.95%)
Mutual labels:  blockchain, bitcoin, transaction
Learning Bitcoin From The Command Line
A complete course for learning Bitcoin programming and usage from the command
Stars: ✭ 2,010 (+1004.4%)
Mutual labels:  blockchain, bitcoin, transaction
Bitcoin in a nutshell
Книга о том, как действительно работает Bitcoin
Stars: ✭ 98 (-46.15%)
Mutual labels:  blockchain, bitcoin, transaction
Chainabstractionlayer
Blockchain abstraction layer
Stars: ✭ 131 (-28.02%)
Mutual labels:  blockchain, bitcoin, ledger
Chainlink Ruby
Easily connect your applications to blockchains
Stars: ✭ 152 (-16.48%)
Mutual labels:  blockchain, bitcoin
Interledger Rs
An easy-to-use, high-performance Interledger implementation written in Rust
Stars: ✭ 155 (-14.84%)
Mutual labels:  blockchain, bitcoin
Axentro
To be the go to platform for building dApps quickly and cheaply for business and gaming
Stars: ✭ 181 (-0.55%)
Mutual labels:  blockchain, bitcoin
Blockchain Tutorial
🌾 A step-by-step blockchain tutorial in simplified Chinese
Stars: ✭ 2,081 (+1043.41%)
Mutual labels:  blockchain, bitcoin
Blockchain
blockchain (crypto) tools, libraries & scripts in ruby
Stars: ✭ 143 (-21.43%)
Mutual labels:  blockchain, ledger
Blockchain Java
A simplified blockchain implementation in Java
Stars: ✭ 160 (-12.09%)
Mutual labels:  blockchain, bitcoin
Bitcoin Transaction Explorer
Simple and pure block explorer you can run on top of a full node
Stars: ✭ 165 (-9.34%)
Mutual labels:  blockchain, bitcoin
Awesome Token Sale
Curated list of token sale resources / ICO resources
Stars: ✭ 149 (-18.13%)
Mutual labels:  blockchain, bitcoin
Ebtc
eBitcoin (eBTC) is an ERC20 token. Its primary utility is to provide an easy & fast payment solution. Its edge over other tokens is that it is capable of sending up to 255 payments in a single transaction.
Stars: ✭ 149 (-18.13%)
Mutual labels:  blockchain, bitcoin
Proofofexistence
Core and web app for Proof of Existence - the original blockchain notary service
Stars: ✭ 155 (-14.84%)
Mutual labels:  blockchain, bitcoin
Spruned
A Bitcoin-without-Blockchain client w/ RPC that can provide any block or transaction
Stars: ✭ 149 (-18.13%)
Mutual labels:  blockchain, bitcoin
Curso blockchain
Indtroductory course to cryptocurrencies and applications of Blockchain technologies.
Stars: ✭ 161 (-11.54%)
Mutual labels:  blockchain, bitcoin
Cointop
A fast and lightweight interactive terminal based UI application for tracking cryptocurrencies 🚀
Stars: ✭ 2,912 (+1500%)
Mutual labels:  blockchain, bitcoin
Smart Contract Watch
A tool to monitor a number of smart contracts and transactions
Stars: ✭ 168 (-7.69%)
Mutual labels:  blockchain, transaction
Blockchain go videos
Golang公链开发系统视频教程
Stars: ✭ 180 (-1.1%)
Mutual labels:  blockchain, bitcoin

BlockVotes

An e-voting system based on blockchain using ring signature

Demo Video: https://www.youtube.com/watch?v=4c6pQg3q4Vc

Slides: blockvotes.pdf

Topic

E-voting systems will be beneficial to all people who are involved in elections. For example, administrators can improve operation of tasks for elections, and voters can vote in an election anytime and anywhere. In addition, ideal e-voting systems have transparency, completeness (only voters have the right to vote and their votes are correctly counted), and verifiability (voters can check that their vote is correctly counted), and therefore it is better than existing voting system.

Digital voting is the use of electronic devices, such as voting machines or an internet browser, to cast votes. These are sometimes referred to as e-voting whenvoting using a machine in a polling station, and e-voting when using a web browser.

Security of digital voting is always the biggest concern when considering to implement a digitalvoting system. With such monumental decisions at stake, there can be no doubt about the system’s ability to secure data and defend against potential attacks. One way the security issues can be potentially solved is through the technology of blockchains.

Blockchain technology originates from the underlying architectural design of the crypto currency bitcoin. It is a form of distributed database where records take the form of transactions, a block is a collection of these transactions. With the use of blockchains a secure and robust system for digital voting can be devised.

To solve the problem, I propose a way to use the ring signature and the blockchain to ensure the features of the e-voting. The blockchain technology is characterized by decentralization, irreversibility, distribution of joint accounting, asymmetric encryption and data-security.

Blockchain

The blockchain can be described as an immutable, cumulative ledger, with consensus protocol working to maintain this ledger of all valid transactions on every node in the network.

OP_RETURN

OP_RETURN is a script opcode used to mark a transaction output as invalid. Since any outputs with OP_RETURN are provably unspendable, OP_RETURN outputs can be used to burn bitcoins.

Ring Signature

  1. A group of entities each have public/private key pairs, (P1, S1), (P2, S2), ..., (Pn, Sn).
  2. a ring signature: σ = (m, Si, P1,P2,……,Pn)
  3. Anyone can check the validity of a ring signature given σ, m, and the public keys involved, P1, ..., Pn

Tools & Framework

The Protocol

Please see the thesis.

Wu, Yifan. "An E-voting System based on Blockchain and Ring Signature." Master. University of Birmingham (2017).

Instruction

To run the whole system, there are a lot works to do.

Recommended Running Environment

  1. Operation System: Mac OS X or Linux or Windows
  2. Apache ‎2.4.27 or Nginx 1.12.1
  3. MySQL 5.7.19 (at least 5.4)
  4. PHP ‎7.1.8 (at least 7.0)
  5. php7.0-gmp
  6. composer

php7.0-gmp

php7.0-gmp is a package used for the Elliptic Curve Digital Signature Algorithm (ECDSA). If you are using the Linux, please do the following things.

To install GMP on PHP7 on Ubuntu:

Run: sudo apt-get install php7.0-gmp

And add the following to php.ini:

extension=php_gmp.so

To install GMP on PHP7 on Mac OS X:

Run:

brew tap homebrew/dupes
brew tap homebrew/versions
brew tap homebrew/homebrew-php
brew install php71
brew install php71-gmp

And add the following to php.ini:

extension=php_gmp.so

To nstall GMP on PHP7 on Windows:

uncomment ;extension=php_gmp.dll in php.ini

Apache configuration

Ensure your .htaccess and index.php files are in the same public-accessible directory. The .htaccess file should contain this code:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^ index.php [QSA,L]

Make sure your Apache virtual host is configured with the AllowOverride option so that the .htaccess rewrite rules can be used:

AllowOverride All

Nginx configuration

This is an example Nginx virtual host configuration for the domain example.com. It listens for inbound HTTP connections on port 80. It assumes a PHP-FPM server is running on port 9000. You should update the server_name, error_log,access_log, and root directives with your own values. The root directive is the path to your application’s public document root directory; your Slim app’s index.phpfront-controller file should be in this directory.

server {
    listen 80;
    server_name example.com;
    index index.php;
    error_log /path/to/example.error.log;
    access_log /path/to/example.access.log;
    root /path/to/public;

    location / {
        try_files $uri /index.php$is_args$args;
    }

    location ~ \.php {
        try_files $uri =404;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param SCRIPT_NAME $fastcgi_script_name;
        fastcgi_index index.php;
        fastcgi_pass 127.0.0.1:9000;
    }
}

(reference: https://www.slimframework.com/docs/start/web-servers.html)

For the whole project, directory public is the entrance of the system. If you can not open the page, please check it if is configured correctly in the Nginx or Apache.

BlockVotes configuration

To run the system, some critical but private information are not uploaded by gitingore file. Please add the .env file into the root of this project directory.

DB_DRIVER=mysql
DB_HOST=127.0.0.1
DB_DATABASE=blockvotes
DB_USERNAME=root
DB_PASSWORD=
DB_PORT=3306

STMP_SERVER=smtp.gmail.com
STMP_PORT=465
[email protected]
STMP_PASSWORD=password

Database

The sample SQL file is generated and uploaded as the file blockvotes.sql , please import it to MySQL.

Composer

composer is a dependency management tool for PHP. Please ensure all dependencies has been installed before running the system

php composer.phar install

Screenshot

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].