blockchain_project

所属分类:区块链开发
开发工具:CSS
文件大小:3213KB
下载次数:0
上传日期:2023-01-18 04:09:29
上 传 者sh-1993
说明:  blockchain_project,基于ganache区块链和ipfs的新闻Dapp
(blockchain_project,News Dapp based on the ganache blockchain and ipfs)

文件列表:
Rapport Truth.pdf (1355781, 2023-01-18)
TRUTH (0, 2023-01-18)
TRUTH\LICENSE (1067, 2023-01-18)
TRUTH\avoiding_common_attacks.md (1251, 2023-01-18)
TRUTH\bin (0, 2023-01-18)
TRUTH\bin\contracts (0, 2023-01-18)
TRUTH\bin\contracts\Dwitter.abi (5848, 2023-01-18)
TRUTH\bin\contracts\Dwitter.bin (16382, 2023-01-18)
TRUTH\bin\contracts\Dwitter.json (802157, 2023-01-18)
TRUTH\bin\contracts\dwitter-solc-output.json (1164487, 2023-01-18)
TRUTH\build (0, 2023-01-18)
TRUTH\build\contracts (0, 2023-01-18)
TRUTH\build\contracts\Migrations.json (34779, 2023-01-18)
TRUTH\build\contracts\SafeMath.json (2344817, 2023-01-18)
TRUTH\build\contracts\Truth.json (2563726, 2023-01-18)
TRUTH\contracts (0, 2023-01-18)
TRUTH\contracts\Migrations.sol (419, 2023-01-18)
TRUTH\contracts\truth.sol (28546, 2023-01-18)
TRUTH\deployed_addresses.md (242, 2023-01-18)
TRUTH\design_pattern_decisions.md (751, 2023-01-18)
TRUTH\migrations (0, 2023-01-18)
TRUTH\migrations\1_initial_migration.js (126, 2023-01-18)
TRUTH\migrations\2_truth_migration.js (111, 2023-01-18)
TRUTH\package-lock.json (1125984, 2023-01-18)
TRUTH\package.json (819, 2023-01-18)
TRUTH\server.js (240, 2023-01-18)
TRUTH\src (0, 2023-01-18)
TRUTH\src\admin.html (17485, 2023-01-18)
TRUTH\src\app.js (45657, 2023-01-18)
TRUTH\src\app2.js (42981, 2023-01-18)
TRUTH\src\app3.js (43228, 2023-01-18)
TRUTH\src\guest.html (26703, 2023-01-18)
TRUTH\src\index.html (27244, 2023-01-18)
TRUTH\src\public (0, 2023-01-18)
TRUTH\src\public\assets_admin (0, 2023-01-18)
TRUTH\src\public\assets_admin\css (0, 2023-01-18)
TRUTH\src\public\assets_admin\css\dashboard.css (489842, 2023-01-18)
TRUTH\src\public\assets_admin\css\dashboard.min.css (357246, 2023-01-18)
... ...

# TRUTH dapp ## Introduction Truth dapp is a distrubuted application created to provide to it's user a plateform for news sharing free from fake news leveraging the blockchain's consensus mechanism to ensure that. Team members: * Dorra Gara * Hamza Mahjoub * Wala Bahri * Wassime Mekni Toujeni * Ramzi Latrous ## Architecture The application is composed of three major layers defined as the following: * **front application**: a native js application using web three to ensure a web application that is able to reach the blockchain * **Backend server**: an express application ensuring the connectivity of the front application to the IPFS network * **IPFS node and blockchain's smart contracts** The following diagram illustrates the relationship between the specified tiers and components of the application ![Architecture](https://github.com/hamza-mahjoub/blockchain_project/blob/master/./assets/blockchain%20architecture.drawio.png) ## Requirements In order to have this application up and running in development local environment the following is required: * Linux distribution (Ubuntu for example) * Node * Ganache local blockchain * truffle * IPFS * Browser (FireFox for example) * MetaMask ## Installation Before getting into the set up of the servers you need to insure that you have ganache, truffle, IPFS and metamasek installed in your environment ### Ganache installation To install ganache in your local machine visite ganache official [web site](https://github.com/hamza-mahjoub/blockchain_project/blob/master/https://trufflesuite.com/ganache/) and install ganache from there. Once this step is done we need to change the execution policy of the saved file and run it ```bash > chmod a+x > ./ ``` ### Truffle indtallation having node and npm installed in you local environment use the folowing command to install truffle ```bash > sudo npm install -g truffle ``` ### IPFS Installation The easiest way to do so is by downloading the latest .AppImage from the **IPFS Github Repository** and then execute the following commands ```bash > chmod a+x ./ipfs-desktop-linux.AppImage > ./ipfs-desktop-linux.AppImage ``` ### MetaMask Installation Metamask can be installed as an extension of your favorite browser. visit their extension store to find it ### Application setup In order to have now the application up and running we need to: * **install dependecies of the TRUTH frontal application** using the following commands : ```bash > cd TRUTH > npm install ``` * **install dependecies of the IPFS Backend server application** using the following commands : ```bash > cd ipfs > npm install ``` * **Compile and Deploy smart contracts in the blockchain** using the following command ```bash > truffle migrate --reset ``` * **Start both of the servers** * frontend application: ```bash > cd Truth > npm start ``` * backend IPFS server: ```bash > cd ipfs > npm start ``` ## Disclaimer For the next steps discussed in this project we can think of main two aspects to consider * **Developing tests for the application smart contracts** * **Deploying the application in a poblic blockchain** (Etherum public blockchain)

近期下载者

相关文件


收藏者