A decentralized routing model combining gossip-based membership convergence, extremal coordinate embedding, and XOR-based direct routing.
CECR is a hybrid routing system designed for peer-to-peer networks that:
| // PeerPigeon Streaming Patterns Examples | |
| // Who calls startMedia() determines the streaming pattern | |
| // ============================================================================= | |
| // 1:1 (One-to-One) Streaming - Video call between two people | |
| // ============================================================================= | |
| const peer1 = new PeerPigeon.PeerPigeonMesh({ | |
| enableCrypto: true, | |
| autoConnect: true |
| // Example useage at the bottom | |
| async function generateTOTP(username, secret, issuer, rotation, digits) { | |
| let totp = () => { | |
| return new Promise((resolve) => { | |
| let counter = TOTP.getCurrentCounter(rotation); | |
| TOTP.otp(secret, counter, digits, (cb) => { | |
| resolve(cb); | |
| }); | |
| }); | |
| }; |
| <!-- | |
| Adapted from Rebecca Manzi's [Todo App](https://github.com/rebeccamanzi/quasar-todo) for Quasar 1.0.0. This one works | |
| correctly with Quasar 2.11.5. To use it, update quasar.config.js > frameworks > plugins to include 'Notify' in the plugins | |
| array. | |
| --> | |
| <template> | |
| <q-page class="bg-grey-3 column"> | |
| <div class="row q-pa-sm bg-primary"> | |
| <q-input |
| const http = require('http') | |
| const Gun = require('gun') | |
| // Uncomment for ES6, and remove requires above | |
| // import http from 'http' | |
| // import Gun from 'gun' | |
| const server = http.createServer() | |
| const host = 'localhost' |
| /** | |
| * NOTE: Does not work with npm installed heroku-cli | |
| * Uninstall with: npm uninstall heroku -g | |
| * Install Heroku with: curl https://cli-assets.heroku.com/install.sh | sh | |
| */ | |
| const { exec } = require('node:child_process') | |
| const expect = require('../expect') | |
| describe('Heroku deploy', function(){ | |
| it('Returns an error if heroku CREATE fails', async function(){ |