Alden Torres
9d3cf5e68b
changed min_distance_exp for correctness and clarity ( #789 )
...
changed min_distance_exp for correctness and clarity
2016-06-06 18:22:33 -04:00
Arvid Norberg
223f24ca27
some cleanup and transition to std::unique_ptr ( #786 )
...
some cleanup and transition to std::unique_ptr
2016-06-05 14:07:24 -04:00
Alden Torres
db65eb320a
making dht counters additive ( #783 )
...
make dht counters additive to support both IPv4 and IPv6
2016-06-04 14:04:29 -04:00
Arvid Norberg
fa8232cd13
remove some old cruft and defines ( #785 )
...
remove some old cruft and defines
2016-06-04 10:03:13 -04:00
Alden Torres
7c4d92a627
Share the DHT storage for both IPv4 and IPv6 ( #762 )
2016-06-03 19:44:16 -04:00
Arvid Norberg
96999ad67f
replace uses of boost::bind with std::bind and lambdas ( #745 )
2016-05-25 00:31:52 -04:00
Arvid Norberg
178a41b187
clean up natpmp logging infrastructure a bit as well as test_peer_list ( #735 )
...
clean up natpmp logging infrastructure a bit as well as test_peer_list
2016-05-18 01:54:37 -04:00
Arvid Norberg
c6369194f0
simplify and optimize DHT routing table IP distance comparison ( #696 )
2016-05-03 23:22:25 -04:00
Arvid Norberg
c91a700c07
Msvc warnings ( #685 )
...
fix msvc warnings and build examples with warnings-as-errors
2016-05-02 12:36:21 -04:00
Steven Siloti
ff0675e64e
use standard array container ( #676 )
2016-04-30 23:10:47 -04:00
Arvid Norberg
20b41ad0b9
Threads ( #671 )
...
use std::thread, std::mutex, std::condition_variable instead of pulling them in from boost.asio internals.
2016-04-30 18:54:23 -04:00
Arvid Norberg
98fb7df56f
use standard unordered containers ( #673 )
2016-04-30 16:53:20 -04:00
Arvid Norberg
4e97bf556c
use override and final keywords (unconditionally) ( #668 )
...
use override and final keywords instead of macros.
2016-04-30 11:05:54 -04:00
Arvid Norberg
3c785b96fc
Merge pull request #268 from ssiloti/dht-ipv6
...
Support DHT over IPv6
2016-04-25 19:19:48 -04:00
Andrei Kurushin
62eb956c54
fix x64 build with VS2015 UP2 compiler ( #640 )
...
fix VS2015 compiler warnings for: address-model=64, deprecated-functions=on, link=shared
2016-04-25 17:22:09 -04:00
Steven Siloti
2d9a6b76f1
use asio::protcol instead of an enum/bool
2016-04-24 15:18:47 -07:00
Steven Siloti
2abd9867ce
IPv6 DHT support
...
Fixes #110
2016-04-24 14:26:57 -07:00
Steven Siloti
356d2506bd
extend dht_observer to support IPv6 external addresses
2016-04-24 14:26:57 -07:00
Steven Siloti
11fa4f3e47
support IPv6 in node_entry and m_ips
2016-04-24 14:26:57 -07:00
Arvid Norberg
7251575d98
This patch does: ( #633 )
...
1. simplifies and regularizies creation of listen sockets based on the listen
interfaces setting.
2. simplifies and improves the behavior of UDP sockets, which are now explicitly
opened per listen interface
3. transitions udp tracker, DHT and uTP socket manager over to using the new
udp sockets
4. greatly simplified udp_socket to only wrap a single underlying socket (as
opposed to one IPv4 and IPv6 socket)
5. improved behavior of bind-to-device
6. introduce an array_view type to make udp packet passing code simpler
7. simplify and make setting of DF flag more robust
8. simplify and regularize port mapping of listen sockets
2016-04-24 15:26:28 -04:00
arvidn
d17ae19391
Merge branch 'RC_1_1'
2016-04-11 02:08:06 -04:00
arvidn
08edf43b3f
fix to documentation generation to exclude private functions. fix makefile errors
2016-04-09 00:33:26 -04:00
arvidn
6d85c7c5f0
merge RC_1_1 into master
2016-03-08 01:10:48 -05:00
Alden Torres
4998bfedc6
Documentation typos
2016-03-04 10:43:25 -05:00
arvidn
3842a0a197
Merge branch 'RC_1_1'
2016-02-12 15:43:13 -05:00
Alden Torres
feb2fd34d6
Documentation typos and new lines
2016-02-11 19:53:43 -05:00
arvidn
d5203c67d9
add DHT rate limit test (simulation). introduce a new counter for dropped incoming dht messages.
2016-01-18 14:34:42 -05:00
arvidn
06b52f1421
some cleanup of the dht_socket_interface and fix tests and simulations to build with the dht disabled
2016-01-18 14:34:42 -05:00
arvidn
297b8943d0
move the DHT rate limiter into the dht_tracker class and remove the rate_limited_udp_socket type. This further simplifies the udp socket (preparing for moving it into the listen_socket structure)
2016-01-18 14:34:41 -05:00
arvidn
1f9f588e75
merge copyright year update and changelog from RC_1_0
2016-01-17 18:57:46 -05:00
arvidn
651b473908
add unit test for routing_table::update_node_id
2016-01-11 23:47:27 -05:00
arvidn
f4d643bd2d
instead of restarting the whole DHT when changing external IP, just rebuild the routing table and change the node IDs
2016-01-11 21:17:25 -05:00
arvidn
e3ba811ae4
improve name of m_timer in dht_tracker
2016-01-01 16:42:44 -05:00
arvidn
01e6b93854
simplify and improve unit test for distance_exp. make some immutable variables const in the DHT implementation. instead of waking up periodically just to check if it's time to refresh the DHT secret key, set the timer to only wake up to refresh the key. If we don't have a DHT observer (to ask for our external IP) or if we don't know our external IP, don't generate a node ID based on 0.0.0.0, just generate a random ID instead. Simplified and improved node replacement logic in the routing table a little bit
2016-01-01 16:42:37 -05:00
Arvid Norberg
ffb78f0378
Merge pull request #312 from ssiloti/export-verify-message
...
export verify_message and incoming_error
2015-12-30 22:51:38 -05:00
Steven Siloti
30076218f8
entry is a class not a struct
2015-12-30 17:25:00 -08:00
Steven Siloti
ac01ccc43a
add templated wrapper around verify_message
...
It was too easy to forget to update the ret and size parameters
when the size of desec changed. With this change we now automatically
get the size of desc and enforce that ret has the same size.
It would be nice if we could use bdecode_node ret[static Size] from C99
but that is not widely supported.
2015-12-29 20:35:36 -08:00
arvidn
505ae508f4
mark up some override functions and fix other clang warnings
2015-12-13 19:44:42 -05:00
Steven Siloti
c6f1e0bd7b
export verify_message and incoming_error
...
Also move these functions to a new msg.cpp. They are useful for plugins
which implement DHT extensions.
2015-12-05 18:20:08 -08:00
arvidn
98c9ac0448
fix msvc build
2015-12-03 19:28:57 -05:00
arvidn
69f4e94995
null_observer is used in a test now
2015-12-03 07:51:53 -05:00
arvidn
12dde0f415
actually add a test to the unit test
2015-11-30 19:07:35 -05:00
arvidn
332799bff2
make alert types declared final and disable the log alert declarations when logging is disabled
2015-11-29 10:16:02 -05:00
Steven Siloti
9c7edf803e
add override and a TODO
2015-11-22 18:58:32 -08:00
Steven Siloti
9f7aa7f3a6
fix segfault in put_data
...
If less than three nodes are found to put an item to then traversal_algorithm::start
will add router nodes. This leads to a crash in put_data::invoke when it tries to
read a token from uninitialized memory in a null_observer.
2015-11-22 16:05:24 -08:00
Steven Siloti
1f13343a70
const correctness
2015-11-22 10:02:26 -08:00
Arvid Norberg
42b129b9d5
Merge pull request #178 from thomas-yuan/put
...
Make dht_put_alert more accurate.
2015-11-21 02:30:45 -05:00
Thomas Yuan
ab70ad3e05
fix comments and unit test
2015-11-20 00:06:08 -05:00
Thomas Yuan
194ad410dc
Make dht_put_alert more accurate.
2015-11-20 00:06:08 -05:00
arvidn
fba0762353
fix some msvc warnings
2015-11-19 19:01:54 -05:00