Commit Graph

42 Commits (fda74a8454a028c9ec063f0074062e19fd25f7e7)

Author SHA1 Message Date
irungentoo fda74a8454 Restrict packet kinds that can be sent through onion path.
Taken from:
6b97acb773
2018-04-20 07:40:43 -04:00
irungentoo bd67129c3e
Added a define for the length of onion paths. 2015-05-01 15:46:48 -04:00
irungentoo e4ae993a80
Some small fixes.
Increased interval between onion key changes to 2 hours.
2015-04-20 20:40:32 -04:00
irungentoo f463cb52a2
Code cleanups.
Rename array in Node_format from client_id to public_key.
2015-01-29 19:38:44 -05:00
irungentoo b10aaecee5
Fixed gcc warnings. 2015-01-20 21:00:08 -05:00
irungentoo 5e1d6f5183
Fix TCP server regression.
onion.c was parsing recieved packets a bit too strictly and discarding
packets that had ips with non valid families.

TCP uses a non valid family to send back the packet to the proper
connected node.
2015-01-13 15:04:41 -05:00
irungentoo 93a998d15a
Code cleanups.
Moved some functions to onion.c.

Fixed possible portability issues.
2015-01-01 21:30:42 -05:00
irungentoo 8ac13beea4
Code cleanup.
Added length checks to ipport_pack() function.
2014-12-31 15:24:09 -05:00
irungentoo 8ff85f09cb
Check if received ip family is valid for the onion packets. 2014-12-31 12:30:39 -05:00
irungentoo 18b45ffade
Add function to get nodes from onion path. 2014-12-25 15:01:12 -05:00
irungentoo 6bbb939855
Cleaned up packet length types in toxcore.
They are now all uint16_t instead of sometimes being uint32_t.

Replaced some other uint32_t with unsigned ints.
2014-11-21 20:18:29 -05:00
irungentoo 70d338703d
Added function to create onion packets to send via TCP. 2014-08-13 06:41:35 -04:00
irungentoo f83fcbb13c
Added length check to onion_send_1(). 2014-08-11 15:48:33 -04:00
irungentoo 6d4fdb3597
Merge branch 'const_correctness' of https://github.com/schuetzm/ProjectTox-Core 2014-07-02 15:41:59 -04:00
Marc Schütz 1494992a9f Const-correctness for onion.c 2014-06-30 21:30:41 +02:00
Marc Schütz 0aa0cbda42 Const-correctness for toxcore/onion_announce.c 2014-06-30 21:26:51 +02:00
irungentoo a82cbfff6a
Preparation work to make onion packets go through TCP. 2014-06-18 19:44:49 -04:00
Marc Schütz 4940c4c62b Const correctness for various packet callbacks 2014-06-13 22:55:15 +02:00
notsecure d27a83820c added missing ipport_pack 2014-05-19 14:18:26 -04:00
notsecure 0d711afbec IP_Port packing unpacking in onion.c 2014-05-19 09:18:04 -04:00
irungentoo 384750af8c
Major cleanups.
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.
2014-04-23 11:35:40 -04:00
irungentoo 1bfe15ee88
Decided pretty much how the handshake would work.
Started writing the code.

Astyled some files.
2014-04-22 20:28:40 -04:00
irungentoo 9c6a8432ce Crypto related cleanups.
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.
2014-04-21 16:51:36 -04:00
irungentoo 98cba889a7
TCP server now has onion functionality.
All the IP/Port related structs now have __attribute__ ((__packed__))
2014-03-29 22:19:03 -04:00
irungentoo 8aaa5fe996
TCP server almost ready. 2014-03-28 22:37:42 -04:00
irungentoo 3bcc6e2ae5 CPU optimizations.
Use get_shared_key() in more places.
2014-03-05 16:54:17 -05:00
irungentoo cebae58ddc Major speed/cpu usage/bandwidth improvements to onion. 2014-02-26 12:18:47 -05:00
irungentoo cfb820c2fc Made onion paths expire. 2014-02-13 13:03:19 -05:00
irungentoo 0d53abebcd Fixed possible anonimity leak with the onion routing. 2014-01-25 13:33:39 -05:00
irungentoo 4e1bc481c5 Fixed some portability issues. 2014-01-21 07:31:19 -05:00
irungentoo cd2474a2f6 Incorporated onion into Tox.
Fixed a couple of issues related to that.
2014-01-17 13:35:40 -05:00
irungentoo 6cd1e7fb70 Tests added and some fixes for the onion part. 2014-01-05 19:22:38 -05:00
irungentoo d46891c3b7 A bit of work done on the onion part. 2014-01-03 22:13:20 -05:00
irungentoo ec429b7fee Some small cleanups.
TODO: remove old todos that have been done.
2014-01-01 22:24:09 -05:00
irungentoo 97b9a9cf04 Added onion.c to build system and added a test. 2013-12-31 23:18:37 -05:00
irungentoo 5341801bf1 Fixed small issues in onion.c 2013-12-31 22:05:33 -05:00
irungentoo 9c9e3b0e45 Added a function to create and send a onion packet. 2013-12-30 12:20:30 -05:00
irungentoo 346dc5265e onion.c now handles another packet type. 2013-12-29 15:10:09 -05:00
irungentoo 822c7d3dca Another packet type is now handled by onion.c 2013-12-28 21:51:09 -05:00
irungentoo 86aff82a9f Another packet type added to onion.c 2013-12-27 15:21:16 -05:00
irungentoo 042d759847 All recv packets now handled. 2013-12-25 20:23:14 -05:00
irungentoo ad2037e165 Added the shell of onion.{c, h} 2013-12-24 16:22:56 -05:00