summaryrefslogtreecommitdiff
path: root/toxcore/onion_client.c
diff options
context:
space:
mode:
authoriphydf <iphydf@users.noreply.github.com>2016-09-12 16:48:35 +0100
committeriphydf <iphydf@users.noreply.github.com>2016-09-16 12:06:02 +0100
commit1494e474dde58ec6e446cdbfad9a8d89f6c4796c (patch)
treee454a18a0f61468d10833d8e80039d025f94f568 /toxcore/onion_client.c
parent37c041f8159f7e89f2585243e9b8073f47d77fd1 (diff)
Ensure that all TODOs have an owner.
In the future, all TODOs added either need a bug number (TODO(#NN)) or a person's github user name. By default, I made irungentoo the owner of all toxcore TODOs, mannol the owner of toxav TODOs, and myself the owner of API TODOs.
Diffstat (limited to 'toxcore/onion_client.c')
-rw-r--r--toxcore/onion_client.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/toxcore/onion_client.c b/toxcore/onion_client.c
index 04822cc1..316ed3d1 100644
--- a/toxcore/onion_client.c
+++ b/toxcore/onion_client.c
@@ -203,7 +203,7 @@ static int is_path_used(const Onion_Client_Paths *onion_paths, const Node_format
203 continue; 203 continue;
204 } 204 }
205 205
206 // TODO: do we really have to check it with the last node? 206 // TODO(irungentoo): do we really have to check it with the last node?
207 if (ipport_equal(&onion_paths->paths[i].ip_port1, &nodes[ONION_PATH_LENGTH - 1].ip_port)) { 207 if (ipport_equal(&onion_paths->paths[i].ip_port1, &nodes[ONION_PATH_LENGTH - 1].ip_port)) {
208 return i; 208 return i;
209 } 209 }
@@ -228,8 +228,8 @@ static bool path_timed_out(Onion_Client_Paths *onion_paths, uint32_t pathnum)
228 * return -1 on failure 228 * return -1 on failure
229 * return 0 on success 229 * return 0 on success
230 * 230 *
231 * TODO: Make this function better, it currently probably is vulnerable to some attacks that 231 * TODO(irungentoo): Make this function better, it currently probably is
232 * could de anonimize us. 232 * vulnerable to some attacks that could deanonimize us.
233 */ 233 */
234static int random_path(const Onion_Client *onion_c, Onion_Client_Paths *onion_paths, uint32_t pathnum, Onion_Path *path) 234static int random_path(const Onion_Client *onion_c, Onion_Client_Paths *onion_paths, uint32_t pathnum, Onion_Path *path)
235{ 235{
@@ -558,7 +558,7 @@ static int client_add_to_list(Onion_Client *onion_c, uint32_t num, const uint8_t
558 memcpy(list_nodes[index].public_key, public_key, crypto_box_PUBLICKEYBYTES); 558 memcpy(list_nodes[index].public_key, public_key, crypto_box_PUBLICKEYBYTES);
559 list_nodes[index].ip_port = ip_port; 559 list_nodes[index].ip_port = ip_port;
560 560
561 //TODO: remove this and find a better source of nodes to use for paths. 561 // TODO(irungentoo): remove this and find a better source of nodes to use for paths.
562 onion_add_path_node(onion_c, ip_port, public_key); 562 onion_add_path_node(onion_c, ip_port, public_key);
563 563
564 if (is_stored == 1) { 564 if (is_stored == 1) {
@@ -718,7 +718,7 @@ static int handle_announce_response(void *object, IP_Port source, const uint8_t
718 } 718 }
719 } 719 }
720 720
721 //TODO: LAN vs non LAN ips?, if we are connected only to LAN, are we offline? 721 // TODO(irungentoo): LAN vs non LAN ips?, if we are connected only to LAN, are we offline?
722 onion_c->last_packet_recv = unix_time(); 722 onion_c->last_packet_recv = unix_time();
723 return 0; 723 return 0;
724} 724}