Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pj8912/python_p2p
Peer-to-Peer network in python
https://github.com/pj8912/python_p2p
decentralized-applications hybrid-approach p2p p2p-networks p2p-node peer-to-peer python python-socket
Last synced: 13 days ago
JSON representation
Peer-to-Peer network in python
- Host: GitHub
- URL: https://github.com/pj8912/python_p2p
- Owner: pj8912
- License: apache-2.0
- Created: 2022-08-18T12:34:04.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-05-08T03:12:01.000Z (over 1 year ago)
- Last Synced: 2024-11-12T12:13:11.801Z (2 months ago)
- Topics: decentralized-applications, hybrid-approach, p2p, p2p-networks, p2p-node, peer-to-peer, python, python-socket
- Language: Python
- Homepage: https://github.com/pj8912/python_p2p
- Size: 43.9 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# python_p2p
Peer-to-Peer network in pythonThis is a peer-to-peer network built using Python programming language. The network enables direct communication between nodes (peers) in the network without the need for a central server.
## Requirements
- Python 3.x
- Required packages:
- `socket`
- `threading`## Quick Start
- Write `python3 peer.py ` on terminal to start.- The peer.py file combines both the `server` and the `client` files together to create a `Peer` in the network.
- This program starts creating a peer as the Server and then when the server is disconnected this program takes care making another peer as the server.
- This is done by constantly looping over the peers in list and try make all peers as clients and then try making itself as the server.## Features
- Direct communication between nodes in the network.
- Dynamic discovery of other nodes in the network.
- Ability to send messages to other nodes in the network.## Limitations
- The network does not support secure communication and is vulnerable to hacking and eavesdropping.## Hybrid approach
In a hybrid approach, both client and server components play a role in managing the peer list and maintaining the P2P network.
Check out [Hybrid approach](https://github.com/pj8912/python_p2p/tree/main/hybrid-approach)## Contribute
- If you are interested in contributing to the development of the P2P network, you can create a pull request with your changes. All contributions are welcome and appreciated.