Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ambianic/peerfetch
Peer-to-peer HTTP over WebRTC.
https://github.com/ambianic/peerfetch
end-to-end-encryption iot webrtc
Last synced: 1 day ago
JSON representation
Peer-to-peer HTTP over WebRTC.
- Host: GitHub
- URL: https://github.com/ambianic/peerfetch
- Owner: ambianic
- License: apache-2.0
- Created: 2021-08-15T03:34:42.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-03-14T18:12:37.000Z (almost 2 years ago)
- Last Synced: 2025-01-05T02:09:37.270Z (8 days ago)
- Topics: end-to-end-encryption, iot, webrtc
- Language: TypeScript
- Homepage:
- Size: 1.4 MB
- Stars: 600
- Watchers: 4
- Forks: 18
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-webrtc - peerfetch - Peer-to-peer HTTP over WebRTC. (Libraries / JavaScript)
README
# peerfetch
Peer-to-peer HTTP over WebRTC. Implements an http client wrapper (similar to [HTML fetch](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch)) and a corresponding server side HTTP proxy over WebRTC DataChannel. Allows direct secure access from a web browser to edge devices (IoT or servers) hidden behind a firewall.
Highlights:
- Excutes in safe application space (no `sudo`)
- End to end encryption
- No custom VPN setup needed
- No cloud middleman for data tunneling
- No dynamic DNS service required
- No custom firewall rules required
- Programming language agnostic. (Currently available in JavaScript and Python)# Hello World example
See this [README](examples/helloworld/README.md) for a step by step Hello World example.
# How it works
For an in-depth technical discussion and project background, see [this blog post](https://webrtchacks.com/private-home-surveillance-with-the-webrtc-datachannel/).
# Hands-on Workshop
[Here is the recording](https://www.youtube.com/watch?v=LFKYtL1_RjQ) of a `peerfetch` workshop hosted by [Python Austin](https://github.com/Jacob-Barhak/EveningOfPythonCoding).
# Use cases:
- Direct user access from a web app to private home security camera without sharing footage with a cloud provider.
- IoT device mesh with direct p2p communication.
- Personal web apps can share data directly (files, notes, photos) only with the end user without exposing a public IP address.
- Federated learning - ML models can train on local user data and share learned states directly with each other without a centralized model aggregation server.# Used by
- [Ambianic UI PWA](https://github.com/ambianic/ambianic-ui)
- [Ambianic Edge](https://github.com/ambianic/ambianic-edge)