- Dependencies:
ruby 2.1.0p0
protobuf
ruby-protofbu (bundle)
openssl (available in path)
- Setup keys
#-b server base port
#-s server instances
#-c client instances
ruby setup.rb -b 10000 -s 5 -c 5
- Start server
#-b base port as used in setup.rb
#-i server id 0..4
ruby server.rb -b 10000 -i 0
ruby server.rb -b 10000 -i 1
ruby server.rb -b 10000 -i 2
ruby server.rb -b 10000 -i 3
ruby server.rb -b 10000 -i 4
- Start clients
#-i client id 0..4
# more options available with -h
ruby client.rb -i 0
ruby client.rb -i 1
ruby client.rb -i 2
ruby client.rb -i 3
ruby client.rb -i 4
- Decrypt messages
To decrypt the following messages
[M] -> client1 [bbc4aa3fa029fd3e59f6f68d0017ea4a90ed138c]
run
ruby decryptor.rb -r client1 -m bbc4aa3fa029fd3e59f6f68d0017ea4a90ed138c