atraczyk
9987485f63
clean up solution
2017-02-17 18:15:54 -05:00
Adrien Béraud
b08b2f14f2
sockaddr: add missing header and typedef
2017-02-17 12:09:33 -05:00
Adrien Béraud
1e7ba56aeb
Merge pull request #174 from sim590/announce-status-fix
...
dht: standardize announce status check
2017-02-16 23:01:10 +01:00
Simon Désaulniers
faf23195a4
dht: standardize announce status check
...
Fixes a bug where some callbacks wouldn't be called when a dummy request was
inserted to cancel some operation while not using the
net::Request::State::COMPLETED flag as per 19c47ec .
2017-02-16 16:29:21 -05:00
Adrien Béraud
0d66b9435f
dht: print IPv6 search log
2017-02-16 11:49:38 -05:00
Adrien Béraud
49353e2d5c
dht: replace expired node only when bucket is full
2017-02-10 00:38:51 -05:00
Adrien Béraud
c4d5621f67
network: treat loopback address as sender address
...
When learning about nodes in an answer,
we used to drop nodes with loopback address.
Address is now replaced by the packet sender
address and the port is preserved.
2017-02-10 00:10:11 -05:00
Adrien Béraud
aa2227bdfc
SockAddr: add utility methods
2017-02-09 23:49:06 -05:00
Adrien Béraud
34908d573f
network engine: use make_shared
2017-02-08 14:14:06 -05:00
Adrien Béraud
469774037e
Merge pull request #169 from savoirfairelinux/crypto_checks
...
crypto: make Certificate::isCA() more restrictive
2017-02-07 23:27:15 +01:00
Adrien Béraud
93c5ad7cbc
crypto: make Certificate::isCA() more restrictive
2017-02-07 16:51:16 -05:00
Adrien Béraud
03d52e4284
Merge pull request #170 from sim590/dht-random-id
...
dht: randomize id in Dht layer
2017-02-07 22:08:57 +01:00
Simon Désaulniers
9d83ee169b
dht: randomize id in Dht layer
2017-02-07 15:58:04 -05:00
Adrien Béraud
43b181ebbf
python: add bindings for network, maintain_storage
2017-01-25 11:57:42 -05:00
Adrien Béraud
ac65ca5177
add shortcut Sp for std::shared_ptr
2017-01-24 23:38:31 -05:00
Adrien Béraud
42671be21e
Merge pull request #168 from sim590/announce-op-fixes
...
Announce op fixes
2017-01-20 11:19:33 -05:00
Simon Désaulniers
efa6930de2
dht: fix multiple put on a single search segfault
...
"Iterators pointing to an element between the new logical end and the physical
end of the range are still dereferenceable, but the elements themselves have
unspecified values (as per MoveAssignable post-condition)."
- http://en.cppreference.com/w/cpp/algorithm/remove
2017-01-20 02:40:05 -05:00
Simon Désaulniers
19c47ec781
dht: correctly tell if value is announced
...
* A value should be considered announced if all good nodes up to a count of
TARGET_NODES have been tried in the search .
* Bug fix where SearchNode::isAnnounced criteria was not consistent with
announce operation.
2017-01-20 02:39:59 -05:00
Adrien Béraud
435cd554e6
securedht: add getLongId()
2017-01-19 12:09:12 -05:00
Adrien Béraud
10c70ebd12
hash: add string I/O
2017-01-19 12:08:49 -05:00
Adrien Béraud
7da3ff1bba
hash: add support for SHA256 public key fingerprints
2017-01-18 16:08:31 -05:00
Adrien Béraud
a222e30428
update to version 1.3.0
1.3.0
2017-01-17 16:44:02 -05:00
Adrien Béraud
bd822fce19
dht: don't stop node insertion on expired search
2017-01-17 16:43:32 -05:00
Adrien Béraud
cabe9dbeb5
dht: declare StorageBucket as class
2017-01-16 17:53:21 -05:00
Adrien Béraud
99b7a07350
sockaddr: make ipCmp comparator const
2017-01-16 17:51:59 -05:00
Adrien Béraud
756e0bd3d8
dht: cleanup paginate
...
Reduce indentation level by 4,
add code documentation,
remain under 120 chars wide.
2017-01-15 19:02:15 -05:00
Adrien Béraud
9b0ce12b5f
Update README.md
2017-01-15 02:18:37 -05:00
Adrien Béraud
e29c2df002
Merge pull request #166 from sim590/license-notice
...
update license notice (2017)
2017-01-15 02:15:10 -05:00
Simon Désaulniers
b03a8b5b50
update license notice (2017)
2017-01-13 17:27:29 -05:00
Adrien Béraud
32f5175d68
dht: expire storage just on time
2017-01-13 16:06:46 -05:00
Adrien Béraud
7d3a54db57
dht: storage rate limiting
2017-01-13 16:06:46 -05:00
Adrien Béraud
3fb7c2acfe
Merge pull request #165 from atraczyk/master
...
msvc: change contrib repo sources
2017-01-11 14:48:56 -05:00
atraczyk
bce5d35b51
msvc: change contrib repo sources
2017-01-11 14:37:22 -05:00
Adrien Béraud
b6dca5ccd6
dht: use new NodeStats structure to provide stats
2017-01-10 23:34:56 -05:00
Adrien Béraud
23b2712400
dht: use SHA265 instead of SHA512 for the op token
...
The op token is renewed regularly (around every 30 minutes),
so SHA256 provides enough security for this non-sensitive token.
SHA256 takes 32 bytes instead of 64 bytes for SHA512,
and the token is included in every listen requests,
renewed every 30 seconds, and every answer to get.
In the context of limited bandwith usage, using SHA256 seems more appropriate.
This change is backward and forward compatible.
2017-01-10 23:34:56 -05:00
Adrien Béraud
63bec73885
default types: make TrustRequest a map, add confirm field
2017-01-10 14:24:42 -05:00
Simon Désaulniers
af5e0c8982
node: remove expired flag when a node reaches us
2017-01-09 14:40:42 -05:00
Adrien Béraud
5a7c8753e1
python/tools: use asyncio in pingpong test
2017-01-09 14:40:06 -05:00
Adrien Béraud
19fdec96ca
dht: remove getStatus with get
2017-01-09 14:38:51 -05:00
Adrien Béraud
2208a06232
dht: clear acked with announce
...
Clear the search node acked when clearing
the corresponding announce, after checking
the announce status for all announces.
2017-01-09 00:06:54 -05:00
Adrien Béraud
2cfcaf3909
Merge pull request #164 from sim590/connectivity-changes
...
routing_table: complete connecting state resolution
2017-01-04 14:04:37 -05:00
Simon Désaulniers
620868b5d6
routing_table: complete connecting state resolution
...
After a connectivity change, the DHT would enter the "connecting" state in order
to try to resolve good nodes. However, the previous algorithm would
probabilistically increase time for completion each time a node would fail to
resolve. We now avoid this by prioritizing non-expired nodes in the process.
Also, a subtle error would sensibly stop the process for 30 minutes due to using
the Node::NODE_EXPIRE_TIME constant instead of Node::MAX_RESPONSE_TIME.
2017-01-03 17:48:40 -05:00
Adrien Béraud
e7295bac7b
crypto: prevent signing certificates with a non-CA certificate
2017-01-02 16:16:28 -05:00
Adrien Béraud
38aa86de2a
crypto/crl: add getIssuerName, getIssuerUID
2016-12-29 11:19:27 -05:00
Adrien Béraud
fdf476a3f3
cmake: generate opendhtConfigVersion.cmake
2016-12-29 11:18:45 -05:00
Adrien Béraud
22f27a6cc0
cmake: generate opendhtConfig.cmake
2016-12-28 18:19:16 -05:00
Adrien Béraud
c72ea8ce77
tools/scanner: don't use a certificate
2016-12-09 02:41:40 -05:00
Adrien Béraud
ea168353b9
tools/scanner: use urllib3 streaming
2016-12-09 02:41:12 -05:00
Adrien Béraud
79b9c4838e
Merge pull request #161 from savoirfairelinux/yomgui1-patch-1
...
remove InfoHash::toCString()
2016-12-06 18:35:56 -05:00
Guillaume Roguez
d6e86ebcc9
remove InfoHash::toCString()
...
Implementation of InfoHash::toCString() is broken
2016-12-06 18:28:14 -05:00