summaryrefslogtreecommitdiff
path: root/core/net_crypto.h
diff options
context:
space:
mode:
authorirungentoo <irungentoo@gmail.com>2013-07-16 13:44:46 -0400
committerirungentoo <irungentoo@gmail.com>2013-07-16 13:44:46 -0400
commit5572396c5330d2464b5ce429eb71d69bde2ea39b (patch)
tree6f2ab82c33d86da674a2cfb5a250592ab4e70911 /core/net_crypto.h
parente63ba9c61b8603232e6fccc24f7bc763d22c3239 (diff)
Saving and loading of keys added.
Diffstat (limited to 'core/net_crypto.h')
-rw-r--r--core/net_crypto.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/core/net_crypto.h b/core/net_crypto.h
index 2476db10..df2cb9ca 100644
--- a/core/net_crypto.h
+++ b/core/net_crypto.h
@@ -118,6 +118,14 @@ int is_cryptoconnected(int crypt_connection_id);
118//Only call this function the first time the program starts. 118//Only call this function the first time the program starts.
119void new_keys(); 119void new_keys();
120 120
121//save the public and private keys to the keys array
122//Length must be crypto_box_PUBLICKEYBYTES + crypto_box_SECRETKEYBYTES
123void save_keys(uint8_t * keys);
124
125//load the public and private keys from the keys array
126//Length must be crypto_box_PUBLICKEYBYTES + crypto_box_SECRETKEYBYTES
127void load_keys(uint8_t * keys);
128
121//run this to (re)initialize net_crypto 129//run this to (re)initialize net_crypto
122//sets all the global connection variables to their default values. 130//sets all the global connection variables to their default values.
123void initNetCrypto(); 131void initNetCrypto();