Age | Commit message (Collapse) | Author |
|
Fixed circular dependency between DHT and net_crypto: DHT no longer
depends on net_crypto.
Moved the crypto request packets functions to crypto core and DHT.
Cleaned up/added some defines that can be used to get the true maximum
length of things like the friends request message.
MAX_DATA_SIZE has been replaced in most places by more appropriate defines.
|
|
Started writing the code.
Astyled some files.
|
|
Moved Bunch of functions from net_crypto to crypto_core.
decrypt_data_fast and decrypt_data_symmetric were the same thing
therefore, removed decrypt_data_fast.
Replaced all the crypto_secretbox_* defines with the equivalent
crypto_box_* one.
New define: crypto_box_KEYBYTES that is equal to
crypto_box_BEFORENMBYTES.
|
|
Removed a bunch of useless space from various structs.
pack_nodes() and unpack_nodes() are now used to transmit lists of
nodes for the DHT and onion parts. They provide a way to transmit
both ipv6 and ipv4 nodes in the same packet in a portable way that
takes as little space as possible without compression.
Using pack_nodes, merged the send nodes and send nodes ipv6 packets
into one packet greatly reducing the risk of amplification attacks.
|
|
|
|
Use get_shared_key() in more places.
|
|
Shared keys for recieved DHT packets are now stored in a special array
so that they don't need to be recomputed for nodes that send us lots of
packets.
|
|
Only compute the shared key once instead of twice for received DHT
requests/responses.
|
|
|
|
|
|
|
|
|
|
This fixes hole punching for some NATs.
|
|
|
|
|
|
|
|
Fixed test in network_test failing on some machines because of localhost
ipv6 issues.
|
|
|
|
|
|
|
|
|
|
|
|
Fixed a couple of issues related to that.
|
|
Added onion_client to the build system.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
No functionality changed.
|
|
Fix a code cleanup.
|
|
https://github.com/FullName/ProjectTox-Core into FullName-assoc-refresh-distant-data
|
|
DHT.c:
- get_close_nodes():
- allow two 'indirect' nodes ('indirect' as in distant from us and therefore not tested regularly, "bad")
- be consequent when testing for NULLed results, pack nodes_list dense
- (logging) dump number of found entries from assoc
- returnedip_ports():
- fix code cleanup, the entry to be added is about the node we were told, not about the node who told us
assoc.c:
- Assoc_get_close_entries(): break from loops as soon as a marking-invalid-node is hit
|
|
|
|
|
|
|
|
AF_INET/AF_INET6 can vary across devices, we introduce TOX_AF_INET and
TOX_AF_INET6 to fix this.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
https://github.com/FullName/ProjectTox-Core into FullName-sendnodes-with-assoc
|
|
DHT.c:
- get_close_nodes(): use assoc to find nodes for the requested reference id
- handle_sendnodes*(): set a proper timestamp for "heard" nodes
assoc.*:
- expand Assoc_close_entries by flags for additional restrictions for search
- Assoc_get_close_entries(): honor the new flags
- new_Assoc() prime handling: min. prime is now 5 instead of 3, and up to 25 is handled directly
- Assoc_status(): added address family for seen/heard, print of hash is now fixed width
|
|
|
|
|
|
|
|
Should lower CPU usage by a bit.
|