Skip to content

femrawr/redamancy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Redamancy

A proof of concept on how Discord can be used as a middleman to transfer (encrypyted) data from one device to another.

Basically how it works (sending/receiving commands/messages)

How sending/receiving commands/messages works

  1. send command (e.g. take a screenshot)
  2. command gets encrypted with AES-256-GCM
  3. the encrypted command gets sent to discord
  4. the bot running on the other receives the message
  5. it decrypts it and runs the command (e.g. take a screenshot)
  6. it sends back the data (e.g. the bytes of the screenshot) encrypted with AES-256-GCM
  7. the bot running on your device receives the message
  8. it decrypts the data and displays it on the control web page

Basically how key exchange works

  1. both bots send their "calling" message
  2. when the writer bot sees the reader bots "calling" message it will stop and generate a ECDH key pair and send the public key
  3. when the reader bot sees a message prefixed with pk! it will stop and generate its own ECDH key pair and send the public key

Basically, if someone gets into the server, they will not be able to read anything that is sent by the bots.

Redamancy in action

Redamancy in action

  1. the bots send their "calling" message
  2. they both acknowledge each other and exchange thier public keys
  3. the reader bot sends a command
  4. the writer bot executes it and sends back the data
  5. the data is then displayed on the control web panel

My code

This is an extremely simple example to demonstrate the concept.
The "screenshot" button on the web panel does not work. (yet)
You can configure the bots in /shared/constants.go

About

A POC on how Discord can be used as a middleman to transfer data to and from devices.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors