Git Product home page Git Product logo

mbcse / decentralized_social_media Goto Github PK

View Code? Open in Web Editor NEW
21.0 3.0 13.0 1.37 MB

A decentralized social network deployed on ethereum network where you can share your content freely as there is no central authority to control and also can earn cryptos by keeping the platform free from abusive content

Home Page: https://dwittermedia.herokuapp.com/

License: MIT License

Solidity 4.13% JavaScript 17.47% HTML 7.62% CSS 70.78%
ethereum html css jquery javascript ipfs truffle truffle-framework bootstrap web3js

decentralized_social_media's Introduction

Decentralized Social Media(Dwitter)

Consensys Bootcamp Project

Introduction

In the present world social media has become a very important part of our lives. We share so much content everyday ranging from what we are doing in our personal lives to professional information. For some it's a source of income due to its marketing capabilties and for some it's platform to share there content, for some its a platform to raise there voice and for some it's a platform to connect to world. Infact some social media platforms have become a political playground also. Many decisions, ideas, events our shared on these platforms, consider the case of twitter many heads of countries share updates on this platform. But with all these things we know social media has a problem due to its centralized nature. we have seen of password leak of twitter users and forcefull banning of accounts due to political influence. Also the advertisers may not know wether the ads they are promoting are not influenced by these companies. All these things force us to adopt a decentralization and this project have tried to implemented that.

Platform Overview

The platform is a decentralized social media something similar to twitter but totally in a decentralized way having no server. The platform is having a smart contract containing all the important logic and is deployed on Ethereum Blockchain. Some of the features of the platform are:

  • Secure and user friendly login using metamask wallet
  • Only your Public address is the key to access the platform
  • Cool user profile same as Twitter
  • Easy to use interface
  • Commenting feature on dweets
  • Reporting feature on dweets
    • Once a dweet get a specified no of reports it will be sent to maintainers for action
    • You will have to stake some ethers for reporting
    • If the dweet is banned by maintainers you will get refund and a reward
    • If the dweet is not Banned by maintainers you will get no refund and the staked amount will go to the reported dweet author
  • Like feature on dweets
  • You can upload advertisements(image and a link) and reach out to platform users at nominal cost
    • Advertisements once submitted will be sent to maintainers for acceptance -If it is rejected then 80% amount will be refunded
  • Maintainers can be added to the platform
  • A dedicated maintainer page where you can give acceptance and ban dweets(only If it gets required reports)

Tech stack Used

  • Ethereum
  • IPFS
  • Web3js
  • HTML
  • CSS
  • Bootstrap
  • Javascript
  • Jquery
  • Truffle

Future Work

  • Use Meta transactions(gasless transactions) to make the platform gas free for users
  • Add more Features like follow, profile view etc
  • Add video Advertisement options
  • Add reporting on comments

Directory Structure

๐Ÿ“ฆ DECENTRALIZED_SOCIAL_MEDIA
 โ”ฃ ๐Ÿ“‚ .github
 โ”ฃ ๐Ÿ“‚ node_modules
 โ”ฃ ๐Ÿ“‚ build (Recent build of the Smart Contracts)
 โ”ฃ ๐Ÿ“‚ contract (Solidity Smart Contracts)
 โ”ฃ ๐Ÿ“‚ migrations (Truffle deployment migrations)
 โ”ฃ ๐Ÿ“‚ test (Smart Contract Tests)
 โ”ฃ ๐Ÿ“‚ src (Dapp Frontend)
 โ”ฃ ๐Ÿ“œ avoiding_common_attacks.md
 โ”ฃ ๐Ÿ“œ design_pattern_decisions.md
 โ”ฃ ๐Ÿ“œ package.json (project dependencies)
 โ”ฃ ๐Ÿ“œ README.md (Project Documentation)
 โ”ฃ ๐Ÿ“œ server.js (Lite server to host frontend)
 โ”— ๐Ÿ“œ truffle-config.js (Truffle Project Config)

Running the project

Smart Contracts

  1. Run npm i to install dependencies.
  2. Run ganache-cli to start a local chain.
  3. In the projects root directory, run truffle console to interact with the porject.
  4. To compile contracts run truffle compile
  5. To deploy run truffle migrate
  6. To test run truffle test

Frontend/To Start Local Server

  1. In the projects root directory, run npm start

Project Demo

Website ๐Ÿ‘‰ https://dwittermedia.herokuapp.com/

YouTube ๐Ÿ‘‰ https://youtu.be/l75vF8HAJ8Y

Avoiding Common Attacks

Documented here ๐Ÿ‘‰ avoiding_common_attacks.md

Deployed Addresses

Documented here ๐Ÿ‘‰ deployed_addresses.md

Design Pattern Decisions

Documented here ๐Ÿ‘‰ design_pattern_decisions.md

decentralized_social_media's People

Contributors

mbcse avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

decentralized_social_media's Issues

How to config this project?

I have tried to use this project but after install npm module and run server, I have this error when I trying to register.

image

I have project id and secret, so have tried to add them to request header for auth

image

But this is not correct one

How can I add project id and secret?

other tutorial says like this

image

But I can't use Buffer in this project because app.js is not node.js

Help me please

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.