Powerful library for secure p2p networking, written in c++ with boost.asio & openssl
When peer Alice sends connection request to peer Bob and Bob accepts it,
Bob sends his public RSA key to Alice, so Alice could encrypt generated AES key. Then,
after encrypting AES key with Bob's public key, Alice sends it (AES key) back to Bob.
Bob decrypts it with his private RSA key. After all of this Alice and Bob remember this
connection in an unordered_map<socket, AES_stuff>.
Now they both have identical AES key (and initialization vector) so they could chat each other
encrypting incoming messages
AES key is used to encrypt the messages, RSA - to encrypt AES key
boost
openssl
spdlog
nlohmann/json
google test (optionally)
- Build the project with cmake
- if you are using terminal 🤓:
mkdir cmake-build-debug cd cmake-build-debug cmake ..
- if you are using terminal 🤓:
- In your build directory run:
./cp2p_build [<listen_host>] <listen_port>
- Local network (via wi-fi)
./cp2p_build 192.168.2.12 1234
./cp2p_build 192.168.2.13 1234
- On local host:
./cp2p_build 1234
./cp2p_build 1234