Coder Social home page Coder Social logo

cathode's Introduction

             _    _                 _       
            | |  | |               | |      
  ___  __ _ | |_ | |__    ___    __| |  ___ 
 / __|/ _` || __|| '_ \  / _ \  / _` | / _ \
| (__| (_| || |_ | | | || (_) || (_| ||  __/
 \___|\__,_| \__||_| |_| \___/  \__,_| \___|
 Now with ENCRYPTED PACKET technology!

cathode

Encrypted P2P video chat in your terminal


Cathode is a weakly-interacting coupling of two peices of software. First we start with p2pvc (the brilliant little app that renders the audio/video in your terminal), and then ZeroTier (an extremely small but very robust encrypted P2P virtual networking hypervisor). We use the library form found here. We then replace all of the socket API system calls with their libzt equivalents aaaaannnd we're done.

Hint: Use the Glass TTY VT220 font we've included. We think pairs well with cathode, installing this font and increasing your terminal's font size to about 24pt makes this whole experience much more immersive. Have fun!


git submodule update --init --recursive

macOS

brew install pkg-config
brew tap homebrew/science
brew install portaudio opencv
make cathode
make install

linux

yum install portaudio opencv
make cathode
make install
  • You might also need: portaudio-devel opencv-devel ncurses-devel

Usage

Generate ID (or display a previously generated ID)

  • cathode -M

To view yourself:

  • cathode -Z [your_id] -v

If you have a friend's ZeroTier ID or ZeroTier IP address you can connect to them via:

  • cathode -Z [id] -v
  • cathode -N [nwid] -R [id] -v
  • cathode -N [nwid] -S [zt-ipv6-address] -v

Where -v is to enable video (as opposed to only audio)

Uninstall

  • make uninstall

Notes

This app is meant to be a simple demonstration of how you can add ZeroTier to your application. In this example there's only about ten points where modifications to p2pvc were needed. Since we want all network traffic to be handled by ZeroTier we swapped out the system's native calls with our own.

For instance, the p2plib.c's p2p_connect() function, we see:

con->socket = socket(curr_addr->ai_family, curr_addr->ai_socktype, curr_addr->ai_protocol);

We change it to the following:

con->socket = zts_socket(curr_addr->ai_family, curr_addr->ai_socktype, curr_addr->ai_protocol);

We also do this for every instance of bind(), connect(), accept(), listen(), etc. The substituted calls are designed to be perfectly compatible with each system's variation so substitution could be as simple as a find+replace.

cathode's People

Contributors

joseph-henry avatar

Watchers

Yashodhan avatar

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.