summaryrefslogtreecommitdiff
path: root/toxcore/onion_client.h
diff options
context:
space:
mode:
Diffstat (limited to 'toxcore/onion_client.h')
-rw-r--r--toxcore/onion_client.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/toxcore/onion_client.h b/toxcore/onion_client.h
index 6b960e40..4affcc6a 100644
--- a/toxcore/onion_client.h
+++ b/toxcore/onion_client.h
@@ -172,6 +172,13 @@ int onion_set_friend_online(Onion_Client *onion_c, int friend_num, uint8_t is_on
172 */ 172 */
173int onion_getfriendip(Onion_Client *onion_c, int friend_num, IP_Port *ip_port); 173int onion_getfriendip(Onion_Client *onion_c, int friend_num, IP_Port *ip_port);
174 174
175/* Copy friends DHT public key into dht_key.
176 *
177 * return -1 on failure (no key copied).
178 * return 0 on success (key copied).
179 */
180int onion_getfriend_DHT_pubkey(Onion_Client *onion_c, int friend_num, uint8_t *dht_key);
181
175#define ONION_DATA_IN_RESPONSE_MIN_SIZE (crypto_box_PUBLICKEYBYTES + crypto_box_MACBYTES) 182#define ONION_DATA_IN_RESPONSE_MIN_SIZE (crypto_box_PUBLICKEYBYTES + crypto_box_MACBYTES)
176#define ONION_CLIENT_MAX_DATA_SIZE (MAX_DATA_REQUEST_SIZE - ONION_DATA_IN_RESPONSE_MIN_SIZE) 183#define ONION_CLIENT_MAX_DATA_SIZE (MAX_DATA_REQUEST_SIZE - ONION_DATA_IN_RESPONSE_MIN_SIZE)
177 184