aboutsummaryrefslogtreecommitdiff
path: root/node/node.hpp
diff options
context:
space:
mode:
authorDennis Brentjes <d.brentjes@gmail.com>2016-11-01 17:40:17 +0100
committerDennis Brentjes <d.brentjes@gmail.com>2016-11-01 17:40:17 +0100
commit9531b6bea9fb29074c588a4e4e8838f6d9335a2b (patch)
tree4d0e9429203bf5976507b43e6663f9fe0b21e6d0 /node/node.hpp
parentbdc26e00ad99f4f670df1a65b5e6439d0dfadc87 (diff)
downloadcmix-9531b6bea9fb29074c588a4e4e8838f6d9335a2b.tar.gz
cmix-9531b6bea9fb29074c588a4e4e8838f6d9335a2b.tar.bz2
cmix-9531b6bea9fb29074c588a4e4e8838f6d9335a2b.zip
Moves cmix calculation stuff outisde of the node class.
Moves the computations and cryptography to the the libcmix library where we can group and memory manage the underlying crypto-library.
Diffstat (limited to 'node/node.hpp')
-rw-r--r--node/node.hpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/node/node.hpp b/node/node.hpp
index 9e256c7..6587556 100644
--- a/node/node.hpp
+++ b/node/node.hpp
@@ -6,6 +6,7 @@
#include "sender.hpp"
#include "api.h"
+#include "cmix.h"
#include "cmix.pb.h"
@@ -50,7 +51,7 @@ class Node
};
boost::asio::io_service io_service;
- std::shared_ptr<boost::asio::ssl::context> ctx;
+ std::shared_ptr<boost::asio::ssl::context> ssl_ctx;
Server server;
typedef std::list<SSLReceiver> Purgatory;
@@ -66,9 +67,7 @@ class Node
SSLReceiver prev_node;
SSLSender next_node;
- Api api;
- KeyPair keypair;
- void* network_key;
+ CMixContext cmix_ctx;
std::vector<MixData> precomputation_data;
@@ -83,6 +82,7 @@ class Node
void handle_node_initialization(cmix_proto::Initialization const& init);
void handle_node_secretkey(cmix_proto::SecretKey const& secret);
void handle_node_prepre(cmix_proto::PrePre const& prepre);
+ void handle_node_premix(cmix_proto::PreMix const& premix);
void handle_node_message(cmix_proto::CMixMessage message);
void handle_client_keyexchange(ClientConnections::key_type handle, cmix_proto::KeyExchange ke);