Simon Désaulniers
6c0c87a53f
fix variable captured in lambda after findNode
...
findNode requests are not related to searches. No operations other than calling
newNode() is required after a findNode request have completed. NetworkEngine
already takes care of calling newNode().
2016-05-02 15:25:15 -04:00
Simon Désaulniers
e001d8560d
fix ipv4 vs ipv6 search node dumping properly
2016-05-02 15:25:15 -04:00
Simon Désaulniers
848d95c8b2
Properly handling request status as shared_ptr
...
this is concerning the shared_ptr objects in SearchNode.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
e8ec4bb8b4
fix scheduler wrong returned time upon run()
...
makes more sense to return the "nextJobTime".
2016-05-02 15:25:15 -04:00
Simon Désaulniers
82f67f642f
fix wrong nodes serlialisation bug
2016-05-02 15:25:14 -04:00
Simon Désaulniers
407d717c5e
handling request status editing in NetworkEngine
2016-05-02 15:25:14 -04:00
Simon Désaulniers
244877526f
fix blacklisting for wrong reason.
2016-05-02 15:25:14 -04:00
Simon Désaulniers
1e485b1b0c
handling sending requests 3 times before expire
2016-05-02 15:25:14 -04:00
Simon Désaulniers
cc0d3f4195
all refs to Search are std::shared_ptr
2016-05-02 15:25:14 -04:00
Simon Désaulniers
b74e42eae9
using scheduler for timing dht operations
2016-05-02 15:25:14 -04:00
Simon Désaulniers
8364a61082
moving network stuff to NetworkEngine
...
dht_socket variables can be handled in NetworkEngine. Dht::network_engine now
declared as value instead of std::unique_ptr.
2016-05-02 15:25:14 -04:00
Simon Désaulniers
4b13fcac70
fixing various compilation errors
2016-05-02 15:25:14 -04:00
Simon Désaulniers
17216afe0f
request status fixups
2016-05-02 15:25:14 -04:00
Simon Désaulniers
2df9cd5363
send* calls to network engine + on done routines
2016-05-02 15:25:14 -04:00
Simon Désaulniers
69fab983f5
[WIP] ondone + searchnode status
2016-05-02 15:25:14 -04:00
Simon Désaulniers
74b265641d
checking UDP replytime in network engine
2016-05-02 15:25:14 -04:00
Simon Désaulniers
ba8d1af008
using map for ordering searches structures
...
Now ordering searches by InfoHash in different maps (ipv4 and ipv6). This is a
minor improvement for queries over searches.
2016-05-02 15:25:14 -04:00
Simon Désaulniers
9faef0427f
send* methods return NetworkEngine::RequestStatus
...
Previously, the request id was returned. This was needed for cancelling
requests. Returning std::shared_ptr<RequestStatus> enables cancelling the
requests, checking if a request is done and access to timings concerning this
request. This will replace the SearchNode's RequestStatus.
2016-05-02 15:25:14 -04:00
Simon Désaulniers
4383e83dda
add initial schedular class.
2016-05-02 15:25:14 -04:00
Simon Désaulniers
0f94e0de0c
moved infohash constexpr where appropriate
2016-05-02 15:25:14 -04:00
Simon Désaulniers
a1333fcaa5
handling notify listeners when storage changed
2016-05-02 15:25:14 -04:00
Simon Désaulniers
f93fb92ff5
add NetworkEngine::processMessage
2016-05-02 15:25:14 -04:00
Simon Désaulniers
2a61d79b42
enabling DHT log in network engine.
2016-05-02 15:25:14 -04:00
Simon Désaulniers
44d5a0620c
add reception callbacks
2016-05-02 15:25:14 -04:00
Simon Désaulniers
90b73bca56
add closest nodes buffering methods
2016-05-02 15:25:14 -04:00
Simon Désaulniers
594de2bd88
factorized common dependencies
2016-05-02 15:25:14 -04:00
Simon Désaulniers
48512bfd0f
delete packet processing methods in dht.cpp
2016-05-02 15:25:14 -04:00
Simon Désaulniers
9e950c8fed
serialization and packing methods
2016-05-02 15:24:58 -04:00
Simon Désaulniers
91fa097195
add template erase_if for map
2016-05-02 15:24:58 -04:00
Simon Désaulniers
ee3caba05e
add intial NetworkEngine class
2016-05-02 15:24:58 -04:00
Adrien Béraud
96f0bffefa
python: env on first line
2016-05-02 15:13:37 -04:00
Adrien Béraud
e2e30445dc
disable storage maintenance
2016-05-02 15:13:37 -04:00
Adrien Béraud
d48913e9d9
scanner: show more node infos
2016-05-01 15:27:49 -04:00
Adrien Béraud
9b45eabb00
infohash: remove std::hash
...
InfoHash is an hash itself, std::hash reduces the precision,
could cause potential security issues or bugs.
2016-05-01 15:27:13 -04:00
Adrien Béraud
6e0e63c3a5
CMake: add static/shared library build options
...
Add -DOPENDHT_STATIC=Off to disable static library build,
add -DOPENDHT_SHARED=Off to disable shared library build.
2016-04-30 03:16:05 -04:00
Adrien Béraud
08c21069c4
filters: add 'or' chaining
2016-04-30 03:16:05 -04:00
Adrien Béraud
1af71e88a7
filters: handle null filter in chain()
2016-04-30 03:16:05 -04:00
Adrien Béraud
444cdaa5d6
dht: remove unused code
2016-04-30 03:16:05 -04:00
Adrien Béraud
b5ac68d833
dhtrunner: move buffer declaration
2016-04-30 03:16:05 -04:00
Adrien Béraud
1a0427500c
Merge pull request #64 from zorun/master
...
dhtscanner: Report both IPv4 and IPv6 for the same ID
2016-04-28 17:12:05 -04:00
Baptiste Jonglez
269fc57f22
dhtscanner: Report both IPv4 and IPv6 for the same ID (dual-stacked peers)
2016-04-28 12:08:22 +02:00
Adrien Béraud
54143d58bf
dht: limit search nodes
...
* Don't remove candidate nodes (they are counted as "bad" nodes)
* Remove as much nodes as necessary to keep the node count bounded
2016-04-26 15:35:28 -04:00
Adrien Béraud
4683310933
extend fix to previous GCC versions
...
Fix suport of GCC 4.8 by extending the fix to
versions before 4.9
2016-04-21 21:46:37 -04:00
Adrien Béraud
d12e5c5af7
Merge pull request #62 from yomgui1/master
...
fix support of gcc 4.9
2016-04-19 16:42:17 -04:00
Guillaume Roguez
ed7a92481c
fix support of gcc 4.9
...
Some Android NDK uses gcc 4.9.0 and this one has a bug
that prevent to use "default" keyword to assign defaulted
methods (like move-constructor).
This issue is solved in 4.9.2.
This patch permits gcc 4.9.0 support by implementing
by hand previously defaulted methods.
2016-04-19 16:25:51 -04:00
Adrien Béraud
69e3addb2c
crypto: add CA certificate generation options
2016-04-19 12:30:42 -04:00
Adrien Béraud
ff2df41c76
dht: improve token serialization
2016-04-19 12:30:00 -04:00
Simon Désaulniers
d718b66aad
python: add missing enable log method
2016-04-18 16:31:29 -04:00
Adrien Béraud
30d5f7bea5
msgpack: add support for 1.4+
2016-04-14 23:05:37 -04:00
Adrien Béraud
90a9c16d4f
Merge pull request #60 from sim590/fix-base-iterator-segfault
...
dht: fixes out of range container erase.
2016-04-14 18:09:50 -04:00