Adrien Beraud and Copilot
dff27203a4
build: prepare 4.5.0 release candidate 1
...
Co-authored-by: Copilot <223556219+Copilot@users.nply.github.com >
2026-11-03 22:48:09 -05:00
Adrien Beraud and Copilot
506d9f9cbb
ci: install MessagePack C++ headers on Ubuntu
...
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-11-03 22:44:50 -05:00
dependabot[bot]
349f4e5fc6
build(deps): bump pypa/cibuildwheel from 4.3.4 to 4.3.5
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 4.3.4 to 4.3.5.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v4.3.4...v4.3.5 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 4.3.5
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-11-03 22:41:04 -05:00
dependabot[bot]
11d69d02e8
build(deps): bump actions/setup-node from 6 to 7
...
Bumps [actions/setup-node](https://github.com/actions/setup-node ) from 6 to 7.
- [Release notes](https://github.com/actions/setup-node/releases )
- [Commits](https://github.com/actions/setup-node/compare/v6...v7 )
---
updated-dependencies:
- dependency-name: actions/setup-node
dependency-version: '7'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-11-03 22:40:02 -05:00
Adrien Beraud
3c87991e92
docs: make Rust README precise and factual
2026-10-29 22:46:57 -04:00
Adrien Beraud
52287bf608
ci: use npm environment for publishing
2026-10-29 22:27:34 -04:00
Adrien Beraud
061ce2deb4
docker: build with RelWithDebInfo
2026-10-29 22:27:04 -04:00
Adrien Beraud
64b536fb53
ci: publish Python wheels from the tag release workflow
2026-10-29 21:48:33 -04:00
Adrien Beraud
67c76f17de
README: add Node.js bindings
2026-10-29 21:20:25 -04:00
Adrien Beraud
25fde756e8
docs: add linked package and Docker badges
2026-10-29 21:12:35 -04:00
Adrien Beraud
f6b3eda280
rust: rewrite README
2026-10-29 20:55:07 -04:00
Adrien Beraud
9aee407a42
rust: avoid dual-stack conflict in startup error test
2026-10-29 10:35:51 -04:00
Adrien Beraud
722ef44c7d
rust: move owned Value directly through callbacks and streams
2026-10-28 23:51:46 -04:00
Adrien Beraud
6ed2720bd7
rust: test single-copy async value ownership
2026-10-28 23:51:46 -04:00
Adrien Beraud
9005f73141
rust: add optional Serde typed operations
2026-10-28 23:51:46 -04:00
Adrien Beraud
9785c0a127
rust: add typed operation regression tests
2026-10-28 23:51:41 -04:00
Adrien Beraud
5662cc36d1
rust: publish crate on release with trusted publishing
2026-10-28 22:04:57 -04:00
Adrien Beraud
e116cfe548
rust: add optional runtime-independent async API
2026-10-28 21:11:43 -04:00
Adrien Beraud
1c5e8378b8
rust: add async adapter regression tests
2026-10-28 21:11:42 -04:00
Adrien Beraud
c630e80345
ci: use trusted publishing for Python wheels
2026-10-29 00:26:07 +00:00
cyrille and Copilot
17f83edce4
proxy: add Huawei (HMS) push type
...
Route push notifications to Huawei devices, which have no Google Play
Services and therefore cannot receive FCM. gorush, already used as the
push relay, supports HMS natively as platform 3.
HMS takes its payload as a serialized JSON string in "huawei_data" and
carries its own ttl/priority fields, so it needs its own branch rather
than the generic "data" object used for FCM and APNs.
The enum value is appended last: MSGPACK_ADD_ENUM serializes it as an
integer, so reordering would break compatibility with deployed proxies.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-10-29 00:02:02 +00:00
Adrien Beraud
afab251376
nodejs: isolate native Linux dependency symbols
...
Use RTLD_DEEPBIND when loading the Linux addon so its llhttp calls do not resolve to Node's incompatible bundled parser. The CI image uses llhttp 9.2.1 while Node 22 exports 9.4.3, corrupting the heap when the proxy client starts. Preserve default loading on other platforms.
2026-10-27 23:04:32 -04:00
Adrien Beraud
86d452fbb6
nodejs: bundle source-built llhttp license notices
...
The Noble dependency image builds llhttp from source, so dpkg-query cannot identify its license package. Include the pinned upstream MIT notice when bundling Linux llhttp libraries while retaining package-owner checks for other dependencies.
2026-10-27 23:04:32 -04:00
Adrien Beraud
08ff775232
ci: rely on npm trusted publishing
2026-10-27 22:48:58 -04:00
Adrien Beraud
738e0e22bf
nodejs: add streaming iterators and startup proxy configuration
2026-10-27 22:46:34 -04:00
Adrien Beraud
8ec5b47c86
nodejs: test streaming iterators and proxy configuration
2026-10-27 22:09:21 -04:00
Adrien Beraud
e1c31568f9
readme: cleanup
2026-10-27 22:01:05 -04:00
Adrien Beraud
45bad769b4
nodejs: fix npm archive paths and validate release versions
2026-10-27 21:22:15 -04:00
Adrien Beraud
09780fd923
nodejs: publish verified npm archives from tag releases
2026-10-27 20:36:12 -04:00
Adrien Beraud
747e70d1ae
nodejs: simplify design
2026-10-27 20:12:17 -04:00
Adrien Beraud
05abfa89bf
nodejs: initialize GnuTLS before using the addon
2026-10-27 11:33:17 -04:00
Adrien Beraud
b714714128
build: bump version to 4.4.99
2026-10-27 10:21:04 -04:00
Adrien Beraud
2e8b36477d
ci: publish Noble OpenDHT release image
2026-10-27 09:59:17 -04:00
Adrien Beraud
14543ae477
docker: switch to ninja and add Noble Dockerfile
...
Use Ninja instead of Make in the main Dockerfile for faster builds
and install ninja-build in DockerfileDeps. Also, add a new
Dockerfile for Ubuntu Noble.
2026-10-27 09:57:33 -04:00
Adrien Beraud
044135732f
docker: add simdutf to remaining dependency images
2026-10-27 00:31:34 -04:00
Adrien Beraud
21b7f0d757
docker: restore Noble dependency image for Node builds
2026-10-27 00:31:34 -04:00
Adrien Beraud
a5bfd3d933
ci: test Node packages on Ubuntu 24.04 and 26.04
2026-10-27 00:26:08 -04:00
Adrien Beraud
af38323728
nodejs: release dispatcher before environment teardown
2026-10-27 00:14:56 -04:00
Adrien Beraud
62e0ded803
ci: use Ubuntu 26.04 for Node.js packages
2026-10-27 00:14:56 -04:00
Adrien Beraud
a09cfefe5e
tests: require native alignment for C hashes
2026-10-27 00:03:07 -04:00
Adrien Beraud
13f340694e
tools: rebuild proxy web client with concurrent live sessions
2026-10-27 00:03:07 -04:00
Adrien Beraud
3723c4acf1
nodejs: migrate runtime tooling and examples to ESM
2026-10-27 00:02:09 -04:00
Adrien Beraud
f19bca0df1
tests: enforce ESM imports for Node bindings
2026-10-27 00:02:09 -04:00
Adrien Beraud
fbc7f90897
tests: cover Node connectivity and concurrent CLI operations
2026-10-27 00:02:09 -04:00
Adrien Beraud
3a3c421ef9
nodejs: add an interactive dhtnode example
2026-10-27 00:02:09 -04:00
Adrien Beraud
9ec7a58ee3
tests: cover the Node dhtnode example CLI
2026-10-27 00:02:00 -04:00
Adrien Beraud
ce73eb052e
ci: build and verify Node-API npm packages
2026-10-27 00:02:00 -04:00
Adrien Beraud
d716fae4bc
nodejs: expose per-family connectivity status and events
2026-10-27 00:02:00 -04:00
Adrien Beraud
a040bfeebb
nodejs: add crypto APIs and relocatable npm prebuilds
2026-10-26 23:57:50 -04:00
Adrien Beraud
3223742d70
tests: cover Node crypto types and npm archive contents
2026-10-26 23:57:50 -04:00
Adrien Beraud
d2d56fcc20
tests: cover Node crypto persistence and authenticated values
2026-10-26 23:57:50 -04:00
Adrien Beraud
af814f027f
nodejs: add Node-API runner bindings over the C++ library
2026-10-26 23:57:50 -04:00
Adrien Beraud
2016a9e2fa
tests: verify Node TypeScript API and deferred garbage collection
2026-10-26 23:57:50 -04:00
Adrien Beraud
1db8abb7fc
c: align hash structs with native types
2026-10-26 23:57:50 -04:00
Adrien Beraud
3f7b1bc3f5
tests: cover unaligned C hash storage
2026-10-26 23:56:59 -04:00
Adrien Beraud
019c25633e
tests: initialize GnuTLS for MSVC C bindings
2026-10-26 23:56:43 -04:00
Adrien Beraud
8193f43593
tests: cover Node runner collection cancellation and queue overflow
2026-10-26 23:54:00 -04:00
Adrien Beraud
39564f14c1
tests: define Node-API binding lifecycle and loopback contracts
2026-10-26 23:54:00 -04:00
Adrien Beraud
83778d84fe
rust: update edition to 2024
...
Update the Rust edition to 2024 and mark the FFI extern block as unsafe.
2026-10-26 09:57:02 -04:00
Adrien Beraud
b61ee620e4
dht: schedule projected gets with matching reuse rules
2026-10-26 09:21:10 -04:00
Adrien Beraud
0d120eb5d4
tests: cover projected query request scheduling
2026-10-26 09:21:10 -04:00
Cyrille Béraud and Copilot
9b9056c0c8
dht: do not report unfiltered answers to filtered queries
...
Query::isSatisfiedBy() considers an unfiltered answer sufficient for a
filtered query, which is true for a vanilla get: onGetValuesDone() applies
the operation filter to the values before calling back.
A projected query is different. It receives the fields another query selected
and can no longer evaluate its own filters on them, all the more so as those
filters may target fields that were not selected at all. Two concurrent
queries such as "SELECT id" and "SELECT id WHERE value_type=1" therefore made
the filtered callback report identifiers whose type does not match, and
searchNodeGetDone() additionally cancelled its own request so it never got a
correctly filtered answer.
Add Query::isProjectionSatisfiedBy(), which additionally requires both queries
to apply the same filters, and use it for operations with a query callback.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-10-26 09:21:10 -04:00
Cyrille Béraud and Copilot
bf8e3ea251
value: compare field values in FieldValueIndex::containedIn
...
containedIn() only checked that the other index declared the same field
keys, never that they held the same values, contradicting its documented
contract of containment "with the same value".
Dht::query() uses containedIn() to deduplicate projected results. Because
every result of a given query shares the same projection schema, any two
results compared equal: the first one suppressed all the later ones, and the
"lesser" branch even erased the already reported result. A query selecting a
field therefore reported a single value regardless of how many matched.
Compare the FieldValue as well, and add a regression covering distinct
values, equal indexes and a narrower projection contained in a wider one.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-10-26 09:21:10 -04:00
Adrien Beraud
34eb86a119
value: support sequence numbers in wire filters
2026-10-26 09:19:57 -04:00
Adrien Beraud
75c789ceb2
rust: cover sequence filters across loopback nodes
2026-10-26 09:15:36 -04:00
Adrien Beraud
da438d1bd2
value: reproduce sequence filter serialization failure
2026-10-26 09:12:12 -04:00
Adrien Beraud
44e67e1389
rust: parse hexadecimal hashes with string length checks
2026-10-26 09:11:42 -04:00
Adrien Beraud
7f9126b3b0
rust: cover empty and short hexadecimal hashes
2026-10-26 09:10:39 -04:00
Adrien Beraud
574674d3a2
rust: own native pointers in movable handle wrappers
2026-10-26 09:10:16 -04:00
Adrien Beraud
c60703bfc3
rust: cover moves across native handle types
2026-10-26 09:10:16 -04:00
Adrien Beraud
a0220827cd
rust: reproduce moving native values out of boxes
2026-10-26 09:08:03 -04:00
Adrien Beraud
fb90211157
python: expose value state and harden runner operations
2026-10-26 01:10:34 -04:00
Adrien Beraud
9501465293
python: cover value state and binding safety regressions
2026-10-26 01:06:48 -04:00
Adrien Beraud
95bd26c3be
rust: bump version to 0.2.0 and add author
2026-10-26 00:51:27 -04:00
Adrien Beraud
87463c2d6c
rust: own callbacks and expose safe native binding APIs
2026-10-26 00:51:27 -04:00
Adrien Beraud
baf413dd0d
c: expose lifecycle queries crypto and callback ownership
2026-10-26 00:51:27 -04:00
Adrien Beraud
6bf01f3b6d
runner: release status callback captures on join
2026-10-26 00:51:27 -04:00
Adrien Beraud
852403fbeb
crypto: verify signatures using the public key algorithm
2026-10-26 00:51:27 -04:00
Adrien Beraud
5f6d5c769e
rust: reject certificate registration on stopped runners
2026-10-26 00:51:27 -04:00
Adrien Beraud
42e4419b75
bindings: verify retained values and queued push delivery
2026-10-26 00:51:27 -04:00
Adrien Beraud
4e94d123b2
rust: cover threaded crypto and native callback teardown
2026-10-26 00:51:27 -04:00
Adrien Beraud
7f3f1b4ec4
rust: cover filtered queries and extension hooks
2026-10-26 00:51:27 -04:00
Adrien Beraud
6d462c0dbf
rust: cover callback ownership and binding error paths
2026-10-26 00:51:27 -04:00
Adrien Beraud
0285acc766
c: cover lifecycle progress and crypto persistence APIs
2026-10-26 00:51:27 -04:00
Adrien Beraud
0626e82f4a
c: contain crypto generation failures and run binding regressions
2026-10-26 00:51:27 -04:00
Adrien Beraud
aa01f68cb5
c: cover binding ownership and invalid crypto input
2026-10-26 00:51:27 -04:00
Adrien Beraud
af3fd618bf
python: expose observability and projected query APIs
2026-10-26 00:51:27 -04:00
Adrien Beraud
b96bdfbf04
python: cover observability and querying APIs
2026-10-26 00:51:27 -04:00
Adrien Beraud
60ca85f782
python: release native resources and guard callback cleanup
2026-10-26 00:51:27 -04:00
Adrien Beraud
e4966aa457
python: cover native resource and callback cleanup regressions
2026-10-26 00:51:27 -04:00
Adrien Beraud
aa9d23870b
python: guard native errors, iterator lifetimes, and hash bounds
2026-10-26 00:51:27 -04:00
Adrien Beraud
ac68db84eb
python: cover binding exception and memory safety regressions
2026-10-26 00:51:27 -04:00
Adrien Beraud
bbbd9122af
python: use loopback addresses in bootstrap test
2026-10-26 00:51:27 -04:00
Adrien Beraud
cf58d66282
python: expose node state persistence configuration
2026-10-26 00:51:27 -04:00
Adrien Beraud
2ddf1e5ec5
python: await shutdown before checking persisted state
2026-10-26 00:51:27 -04:00
Adrien Beraud
e48bfd578a
python: cover node state persistence configuration
2026-10-26 00:51:27 -04:00
Adrien Beraud
1c3fc22c31
meson: install Python bindings as opendht package
2026-10-26 00:51:27 -04:00
Adrien Beraud
b6cf2fd246
python: expose key persistence and value metadata
2026-10-26 00:51:27 -04:00
Adrien Beraud
91c3f62c0c
python: validate restored keys through certificate chains
2026-10-26 00:51:27 -04:00
Adrien Beraud
2703cf129d
python: cover key persistence and value metadata
2026-10-26 00:51:27 -04:00
Adrien Beraud
51c2aadd4e
python: handle cancelled and repeated async completions
2026-10-26 00:51:27 -04:00
Adrien Beraud
8b20e912d6
docker: use alpine 3.24 runtime
2026-10-26 00:51:27 -04:00
Adrien Beraud
b66ff83fe2
python: preserve permanence in blocking puts
2026-10-26 00:51:27 -04:00
Adrien Beraud
552813e1b9
python: cover permanence forwarding and async cancellation
2026-10-26 00:51:27 -04:00
Adrien Beraud
601a8fbf80
python: release GIL while joining and destroying runners
2026-10-26 00:51:27 -04:00
Adrien Beraud
26488d18a6
python: translate crypto errors and guard empty objects
2026-10-26 00:51:27 -04:00
Adrien Beraud
53c509c54f
python: cover crypto errors and GIL-safe teardown
2026-10-26 00:51:27 -04:00
Adrien Beraud
def6a28d96
python: fix listener ownership and isolate run config
2026-10-26 00:51:27 -04:00
Adrien Beraud
dbd5953b17
python: cover listener lifetime and config isolation
2026-10-26 00:51:27 -04:00
Cyrille Béraud and Copilot
2893823a77
securedht: forward push platform and topic
...
SecureDht only forwarded the push token to the DHT it wraps, so the
push platform and topic given to DhtRunner after the proxy client was
created never reached it. A device started without push platform
(e.g. a Jami account created by a build without push support) then
subscribed with an empty platform once given a token, and the proxy
server pushed it as an iOS device.
Co-authored-by: Copilot (Claude Opus 5.5) <223556219+Copilot@users.noreply.github.com >
2026-10-26 02:55:59 +00:00
Cyrille Béraud and Copilot
3ec03ccc0b
proxy_server: keep push platform up to date
...
The DHT listen callback of a push subscription kept the push type and
topic of the request that created it. Refreshing the subscription
with another platform updated the listener, but values kept being
pushed to the first platform: an Android device that once subscribed
without platform was pushed as an iOS device forever (BadDeviceToken)
and never received values such as connection requests.
Keep the push type and topic in the session context shared with the
callback, and update them on each subscription refresh and when the
state is restored.
Co-authored-by: Copilot (Claude Opus 5.5) <223556219+Copilot@users.noreply.github.com >
2026-10-26 02:55:59 +00:00
Cyrille Béraud and Copilot
20fa751da0
tests: check push platform of proxy notifications
...
Move the fake push gateway of the full chain test into a reusable
helper, and add two tests showing that the proxy server pushes to the
wrong platform:
- when a device refreshes its subscription with another platform,
new values keep being pushed with the platform of the first
subscription;
- a platform set after the proxy client started is not used by its
subscriptions.
Co-authored-by: Copilot (Claude Opus 5.5) <223556219+Copilot@users.noreply.github.com >
2026-10-26 02:55:59 +00:00
Adrien Beraud
0d572f0dab
build: update supported Python versions
...
Drop Python 3.9 and 3.10 and add support for Python 3.15.
2026-10-25 18:16:26 -04:00
Adrien Beraud
d9c401e1e2
docker: migrate to 26.04 for main LLVM image
2026-10-25 12:42:20 -04:00
Adrien Beraud
dbdbe65a5d
docker: fix local build context and missing dependencies
2026-10-25 12:39:30 -04:00
Adrien Beraud
6f5bec3af6
update version to 4.4.2
2026-10-25 12:11:46 -04:00
Adrien Beraud
d07a9e6583
ci: update cibuildwheel to v4.3.4
2026-10-25 12:06:54 -04:00
Adrien Beraud
fd43a329e7
deps: update RESTinio to 0.7.10 across Docker and CI
2026-10-25 11:58:53 -04:00
Adrien Beraud
93b2e8d5b9
ci: migrate vcpkg setup and binary caching
2026-10-25 13:46:35 +00:00
Adrien Beraud
d66713d97e
build: update vcpkg to 2026.10.16
2026-10-25 13:46:35 +00:00
Adrien Beraud
7af9868c47
docker: update to Alpine 3.24, Ubuntu 26.04
2026-10-24 23:25:08 -04:00
Adrien Beraud
05a524b038
docker: update RESTinio to 0.7.10
2026-10-24 23:25:08 -04:00
Adrien Beraud
57ed00579e
pht: preserve prefix padding encoding
2026-10-25 03:03:35 +00:00
Adrien Beraud
9ffccb3956
pht: test prefix padding compatibility
2026-10-25 03:03:35 +00:00
Cyrille Béraud and Copilot
d99324ebd4
pht: fix the bit arithmetic of Prefix
...
Prefix::size_ counts bits, but commonBits walked content_ a byte at a
time up to it. Two prefixes that agree on their whole common length are
therefore read well past their end, which AddressSanitizer reports as a
heap-buffer-overflow, and the count that comes back is eight times too
large. A lookup with a common prefix length hits this as soon as an
index entry matches the key it is looking for, and entry.prefix comes
straight off the network. The flags were indexed the same way, so a
partially known prefix was read at the wrong position too.
swapBit had the other half of the confusion: it flipped bit
(8 - bit) % 8 of the byte, while isActiveBit reads bit 7 - (bit % 8).
getSibling, which flips the last bit of a prefix to name the sibling
node in the trie, therefore returned a prefix differing in some other
bit and sharing the last one, so lookup and insertion looked up the
wrong node. Splitting a leaf and finding a canary both rely on it.
Add tests covering both, which fail before the fix: commonBits returns
193 for two identical 160 bit prefixes, and a prefix and its sibling
share 7 bits rather than all but the last.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-10-25 03:03:35 +00:00
copilot-swe-agent[bot] and aberaud
933f6cbca1
dhtcluster: import netifaces for interface selection
...
Co-authored-by: aberaud <101827+aberaud@users.noreply.github.com >
2026-10-25 02:45:22 +00:00
copilot-swe-agent[bot] and aberaud
d5d7d6483f
test: cover dhtcluster interface address selection
...
Co-authored-by: aberaud <101827+aberaud@users.noreply.github.com >
2026-10-25 02:45:22 +00:00
dependabot[bot]
cc09a39ade
build(deps): bump pypa/cibuildwheel from 4.1.1 to 4.3.1
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 4.1.1 to 4.3.1.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v4.1.1...v4.3.1 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 4.3.1
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-10-25 02:44:52 +00:00
Adrien Beraud
621b44c8e8
Revert "disable windows wheel for now"
...
This reverts commit fc6edb4d20 .
2026-09-23 14:42:57 -04:00
Adrien Beraud
e1c088f2e4
build: bump version to 4.4.1
2026-09-23 14:38:36 -04:00
Adrien Beraud
a6e0e441ac
crypto: use standard unsigned int* for gnutls_ocsp_resp_get_single
2026-09-22 11:31:45 -04:00
Adrien Beraud
dcc2ba3492
crypto: use gnutls_ocsp_cert_status_t* in gnutls_ocsp_resp_get_single
2026-09-22 11:31:45 -04:00
Adrien Beraud
ccf00d6b09
ports: update shiftmedia-libgnutls to f76d780a6
2026-09-22 11:31:45 -04:00
Adrien Beraud
d8250574fc
ports: use ForcedIncludeFiles for gnutls_msvc_fixes.h in shiftmedia-libgnutls
2026-09-22 11:31:45 -04:00
Adrien Beraud
0d698c76e8
ports: update shiftmedia-libgnutls to 9ebeb826d
2026-09-22 11:31:45 -04:00
Adrien Beraud
e4e3b4e73b
ports: set LanguageStandard_C to stdc11 in shiftmedia-libgnutls
2026-09-22 11:31:45 -04:00
Adrien Beraud
b26d622f5d
ports: update shiftmedia-libgnutls to 37840cfa5
2026-09-22 11:31:45 -04:00
Adrien Beraud
78694751bd
ports: update shiftmedia-libgnutls to 4ab78d57e
2026-09-22 11:31:45 -04:00
Adrien Beraud
f9b90c5c1c
ports: update shiftmedia-libgnutls to 5a5a9dd95
2026-09-22 11:31:45 -04:00
Adrien Beraud
56b848bf47
ports: fix savoirfairelinux/gnutls commit hash and SHA512 in shiftmedia-libgnutls
2026-09-22 11:31:45 -04:00
Adrien Beraud
dd875230c3
ports: update shiftmedia-libgnutls to 90eb686e8
2026-09-22 11:31:45 -04:00
Adrien Beraud
de1d428e63
ports: use gitlab gnulib mirror archive in shiftmedia-libgnutls
2026-09-22 11:31:45 -04:00
Adrien Beraud
55e3a6514f
ports: fix gnulib snapshot SHA512 hash in shiftmedia-libgnutls
2026-09-22 11:31:45 -04:00
Adrien Beraud
f4bbef210c
ports: fix savoirfairelinux/gnutls archive SHA512 hash in shiftmedia-libgnutls
2026-09-22 11:31:45 -04:00
Adrien Beraud
2c1470cef6
vcpkg: add overlay port for savoirfairelinux/gnutls on Windows MSVC
2026-09-22 11:31:45 -04:00
Adrien Beraud
adb6aa57e6
update vcpkg
2026-09-22 11:31:45 -04:00
Adrien Beraud
acd0abdb70
ci: fix vcpkg cache keys across workflows and remove manual version string
2026-09-22 11:31:45 -04:00
Cyrille Béraud and Copilot
b9c8f5e0fd
runner: complete pushes received while stopped
...
Resolve idle-runner push futures immediately under the operation queue lock. A stopped runner has no loop left to execute the queued promise, otherwise consumers can wait indefinitely.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-09-21 16:02:47 -04:00
Cyrille Béraud and Copilot
18fedf431f
tests: cover pushes received by stopped runners
...
Require immediate completion before run and after join, including a burst of notifications. Keep active-runner coverage.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-09-21 16:02:47 -04:00
Adrien Beraud
fc6edb4d20
disable windows wheel for now
2026-09-19 22:09:44 -04:00
Adrien Beraud
d1093c77a3
ci: use libmsgpack-cxx-dev on Debian 13
2026-09-19 21:56:06 -04:00
Adrien Beraud
b543f1e3cb
update vcpkg to 2026.06.01
2026-09-19 21:10:44 -04:00
Adrien Beraud
be210e27da
update version to 4.4.0
2026-09-04 16:46:41 -04:00
Adrien Beraud
f7243fca37
value_cache: only emit an edition when the content actually changed
...
ValueCache re-emitted a known value as an edition on a higher seq alone,
while OpValueCache requires the content to differ as well. Since
Value::operator== ignores seq, identical content re-announced with a
bumped seq was re-emitted as an add: a source-counting OpValueCache
then counted the same node twice and kept the value after the node
expired or left the search. Apply the same rule at both levels.
2026-09-04 15:44:35 -04:00
Adrien Beraud
1f6efd5736
tests: cover same-content higher-seq re-announce in ValueCache
...
Value::operator== ignores seq, so a node re-announcing identical content
with a bumped seq is the same value refreshed, not an edition. ValueCache
must not re-emit it: a source-counting OpValueCache above would count the
node twice and keep the value after the node is gone.
2026-09-04 15:44:35 -04:00
Adrien Beraud
54fbad3a7e
op_cache: ignore expiry of versions that were never counted
...
onValuesAdded ignores a different payload that does not carry a higher
seq (e.g. the same signed content re-signed with a randomized
signature), but onValuesExpired only skipped strictly older versions.
The uncounted source could therefore decrement the refcount and expire
a value still held by others. Apply the same rule on both sides.
2026-09-04 15:18:35 -04:00
Adrien Beraud
1315489a7b
tests: cover expiry of an uncounted same-seq version in OpValueCache
...
A source reporting a different payload with the same seq is ignored on
add and not counted; its later expiration must not release the value
still held by the counted sources.
2026-09-04 15:18:35 -04:00
Adrien Beraud
c189fa0e82
proxy_server: detach pending push requests before destruction
...
~DhtProxyServer destroyed requests_ whose ~http::Request notifies DONE;
the handler registered by sendPushNotification then erased from the map
being destroyed, corrupting the heap (double free under ASan) whenever a
push request was still pending, e.g. an unreachable push server. Detach
the state-change callbacks and release the requests before the members
are destroyed.
2026-09-04 15:18:24 -04:00
Adrien Beraud
3eae03289e
storage: re-storing identical content is a refresh, not an edition
...
Storage::store reported edited_values=1 whenever the stored Sp<Value>
differed from the incoming one, even with equal content. A local put()
of an already-stored value was therefore announced to local listeners
as a new value a second time, unbalancing listen caches that count how
many sources hold a value. Only report an edition when the content
actually changed; the expiration is still refreshed.
2026-09-04 15:18:24 -04:00
Adrien Béraud
e5e5a45b91
op_cache, proxy_client: guard SearchCache::get and push refresh expiry
...
SearchCache::get called the GetCallback unconditionally; Dht::query
passes none, which threw bad_function_call as soon as a listen cache
existed for the key. Return false without a callback so the network
path runs. A callback returning false means the consumer has enough
values, not a failure: report done(true) as the network path does.
DhtProxyClient push refresh expired every previously cached value once
the refresh get completed, including values that were just re-delivered
or edited, producing phantom expire callbacks. Track the ids received by
the get and only expire cached values missing from it, and skip the
reconciliation when the get failed so a transient error does not expire
values still present on the DHT.
2026-09-04 15:18:24 -04:00
Adrien Beraud
7a71beb892
value_cache: detect editions by increasing seq, like OpValueCache
...
ValueCache emitted any content change of a known value as an edition
while OpValueCache only accepts a higher seq. A node reporting an older
version made ValueCache replace its copy and re-emit versions that were
then dropped or, with source counting, double counted downstream. Use
the same rule at both levels.
2026-09-04 15:18:24 -04:00
Adrien Béraud
74a894229f
value_cache, op_cache: fix value accounting after edition and re-delivery
...
OpValueCache counted every re-delivery of an identical value as a new
source, but the proxy client is a single logical source that re-sends
values on push refresh or listen restart: the refcount grew unbounded
and expirations were never propagated. Add a countSources flag to
OpValueCache, OpCache and SearchCache; the proxy client disables it.
When a value is edited (same id, higher seq), only the reporting source
is known to hold the new version: replace it in place, reset the
refcount to 1 and emit a single add. Ignore older versions from lagging
sources on add, and ignore their expiration so they cannot release a
newer version still held by others.
ValueCache emits an edited value as an add instead of silently
refreshing its old copy, and applies a grace period of one type
expiration while the listen is synced so that a single lost refresh
notification does not drop a value the remote node still holds.
SearchCache::get only answers from the cache once the listen is synced,
so a get never returns a partial view that the network would complete.
Add the single-source OpCacheTester cases enabled by countSources.
2026-09-04 15:18:13 -04:00
Adrien Beraud
c81c1f70c8
tests: add listen cache tests for OpValueCache, ValueCache, DhtRunner and proxy
...
OpCacheTester and ValueCacheTester exercise the listen caches in
isolation: add/edit/expire flows, per-source refcounting, stale
versions, sync status, SearchCache::get and node drop.
DhtRunnerTester and DhtProxyTester gain end-to-end listen tests for
value edition, duplicate puts, multi-source and partial expiration,
get after a synced listen, and the push refresh/expire paths.
The proxy fixture joins the proxy DhtRunner before destroying the
DhtProxyServer so no DHT callback can reach a destroyed server, and
push notifications are never awaited while holding the mutex taken by
listen callbacks: the result is produced on the DHT thread.
Register the new executables in CMake and Meson.
2026-09-04 15:17:34 -04:00
Adrien Beraud and Copilot
3a383ac873
http: close connections on the io_context thread
...
asio sockets are not thread-safe. http::Connection::close() used to close
the socket synchronously on the calling thread. Request::cancel() and
Request::~Request() (via terminate()) are called from arbitrary threads
(e.g. DhtProxyClient::stop(), cancelAllListeners(), cancelListen()),
so the close raced with in-flight operations on the io_context thread.
In particular, asio::async_connect's range_connect_op closes and
re-opens the socket when trying the next endpoint (common on mobile
where the IPv6 endpoint fails first). A concurrent close() from another
thread corrupts the epoll reactor's per-descriptor state, leading to
crashes in epoll_reactor::deregister_descriptor / register_descriptor
called from range_connect_op::process.
Dispatch the close to the io_context thread when not already on it.
Also keep the connection alive during the TLS handshake, like every
other asynchronous operation, so that the destructor can never run
while an operation is pending.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-09-04 14:13:20 -04:00
Adrien Beraud
3149fe60c4
proxy: increase OP_MARGIN to 8 hours
2026-09-04 11:04:42 -04:00
Adrien Beraud
d5956e0778
proxy: use system_clock for subscriber expiration timeouts
...
Track subscribe/permanent-put expiration with std::chrono::system_clock
(wall clock) instead of steady_clock in both the proxy client and server,
so persisted expirations survive restarts and map directly to epoch time.
- DhtProxyServer::clock is now system_clock; expireTimer/expireNotifyTimer
use asio::system_timer.
- DhtProxyClient::refreshSubscriberTimer uses asio::system_timer and
system_clock::now() for subscriber refresh.
2026-09-04 11:04:42 -04:00
Adrien Beraud
8baf53d078
utils: fix clock conversion overflow with mismatched durations
...
to_system_time computed its saturation bounds by subtracting a
steady_clock duration from system_clock::time_point::max(). When the
two clocks have different periods (microseconds for system_clock and
nanoseconds for steady_clock on libc++), the common type promotes the
bound to nanoseconds and overflows, so every future time point was
converted to system_clock::time_point::max().
Cast the delta to the target duration before comparing against the
bounds, and saturate from_system_time before the reverse cast for
symmetry.
2026-09-01 22:56:16 -04:00
Adrien Beraud
82ab21dc3f
crypto: support explicit EC curve generation
2026-09-01 21:34:36 -04:00
Adrien Beraud
d676aef027
http: support legacy X509 lookup signature
2026-08-06 14:05:48 -04:00
Adrien Beraud
a2d9fdf334
Recompute runner wakeup after import schedules value expirations.
2026-08-06 13:59:48 -04:00
Adrien Beraud
0cec4135c0
update to 4.3.0
2026-08-05 16:35:01 -04:00
Adrien Beraud
6f76686a3e
ci: update to Debian 13
2026-08-05 16:19:46 -04:00
Adrien Beraud
c211b3c376
dht: persist values with system time
2026-08-05 16:14:15 -04:00
Adrien Beraud
0179b6ecc7
test: cover system time state persistence
2026-08-05 16:14:15 -04:00
Adrien Beraud
44e1ad839e
net: harden fragmented reply completion
2026-08-05 14:29:03 -04:00
Adrien Beraud
dddd97daff
tests: cover partial reply hardening
2026-08-05 14:29:03 -04:00
Adrien Beraud
632bec459e
net: avoid partial key allocation for regular messages
2026-08-05 14:29:03 -04:00
Cyrille Béraud and Copilot
910ca10a5f
net: reject malformed error and request fields
...
An error array was read at index 0 without checking its size, so a packet
carrying "e":[] dereferenced a null element pointer and crashed the process
on unauthenticated UDP input.
When a message had an error array but no "a", "r" or "u" map, the same object
was then walked through the map view of the msgpack union. A two-element array
appeared to hold two key/value pairs, reading past its allocation. A request
field that was not a map was never type-checked either.
Validate the error array size, restrict request parsing to "a", "r" and "u",
and require those to be maps. Add parser regressions for the empty error
array, the error-only message and the non-map request; the first one
segfaults without this change.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-08-05 14:29:03 -04:00
Cyrille Béraud and Copilot
0826822a4d
net: harden fragmented message reassembly
...
Key partial messages by source and transaction ID, buffer bounded fragments received before their header, and avoid charging reordered requests twice against rate limits. Cover source collisions, early fragments, empty data and large values.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-08-05 14:29:03 -04:00
Cyrille Béraud and Copilot
8aa6b009c3
net: reject empty field selections
...
Reject field-compressed responses with no selected fields before computing the value count, avoiding a division by zero on malformed network input. Add a parser regression test.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-08-05 14:29:03 -04:00
Cyrille Béraud and Copilot
2caa21d65f
dht: let a node that lost the network try to rejoin it
...
Dht::onDisconnected() only starts a bootstrap when bootstrapJob is
unset, reading a set handle as "a bootstrap is already scheduled".
That reading is wrong: Scheduler::run() erases the job from its timers
and calls it, but never clears the shared handle the caller holds, and
Scheduler::cancel() leaves the handle alone too when the job is no
longer in the timers. The handle therefore stays set for as long as the
Dht lives, once a bootstrap job has run.
That is harmless while bootstrap() reschedules itself, which it does as
long as the node is disconnected. It is not harmless on the early
return: a job that fires while a ping is still in flight, or while a
dubious contact keeps the status at Connecting, returns without
rescheduling. From then on the chain is dead and onDisconnected() will
not restart it, so a node that goes on to lose every contact stays
disconnected for good. Only an explicit addBootstrap() or a
connectivityChanged() can revive it, and a node whose network simply
went away gets neither.
Clearing the handle on the early return restores the meaning
onDisconnected() relies on.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-08-03 11:34:25 -04:00
Adrien Beraud
cf64fa454c
crypto: encode certificate serials in network order
2026-08-02 17:24:55 -04:00
Adrien Beraud
ef9ef12195
tests: cover positive certificate serials
2026-08-02 17:24:55 -04:00
Cyrille Béraud and Copilot
74a1918a4d
crypto: strip the terminating null byte from an exported public key
...
gnutls_pubkey_export reports the size of the exported PEM including its
terminating null byte, and PublicKey::toString hands that size straight
back to the caller. The returned string therefore ends with a null byte
that is not part of the PEM text.
Certificate::toString does not have the problem because
gnutls_x509_crt_export excludes the terminator, so the two exports
disagree on what a PEM string is.
The stray byte travels: Value::toJson stores owner->toString() in the
"owner" field, so a value published through the proxy carries a null
byte inside a JSON string, which is valid JSON but a surprise for any
consumer that treats the field as text.
Resize to the reported size and drop the terminator when it is there.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-08-02 17:20:04 -04:00
dependabot[bot]
56a60fb557
build(deps): bump pypa/cibuildwheel from 4.1.0 to 4.1.1
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 4.1.0 to 4.1.1.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v4.1.0...v4.1.1 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 4.1.1
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-07-30 10:17:04 -04:00
Adrien Beraud
f98df1d615
crypto: allow signing a revocation list with an explicit CRL number
...
RevocationList::sign() always overwrote the CRL Number extension: random
on the first signature, incremented afterwards. This leaves no way for a
certificate authority replicated over several devices to keep numbers
unique, since every device branching from the same list mints the same
number for a different content.
Add an optional `number` parameter, used verbatim when non-zero, so
callers can partition the number space (RFC 5280 5.2.3 requires
monotonicity for a given CRL scope and issuer, not globally).
Also fix the default increment path: the extension holds a DER integer
with leading zeros stripped, so reading it straight into an uint64_t only
worked for numbers wide enough to occupy all 8 bytes. Signing a list
numbered 5 produced 0x0500000000000001 instead of 6. Read and write the
number as a big-endian byte string instead, which makes the `endian()`
helper unnecessary.
Add tests covering the default numbering, explicit numbers (including
values with leading zero bytes and the largest positive 8-byte integer),
pack/unpack round-trips, and a device-partitioned numbering scheme.
2026-07-29 13:26:23 -04:00
Adrien Beraud
8f779f2efb
http: fix build on OpenSSL 4.0
2026-07-20 11:25:02 -04:00
Adrien Beraud
699073acd8
update version to 4.2.0
2026-07-17 14:09:54 -04:00
Cyrille
02d49b9f6a
http: run completed resolver callbacks on io executor
2026-07-15 14:07:14 -04:00
Adrien Beraud
85b0bc52c8
test: reproduce completed resolver callback race
2026-07-15 14:07:14 -04:00
Adrien Beraud
af02c3a117
ci: install brew packages for macOS 15
2026-07-15 12:16:28 -04:00
François-Simon Fauteux-Chapleau
74b99453ce
op_cache: fix boundary condition
...
In SearchCache::expire, if there is an op whose expiration is equal to
`now`, then it's not processed and the function returns `now` as the
next expiration timepoint. This can lead to the opExpirationJob in
Search::cancelListen getting rescheduled at the same time in an infinite
loop.
2026-07-13 14:38:27 -04:00
Adrien Beraud
cba3d0e18f
update version to 4.1.1
2026-07-06 15:50:00 -04:00
Adrien Beraud
f9332985f5
thread_pool: only include ciso646 on C++<20
2026-07-06 15:45:01 -04:00
Cyrille Béraud and Copilot
513d0eb803
dhtrunner: fall back to random port when saved port is taken
...
Since 15eb221c the node's bound port is persisted alongside the DHT
state and reused on the next run for a stable identity. If that port
is still held by another process - typically a fast application
restart racing the previous instance's shutdown - UdpSocket
constructor throws (both the IPv4 and IPv6 binds fail) and
DhtRunner::run() propagates the exception: the node never starts.
In Jami this left every account stuck in the connecting state after a
quick restart, with 'DhtException occurred: Can't bind socket' logged
per account, and no retry.
The persisted port is only a best-effort hint: when binding it fails,
retry with OS-assigned ports instead of throwing. The persisted file
is then refreshed with the newly bound ports as before.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-07-06 15:44:47 -04:00
Cyrille Béraud and Copilot
139852a531
tests: dhtrunner: cover saved-port fallback
...
Cover starting a node whose persisted port (persist_path + "_port.txt")
is already bound by another node, as happens when an application is
restarted while the previous instance still holds the socket. The node
is expected to start on a fallback port instead of failing.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-07-06 15:44:47 -04:00
Cyrille Béraud and Copilot
3a73ad3aca
value: serialize pushType in JSON
...
The pushType field (593e59e0 ) lets the DHT proxy server tag push
notifications with the connection type ("pt" in the FCM payload), so
mobile clients can tell incoming calls apart from background noise.
It was only serialized in msgpack. Clients using DhtProxyClient
send their puts as JSON (Value::toJson()), where the field was
silently dropped, and the proxy server parsed the incoming JSON with
Value(const Json::Value&), which never read it back. As a result any
value put through a proxy (e.g. a call request from a mobile device)
reached the recipient's device with an empty "pt", was classified as
noise, and did not wake up the callee: calls from proxied devices
never rang, while the same call from a full DHT node (desktop) did.
Serialize pushType as "pt" in Value::toJson() when set, and parse it
back in the JSON constructor, mirroring the msgpack behavior.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-07-04 11:57:49 -04:00
Cyrille Béraud and Copilot
9031cf06c4
tests: value: add pushType JSON round-trip test
...
Cover Value::toJson() / Value(const Json::Value&) preservation of the
pushType field, and its absence from the JSON when empty. This is the
serialization path used by DhtProxyClient::put(), so mobile clients
behind a DHT proxy depend on it to propagate the push notification
type.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-07-04 11:57:49 -04:00
dependabot[bot]
7b1369931e
build(deps): bump actions/cache from 5 to 6
...
Bumps [actions/cache](https://github.com/actions/cache ) from 5 to 6.
- [Release notes](https://github.com/actions/cache/releases )
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md )
- [Commits](https://github.com/actions/cache/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: actions/cache
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-06-29 19:15:42 -04:00
dependabot[bot]
64364602d7
build(deps): bump pypa/cibuildwheel from 3.4.1 to 4.1.0
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.4.1 to 4.1.0.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.4.1...v4.1.0 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 4.1.0
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-06-22 10:56:34 -04:00
dependabot[bot]
2dbec3df97
build(deps): bump actions/checkout from 6 to 7
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 6 to 7.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v6...v7 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: '7'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-06-22 10:53:41 -04:00
Adrien Beraud
507e2de3c4
update version to 4.1.0
2026-06-19 00:27:25 -04:00
dependabot[bot]
c37abed715
build(deps): bump https://github.com/microsoft/vcpkg
...
Bumps [https://github.com/microsoft/vcpkg ](https://github.com/microsoft/vcpkg ) from HEAD to 2026.06.01. This release includes the previously tagged commit.
- [Release notes](https://github.com/microsoft/vcpkg/releases )
- [Commits](https://github.com/microsoft/vcpkg/compare/66c0373dc7fca549e5803087b9487edfe3aca0a1...f3e10653cc27d62a37a3763cd84b38bca07c6075 )
---
updated-dependencies:
- dependency-name: https://github.com/microsoft/vcpkg
dependency-version: 2026.06.01
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-06-19 00:12:50 -04:00
Adrien Beraud
0eb1c33ba5
ci: update vcpkg
2026-06-19 00:10:28 -04:00
Adrien Beraud
45918186a2
ci: update vcpkg
2026-06-19 00:08:20 -04:00
Adrien Beraud
29cb909228
build/meson: base64 requires simdutf
2026-06-18 23:52:24 -04:00
Adrien Beraud
9f6a03bf3d
build/meson: require appropriate dependencies for proxy server
2026-06-18 20:34:45 -04:00
Adrien Beraud
732da0e478
default types: add ValueId to TrustRequest
2026-06-11 16:52:03 -04:00
Adrien Béraud
9a60329f66
proxy server: use token as request url
2026-06-03 20:00:34 -04:00
Adrien Béraud
0bb393ec36
http: allow to build Request by std::string url
2026-06-03 19:30:53 -04:00
vx32
947610003b
http: allow to build Url from std::string, cleanup
2026-06-03 19:14:32 -04:00
Adrien Béraud
dcbe158554
proxy server: allow url-encoded base64 for UnifiedPush
2026-06-03 19:12:40 -04:00
vx32
38e9a7fd61
base64: add support for url-encoded base64
2026-06-03 17:01:19 -04:00
François-Simon Fauteux-Chapleau
7cf3e8b738
thread_pool: notify when task queue becomes empty
...
This prevents ThreadPool::stop from hanging if it is called with `wait`
set to true (which is notably the case in ThreadPool::join) and the
pool's task queue is non-empty.
2026-05-21 10:17:08 -04:00
François-Simon Fauteux-Chapleau
e924ef5620
tests: add regression test for hang in thread pool
...
The worker threads in a ThreadPool don't signal the pool's condition
variable when completing the last task in the queue. As a consequence,
ThreadPool::join() hangs if called while the task queue is non-empty.
2026-05-21 10:17:08 -04:00
Adrien Béraud
d96115b445
docs: update manpage for dhtnode
2026-05-18 10:50:23 -04:00
Adrien Béraud
bb96d2d80e
dhtchat: adapt for new API
2026-05-18 10:36:48 -04:00
Adrien Béraud
8b96652b32
dhtrunner: add signatures for putEncrypted(InfoHash, PkId to, Value&&)
2026-05-18 10:36:48 -04:00
Adrien Béraud
d1235660d5
crypto: add support to build with Nettle 4.0
2026-05-13 14:36:13 -04:00
Adrien Béraud
23c6b5547b
python: update for API changes in 4.0
2026-05-13 14:18:08 -04:00
Adrien Béraud
61c4a3880f
update version to 4.0.0
2026-05-11 09:28:57 -04:00
Adrien Béraud
44f2aaa876
remove deprecated APIs
2026-05-11 09:27:56 -04:00
Adrien Béraud
a363d573e3
dht: fix persisted permanent values never expiring
...
When values are exported and re-imported, permanent values retain their
time_point::max() expiration but lose their permanent flag. This caused
them to be stored as non-permanent with an effectively infinite
expiration, so they would never expire.
Cap the expiration of non-permanent values to created + type.expiration,
ensuring that imported permanent values get a finite expiration matching
their value type.
2026-05-09 00:39:49 -04:00
Adrien Béraud
3ff9338980
tests: add test for permanent value import expiration
...
Add testImportPermanentValueExpires to verify that values originally
stored as permanent (with time_point::max() expiration) properly expire
after being exported and re-imported, since the permanent flag is lost
during the import process.
2026-05-09 00:39:49 -04:00
Adrien Béraud
ea3c0f0d93
update version to 3.7.9
2026-05-02 20:40:25 -04:00
Adrien Béraud
f0cf074576
BUILD.md: add llhttp dependency and remove CMAKE_INSTALL_PREFIX
2026-05-02 19:08:02 -04:00
Adrien Béraud
760586ed4a
python: build for python 3.14
2026-05-02 19:06:25 -04:00
dependabot[bot]
b951f4f40a
build(deps): bump softprops/action-gh-release from 2 to 3
...
Bumps [softprops/action-gh-release](https://github.com/softprops/action-gh-release ) from 2 to 3.
- [Release notes](https://github.com/softprops/action-gh-release/releases )
- [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md )
- [Commits](https://github.com/softprops/action-gh-release/compare/v2...v3 )
---
updated-dependencies:
- dependency-name: softprops/action-gh-release
dependency-version: '3'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-04-18 13:55:23 +10:00
dependabot[bot]
63cc650a72
build(deps): bump pypa/cibuildwheel from 3.4.0 to 3.4.1
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.4.0 to 3.4.1.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.4.0...v3.4.1 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 3.4.1
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-04-18 13:54:34 +10:00
Adrien Béraud
c020d2e1ef
update version to 3.7.8
2026-04-02 16:37:17 -04:00
copilot-swe-agent[bot] and aberaud
aae1bb2ae5
infohash: fix unaligned memory access on strict-alignment architectures (sparc64)
...
Agent-Logs-Url: https://github.com/savoirfairelinux/opendht/sessions/d4106989-db2c-4d34-b1ea-4ca2ecab524a
Co-authored-by: aberaud <101827+aberaud@users.noreply.github.com >
2026-04-02 16:08:33 -04:00
Pavan Koushik Nellore
593e59e093
proxy: add pushType field and propagate through proxy notifications
2026-04-02 15:03:11 -04:00
dependabot[bot]
86d5065aca
build(deps): bump microsoft/setup-msbuild from 2 to 3
...
Bumps [microsoft/setup-msbuild](https://github.com/microsoft/setup-msbuild ) from 2 to 3.
- [Release notes](https://github.com/microsoft/setup-msbuild/releases )
- [Commits](https://github.com/microsoft/setup-msbuild/compare/v2...v3 )
---
updated-dependencies:
- dependency-name: microsoft/setup-msbuild
dependency-version: '3'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-25 16:25:14 -04:00
dependabot[bot]
308d8ff82b
build(deps): bump actions/upload-artifact from 6 to 7
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 6 to 7.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](https://github.com/actions/upload-artifact/compare/v6...v7 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-version: '7'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-19 18:32:26 -04:00
dependabot[bot]
34b9ddd023
build(deps): bump docker/build-push-action from 6 to 7
...
Bumps [docker/build-push-action](https://github.com/docker/build-push-action ) from 6 to 7.
- [Release notes](https://github.com/docker/build-push-action/releases )
- [Commits](https://github.com/docker/build-push-action/compare/v6...v7 )
---
updated-dependencies:
- dependency-name: docker/build-push-action
dependency-version: '7'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-19 18:32:04 -04:00
dependabot[bot]
88cb14ad95
build(deps): bump actions/download-artifact from 7 to 8
...
Bumps [actions/download-artifact](https://github.com/actions/download-artifact ) from 7 to 8.
- [Release notes](https://github.com/actions/download-artifact/releases )
- [Commits](https://github.com/actions/download-artifact/compare/v7...v8 )
---
updated-dependencies:
- dependency-name: actions/download-artifact
dependency-version: '8'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-19 18:31:48 -04:00
Adrien Béraud
e453a47242
update version to 3.7.7
2026-03-16 11:05:38 -04:00
Adrien Béraud
199090b959
network engine: log exceptions
2026-03-15 19:42:09 -04:00
Adrien Béraud
d250e6a349
dhtrunner: cleanup
2026-03-15 10:43:46 -04:00
Adrien Béraud
99da0be2b7
misc: remove lock mutex template argument
2026-03-15 00:00:33 -04:00
Adrien Béraud
22d219c695
dht: close socket on auth error
2026-03-14 18:19:06 -04:00
Adrien Béraud
ccd4865df5
dht: allow search table update with listen token refresh
2026-03-14 16:17:32 -04:00
Adrien Beraud
5afc452f32
build/cmake: set SIMDUTF_CXX_STANDARD to match CMAKE_CXX_STANDARD
2026-03-14 11:37:53 -04:00
Adrien Beraud
a06596d365
tests: unlock mutex before join
2026-03-14 11:37:50 -04:00
Adrien Béraud
aa260c7b40
tests: add testShutdownCompletesWithPendingPut
2026-03-14 11:37:43 -04:00
Adrien Béraud
7183847e44
tests: use random ports
2026-03-13 22:59:41 -04:00
Adrien Béraud
884cb09220
tests: bound dhtrunner async waits
2026-03-13 22:00:09 -04:00
Adrien Béraud
04edaafa57
dht: simplify bootstrap logic
2026-03-13 20:59:24 -04:00
Adrien Béraud
6be58884aa
tests: set timout for test_crypto to 60s
2026-03-13 20:58:53 -04:00
Adrien Béraud
d50d3d4f32
tests: set timout for test_dhtrunner to 60s
2026-03-13 20:52:56 -04:00
Adrien Béraud
8acafe844d
dht: release pending bootstrap after first attempt
2026-03-13 20:39:40 -04:00
Adrien Béraud
688b713c09
tests: cover bootstrap put failure after disconnect
2026-03-13 20:39:37 -04:00
Adrien Béraud
017df59dde
update version to 3.7.6
2026-03-13 18:30:43 -04:00
Adrien Béraud
964800a506
tests: disable test_networkengine on MSVC
2026-03-13 16:30:36 -04:00
Adrien Béraud
4f423d066f
tests: attempt to fix test_networkengine on MSVC
2026-03-13 16:09:49 -04:00
Adrien Béraud
ae49b96c2d
tests: attempt to fix test_networkengine on MSVC
2026-03-13 16:02:33 -04:00
Adrien Béraud
3701b21425
tests: attempt to fix test_networkengine on MSVC
2026-03-13 15:49:52 -04:00
Adrien Béraud
55af602026
tests: fix build with GCC 14
2026-03-13 15:32:45 -04:00
Adrien Béraud
eda121297b
proxy client: protect searches when updating push token
2026-03-13 15:10:12 -04:00
Adrien Béraud
603e777c9e
dht: refresh token on listen confirmation
2026-03-13 15:10:12 -04:00
Adrien Béraud
bef4e61fc6
tests: add test for update of listen token
2026-03-13 15:10:12 -04:00
Adrien Béraud
42971d9587
tests: add test for proxy client token change
2026-03-13 15:10:12 -04:00
Adrien Béraud
4a43326de1
tests: add more proxy tests
2026-03-13 13:06:36 -04:00
Adrien Béraud
8fcb19627d
dht: mark listen as non-synced on auth failure
2026-03-13 13:06:08 -04:00
Adrien Béraud
b6ea2ed8e2
proxy client: resubscribe on new endpoint
2026-03-13 13:05:34 -04:00
Adrien Béraud
ac520bd587
tests: make sure bootstrap then put always succeed
2026-03-13 12:03:09 -04:00
Adrien Béraud
4bd796cddd
dht: state is connecting if bootstrap is pending
2026-03-13 11:53:32 -04:00
Adrien Béraud
ad372bf232
dht: restart searches on connect
2026-03-13 11:52:57 -04:00
Adrien Béraud
299b4510f5
AGENTS.md: add commit instructions
2026-03-13 11:07:01 -04:00
Adrien Béraud
ae44ac98fb
dht: open new socket if previous was closed
2026-03-13 11:06:50 -04:00
Adrien Béraud
c37ff1b167
tests: add test for reopens socket after node expiration
2026-03-13 11:06:30 -04:00
Adrien Béraud
f94f072ad6
dht: send token in listen confirmation
2026-03-13 00:53:05 -04:00
Adrien Béraud
c51beca374
dht: properly persist expiration time
2026-03-13 00:38:31 -04:00
Adrien Béraud
4b9a6489c3
dht: persist storage usage
2026-03-13 00:28:38 -04:00
Adrien Béraud
34722cab7a
dht: clarify storage log
2026-03-13 00:04:49 -04:00
Adrien Béraud
9e1dc3f793
dht: log stats about imported values
2026-03-13 00:04:49 -04:00
Adrien Béraud
0eacd7fe6c
tools: move to dht::tools namespace
2026-03-13 00:04:49 -04:00
Adrien Béraud
37f4469961
update version to 3.7.3
2026-03-09 16:08:26 -04:00
Adrien Béraud
e9c4a31949
Support listing tests and running a single test by name
2026-03-09 13:57:56 -04:00
dependabot[bot]
1b5d9569ec
build(deps): bump pypa/cibuildwheel from 3.3.1 to 3.4.0
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.3.1 to 3.4.0.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.3.1...v3.4.0 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 3.4.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-09 10:35:40 -04:00
dependabot[bot]
e70f76f7f9
build(deps): bump docker/setup-buildx-action from 3 to 4
...
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action ) from 3 to 4.
- [Release notes](https://github.com/docker/setup-buildx-action/releases )
- [Commits](https://github.com/docker/setup-buildx-action/compare/v3...v4 )
---
updated-dependencies:
- dependency-name: docker/setup-buildx-action
dependency-version: '4'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-09 10:34:43 -04:00
dependabot[bot]
0f25da371e
build(deps): bump docker/setup-qemu-action from 3 to 4
...
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action ) from 3 to 4.
- [Release notes](https://github.com/docker/setup-qemu-action/releases )
- [Commits](https://github.com/docker/setup-qemu-action/compare/v3...v4 )
---
updated-dependencies:
- dependency-name: docker/setup-qemu-action
dependency-version: '4'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-09 10:33:43 -04:00
dependabot[bot]
f33f66c038
build(deps): bump docker/login-action from 3 to 4
...
Bumps [docker/login-action](https://github.com/docker/login-action ) from 3 to 4.
- [Release notes](https://github.com/docker/login-action/releases )
- [Commits](https://github.com/docker/login-action/compare/v3...v4 )
---
updated-dependencies:
- dependency-name: docker/login-action
dependency-version: '4'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-09 10:33:06 -04:00
dependabot[bot]
1d08ff1489
build(deps): bump docker/metadata-action from 5 to 6
...
Bumps [docker/metadata-action](https://github.com/docker/metadata-action ) from 5 to 6.
- [Release notes](https://github.com/docker/metadata-action/releases )
- [Commits](https://github.com/docker/metadata-action/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: docker/metadata-action
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-03-09 10:32:35 -04:00
Adrien Béraud
b892be092a
infohash: make core APIs constexpr
...
Make Hash default constructor, hex constructor, data(), const
operator[] and fromString constexpr. Change fromString to be
non-throwing: it now uses a validity flag and fills the hash with zeros
on parse error instead of throwing. Add a constexpr toHexArray helper
that returns a std::array<char, N*2> for compile-time hex conversion.
Update tests to include <string_view>, use std::string_view, add
constexpr InfoHash usage and a static_assert for the hex array.
2026-03-08 23:34:50 -04:00
Adrien Béraud
9a902fa80c
dht: fix incorrect id in log
2026-03-08 12:27:00 -04:00
Adrien Béraud
984d720fac
meson: export opendht_EXPORTS
2026-03-08 12:26:23 -04:00
Adrien Béraud
931d79b701
dht: handle out-of-order partial messages
2026-03-08 12:26:23 -04:00
Adrien Béraud
58a5791063
ci: fix ccpp.yml syntax
2026-03-07 14:52:14 -05:00
Adrien Béraud
33b2bf12fa
dht: fix recycling of existing search
2026-03-06 23:19:51 -05:00
Adrien Béraud
08e9f0b763
network_engine: always erase partial message after processing
2026-03-06 23:19:51 -05:00
Adrien Béraud
12cb93f9cf
AGENTS.md: update
2026-03-06 23:19:51 -05:00
Adrien Béraud
71d14bb0fe
proxy stats: use localhost by default
2026-03-02 16:32:38 -05:00
Adrien Béraud
635a73141a
build/cmake: use three dots as policy_max separator
2026-03-01 21:39:53 -05:00
Adrien Béraud
de4327c056
proxy stats: add storage stats
2026-02-27 16:52:07 -05:00
Adrien Béraud
348d6be920
proxy stats: add storage stats
2026-02-27 16:00:16 -05:00
Adrien Béraud
dbdf2ba94d
update version to 3.7.2
2026-02-27 15:27:44 -05:00
Adrien Béraud
ef7505baaa
tests/dhtrunner: adapt to use longId
2026-02-27 15:12:31 -05:00
Adrien Béraud
9ad6b3a608
dhtrunner, securedht: mark findCertificate(InfoHash hash) as deprecated
2026-02-27 14:26:39 -05:00
Adrien Béraud
a32d76d312
securedht: cleanup
2026-02-27 00:18:20 -05:00
Adrien Béraud
8ebecfa25a
securedht: stop storing certificate at sha1(publicKey)
2026-02-27 00:12:40 -05:00
Adrien Béraud
ae3c2ae0d3
build/meson: use c++20 by default
2026-02-26 22:53:06 -05:00
Adrien Béraud
808ef0c51e
rename tests to test_x format
2026-02-26 22:52:48 -05:00
Adrien Béraud
6cf6892767
add AGENTS.md
2026-02-26 22:51:41 -05:00
Adrien Béraud
9ebe6e8bb6
tools: pretty print byte count
2026-02-24 00:15:47 -05:00
Adrien Béraud
a5455c19a6
update version to 3.7.1
2026-02-22 23:34:54 -05:00
Adrien Béraud
166566dbf4
remove automake files
2026-02-22 23:34:16 -05:00
Adrien Béraud
9b1534e6fe
update README.md
2026-02-22 21:42:24 -05:00
Adrien Béraud
0263104373
proxy client: implement getLocalStoreSize
2026-02-22 18:55:02 -05:00
Adrien Béraud
0fc7e451e6
dhtrunner: move getNodeInfo implementation to securedht
2026-02-22 17:16:28 -05:00
Adrien Béraud
85cbee0f1a
dht: add local storage stats in NodeInfo
2026-02-22 16:27:35 -05:00
Adrien Béraud
724b5e592e
dht: use independent storage quota for local values
2026-02-22 16:27:35 -05:00
Adrien Béraud
28001840fa
dht: avoid infinite loop when largest quota empty
...
Ensure the selected store_quota entry is non-empty before entering the
expiry loop. If an empty entry is encountered, log a warning and break
out to prevent repeatedly attempting to expire from an empty quota
(which could hang the expiry routine).
2026-02-21 18:34:07 -05:00
Adrien Béraud
047c10cf85
dht: handle empty values when updating storage quota
2026-02-21 18:34:00 -05:00
Adrien Béraud
152f9a2f54
dht: take shared_ptr by const-ref in sortedBucketInsert
2026-02-19 22:02:32 -05:00
Adrien Béraud
62243fb4f6
query: optimize msgpack_pack
2026-02-19 21:50:07 -05:00
Adrien Béraud
01eab83a7b
value: move filter
2026-02-19 21:44:43 -05:00
Adrien Béraud
2c71662af7
dht_proxy_client: prevent disconnect on local ip change
2026-02-09 15:05:43 -05:00
Adrien Béraud
64032eb6d2
utils: use fmt::format for getaddrinfo error
...
Use fmt::format to build the std::invalid_argument message in
SockAddr::resolve
instead of manual std::string concatenation when getaddrinfo fails.
2026-02-09 13:26:02 -05:00
Adrien Béraud
d91f3bdbbd
dhtrunner: implement getStorageLimit
2026-02-09 13:26:00 -05:00
Adrien Béraud
1abaddba3e
ci: bump VCPKG_VERSION to 2026.01.16
...
Bump VCPKG_VERSION in .github/workflows/windows-build.yml from
2025.07.25 to 2026.01.16 so the Windows CI workflow uses the newer
vcpkg release.
2026-02-05 21:53:28 -05:00
Adrien Béraud
65b537f6e9
ci: test builds with C++17/20/23
...
Add a cxx_standard matrix (17, 20, 23) to the Ubuntu and macOS CI jobs
and pass
-DCMAKE_CXX_STANDARD=${{ matrix.cxx_standard }} and
-DCMAKE_CXX_STANDARD_REQUIRED=ON to CMake so the builds are exercised
across
C++17, C++20 and C++23.
2026-02-05 21:53:14 -05:00
Adrien Béraud
f44646ff82
ci(windows): test builds with C++17/20/23 standards
...
Add a cxx_standard matrix axis to the Windows build jobs and pass
-DCMAKE_CXX_STANDARD and -DCMAKE_CXX_STANDARD_REQUIRED=ON to CMake so
builds are produced for C++17, C++20 and C++23. Include the chosen
standard in the uploaded artifact names for both shared and static
builds.
2026-02-05 21:34:44 -05:00
Adrien Béraud
73dc55155e
utils: make unpackMsg take const Blob& and inline
...
Change the template unpackMsg to accept a const Blob& to avoid an
unnecessary copy of the Blob argument. Move the non-template unpackMsg
(returning msgpack::unpacked) into the header as an inline function and
remove its out-of-line definition from src/utils.cpp. Update
declarations accordingly.
2026-02-05 21:31:42 -05:00
Adrien Béraud
aa000ee586
http: cleanup
2026-02-05 21:31:42 -05:00
Adrien Béraud
ec4c3e343c
dht: format request targets with fmt
2026-02-05 21:31:42 -05:00
copilot-swe-agent[bot] and aberaud
4b24f1da38
Replace deprecated systemd directives with current alternatives
...
Replace ReadOnlyDirectories with ReadOnlyPaths and ReadWriteDirectories with ReadWritePaths as per modern systemd.exec(5) documentation
Co-authored-by: aberaud <101827+aberaud@users.noreply.github.com >
2026-02-03 16:35:58 -05:00
dependabot[bot]
c47048121b
build(deps): bump https://github.com/microsoft/vcpkg
...
Bumps [https://github.com/microsoft/vcpkg ](https://github.com/microsoft/vcpkg ) from HEAD to 2026.01.16. This release includes the previously tagged commit.
- [Release notes](https://github.com/microsoft/vcpkg/releases )
- [Commits](https://github.com/microsoft/vcpkg/compare/dd3097e305afa53f7b4312371f62058d2e665320...66c0373dc7fca549e5803087b9487edfe3aca0a1 )
---
updated-dependencies:
- dependency-name: https://github.com/microsoft/vcpkg
dependency-version: 2026.01.16
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-02-02 09:33:51 -05:00
Adrien Béraud
638ffdc669
logger: add missing header
2026-01-29 22:55:47 -05:00
Adrien Béraud
40ffafa756
logger: use file and line number
2026-01-29 22:38:57 -05:00
Adrien Béraud
e6836f076f
logger: protect children with mutex
2026-01-29 22:38:31 -05:00
Adrien Béraud
03c1158d7e
build: use /Zc:__cplusplus on MSVC
2026-01-27 16:09:07 -05:00
Adrien Béraud
0018e577d9
build: add simdutf to opendht.pc when downloaded
2026-01-27 15:07:15 -05:00
Adrien Béraud
eb7d94ee79
Revert "build: add private link to simdutf static to pkgconfig"
...
This reverts commit ea6ca025fc .
2026-01-27 15:06:23 -05:00
Adrien Béraud
ea6ca025fc
build: add private link to simdutf static to pkgconfig
2026-01-27 14:45:07 -05:00
Adrien Béraud
1105a68f93
build: update simdutf to 8.0.0
2026-01-27 14:31:41 -05:00
Adrien Béraud
76ae1cd6f2
logger: make setFilter match substrings
...
Allow to filter based on partial tag match
2026-01-27 14:29:43 -05:00
Adrien Béraud
c59c0ef64d
log: add tag and filter mechanism
2026-01-26 17:31:37 -05:00
Adrien Béraud
1011d82b35
update version to 3.7.0
2026-01-21 15:41:12 -05:00
Adrien Béraud
29f87169f8
proxy server: use TLS 1.3
2026-01-21 15:29:25 -05:00
ovari
435ee9cbbc
Create FUNDING.yml
2026-01-18 09:17:19 -05:00
Adrien Béraud
6f111bcc0c
build/cmake: cleanup
2026-01-17 22:30:10 -05:00
Adrien Béraud
f9cba71d51
Switch project license from GPL-3.0-or-later to MIT
2026-01-17 22:25:43 -05:00
Adrien Béraud
4fd4745647
update copyright to 2026
2026-01-17 17:09:06 -05:00
dependabot[bot]
7165a02aaf
build(deps): bump pypa/cibuildwheel from 3.3.0 to 3.3.1
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.3.0 to 3.3.1.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.3.0...v3.3.1 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 3.3.1
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2026-01-13 21:43:51 -05:00
Andreas Hatziiliou
fb34682e78
cleanup: deprecate autotools
2026-01-13 21:41:57 -05:00
Adrien Béraud
db8ca78943
securedht: refactor lambda captures
2026-01-07 00:30:56 -05:00
Adrien Béraud
da9360143d
dht: fix typo in comment
2026-01-07 00:14:25 -05:00
Adrien Béraud
f55884b7d3
utils: cleanup
2026-01-07 00:14:25 -05:00
Adrien Béraud
d978b471a3
thread pool: cleanup
2026-01-07 00:14:25 -05:00
Maxim Cournoyer
4a6a7e3827
meson: Install headers.
...
Fixes : #820
2026-01-03 11:38:40 -05:00
Maxim Cournoyer
d3e6788dc0
meson: Fix durl tool dependency on liburing.
...
Fixes : #819
2026-01-03 11:38:40 -05:00
dependabot[bot]
e355e1fd5c
build(deps): bump actions/cache from 4 to 5
...
Bumps [actions/cache](https://github.com/actions/cache ) from 4 to 5.
- [Release notes](https://github.com/actions/cache/releases )
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md )
- [Commits](https://github.com/actions/cache/compare/v4...v5 )
---
updated-dependencies:
- dependency-name: actions/cache
dependency-version: '5'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-12-29 14:28:28 -05:00
dependabot[bot]
5890971e1d
build(deps): bump actions/upload-artifact from 5 to 6
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 5 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-12-29 14:28:01 -05:00
dependabot[bot]
512d81e0c0
build(deps): bump actions/download-artifact from 6 to 7
...
Bumps [actions/download-artifact](https://github.com/actions/download-artifact ) from 6 to 7.
- [Release notes](https://github.com/actions/download-artifact/releases )
- [Commits](https://github.com/actions/download-artifact/compare/v6...v7 )
---
updated-dependencies:
- dependency-name: actions/download-artifact
dependency-version: '7'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-12-29 14:27:21 -05:00
Adrien Béraud
c433fbe460
docker: don't build unit tests
2025-12-15 00:26:10 -05:00
Adrien Béraud
7f5d39ad36
ci/docker: add dependencies between jobs
2025-12-15 00:06:29 -05:00
Adrien Béraud
8c6dd935a9
ci: correct syntax error in clang-analyzer
2025-12-14 23:48:29 -05:00
Adrien Béraud
79d51e10ab
ci: update dependencies
2025-12-14 23:29:08 -05:00
Adrien Béraud
b582ced6da
docker: update dependencies
2025-12-14 23:29:08 -05:00
copilot-swe-agent[bot] and aberaud
c7079c7200
Add ARM64 support to Docker image builds
...
Co-authored-by: aberaud <101827+aberaud@users.noreply.github.com >
2025-12-14 23:28:58 -05:00
Adrien Beraud
c60c6b8af2
update version to 3.6.2
2025-12-10 12:13:28 -05:00
Adrien Beraud
9f7e4aaa96
Revert "log: add tag and filter mechanism"
...
This reverts commit afce0fb0b4 .
2025-12-10 12:12:05 -05:00
Adrien Béraud
0bfd3cd9fc
network engine: check on_expired
2025-12-09 15:46:57 -05:00
Adrien Béraud
442e5501d8
build/meson: update
2025-12-09 15:22:45 -05:00
dependabot[bot]
0203bd8318
build(deps): bump alpine from 3.22 to 3.23 in /docker
...
Bumps alpine from 3.22 to 3.23.
---
updated-dependencies:
- dependency-name: alpine
dependency-version: '3.23'
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-12-09 10:44:45 -05:00
Adrien Béraud
cd07d68bef
crypto: only support webPush with GnuTLS 3.8.2+
2025-12-09 10:39:58 -05:00
Adrien Béraud
88f3870f20
dhtrunner: add registerInsecureType method and header file
2025-12-09 09:43:30 -05:00
Adrien Béraud
d9d2c44e0f
format
2025-12-09 09:43:19 -05:00
Adrien Béraud
f427f36d9c
Add exceptions for missing owner or recipient in unpackValue methods
2025-12-09 09:43:19 -05:00
Adrien Béraud
a1c881d914
network engine: replace lambda with direct on_expired callback
2025-12-09 09:42:52 -05:00
Adrien Béraud
fbc489863f
http: use string_view for resolver, url
2025-12-02 22:28:32 -05:00
Adrien Béraud
504a3638d9
proxy server: add support for encrypted WebPush
2025-12-02 22:28:32 -05:00
Adrien Béraud
a85abccd62
proxy server: improve unifiedpush support
2025-12-01 22:20:37 -05:00
Adrien Béraud
afce0fb0b4
log: add tag and filter mechanism
2025-12-01 22:20:37 -05:00
Adrien Béraud
99f0334229
http: improve Url parsing
2025-11-30 12:40:17 -05:00
Lucas Fryzek
55ac11bf5c
Modify UnifiedPush post request to be AND_3 compliant
2025-11-30 10:54:18 -05:00
Adrien Béraud
e028c1be8c
update version to 3.6.0
2025-11-26 14:03:56 -05:00
Adrien Béraud
3e8d9835d4
utils: various fixes to build with c++23
2025-11-26 14:03:56 -05:00
Adrien Béraud
18df23bd50
build/cmake: support c++ other than 17
2025-11-26 14:03:56 -05:00
Adrien Béraud
6b8c3ea581
base64: use simdutf
2025-11-26 14:01:45 -05:00
dependabot[bot]
7645f284e4
build(deps): bump pypa/cibuildwheel from 3.2.1 to 3.3.0
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.2.1 to 3.3.0.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.2.1...v3.3.0 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 3.3.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-11-25 10:54:55 -05:00
dependabot[bot]
2cec478dfc
build(deps): bump actions/checkout from 5 to 6
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 5 to 6.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-11-25 10:54:00 -05:00
Adrien Béraud
54f07e449c
pkgconfig: link with fmt
2025-11-19 11:20:40 -05:00
Adrien Béraud
09308321f8
network_utils: cleanup
2025-11-19 11:20:02 -05:00
Adrien Béraud
e4b333b672
add clang-format
2025-11-19 11:20:02 -05:00
Adrien Béraud
69f382449d
add .vscode settings
2025-11-19 11:19:55 -05:00
Adrien Beraud
47d2f41930
proxy client: check for null resolver
2025-11-17 12:56:36 -05:00
ovari
d6b124eec0
Update BUILD.md
2025-11-16 17:35:19 -05:00
ovari
0330ee6683
Update BUILD.md
2025-11-16 17:35:19 -05:00
Jean-Charles de Longueville
1b854b8a09
Update BUILD.md from reviewer's comments
2025-11-16 16:50:04 -05:00
Jean-Charles de Longueville
4f6c561540
Update BUILD.md: typo
2025-11-16 16:50:04 -05:00
Jean-Charles de Longueville
79ffe663f6
Update BUILD.md: add debian 13 trixie instructions
2025-11-16 16:50:04 -05:00
dependabot[bot]
a14a97e3a2
build(deps): bump actions/download-artifact from 5 to 6
...
Bumps [actions/download-artifact](https://github.com/actions/download-artifact ) from 5 to 6.
- [Release notes](https://github.com/actions/download-artifact/releases )
- [Commits](https://github.com/actions/download-artifact/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: actions/download-artifact
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-10-28 10:20:24 -04:00
dependabot[bot]
bddc34d47b
build(deps): bump actions/upload-artifact from 4 to 5
...
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact ) from 4 to 5.
- [Release notes](https://github.com/actions/upload-artifact/releases )
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v5 )
---
updated-dependencies:
- dependency-name: actions/upload-artifact
dependency-version: '5'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-10-28 10:19:46 -04:00
kestrel
de6ea1d632
Add support for io_uring for Autotools builds.
...
* configure.ac (liburing): Add --with-liburing option, tests for liburing.
* src/Makefile.am (libopendht_la_CPPFLAGS, libopendht_la_LIBS): Add relevant compiler and linker flags.
2025-10-15 15:13:19 -04:00
kestrel
1d2fd80fad
Use pkg-config to test for llhttp for Autotools builds.
...
* configure.ac (llhttp_lib): Replaces existing tests with PKG_CHECK_MODULES.
* src/Makefile.am (libopendht_la_CPPFLAGS, libopendht_la_LIBS): Add relevant compiler and linker flags.
2025-10-15 15:13:19 -04:00
SASANO Takayoshi
f7df3413e1
CMakeLists.txt: revise libreadline check on OpenBSD
2025-10-15 15:12:17 -04:00
SASANO Takayoshi
4cb67002e3
CMakeLists.txt: fix -lreadline not found error
2025-10-15 15:12:17 -04:00
SASANO Takayoshi
197a9a6bcd
CMakeLists.txt: fix 'install TARGETS RUNTIME_DEPENDENCY_SET is not supported'
2025-10-15 15:12:17 -04:00
SASANO Takayoshi
8641de139d
CMakeLists.txt: avoid libreadline check on OpenBSD
2025-10-15 15:12:17 -04:00
dependabot[bot]
adcb61bbf9
build(deps): bump pypa/cibuildwheel from 3.2.0 to 3.2.1
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.2.0 to 3.2.1.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.2.0...v3.2.1 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 3.2.1
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-10-15 15:11:09 -04:00
dependabot[bot]
70709c9a68
build(deps): bump github/codeql-action from 3 to 4
...
Bumps [github/codeql-action](https://github.com/github/codeql-action ) from 3 to 4.
- [Release notes](https://github.com/github/codeql-action/releases )
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md )
- [Commits](https://github.com/github/codeql-action/compare/v3...v4 )
---
updated-dependencies:
- dependency-name: github/codeql-action
dependency-version: '4'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-10-15 15:10:42 -04:00
kestrel
bf930de9e4
configure.ac: Fix llhttplib substituion.
...
* configure.ac (@http_lib@): Rename to llhttp_lib, replace the substituted value for a pkg-config module name.
2025-10-13 14:35:28 -04:00
Adrien Beraud
bb4e716fc7
README: add pypi badge
2025-10-10 13:59:44 -04:00
Adrien Beraud
54fd6cf64f
securedht: avoid calling identity announced callback multiple times
2025-10-10 13:59:44 -04:00
dependabot[bot]
d905a02b32
build(deps): bump pypa/cibuildwheel from 3.1.4 to 3.2.0
...
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel ) from 3.1.4 to 3.2.0.
- [Release notes](https://github.com/pypa/cibuildwheel/releases )
- [Changelog](https://github.com/pypa/cibuildwheel/blob/main/docs/changelog.md )
- [Commits](https://github.com/pypa/cibuildwheel/compare/v3.1.4...v3.2.0 )
---
updated-dependencies:
- dependency-name: pypa/cibuildwheel
dependency-version: 3.2.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-10-10 11:11:56 -04:00
Adrien Béraud
d12f9271b8
pht: use const reference for IndexEntry::TYPE
...
Prevents static initialization order issue
2025-09-22 14:41:22 -04:00
Adrien Béraud
3639d651a2
docker: add alpine edge container
2025-09-22 14:41:22 -04:00
Adrien Béraud
07824391a2
update version to 3.5.5
2025-09-22 14:41:22 -04:00
Adrien Béraud
c855f495d0
ci/release: remove reference to removed artifact
2025-09-19 00:59:28 -04:00
Adrien Béraud
cc5c148fc1
python: repair python installation with cmake
2025-09-19 00:41:18 -04:00
Adrien Béraud
949751f632
crypto: disable Oaep test for win32
2025-09-18 23:39:38 -04:00
Adrien Béraud
6dfc4e4ba1
ci: don't build with documentation on Windows/MSVC
2025-09-18 23:19:35 -04:00
Adrien Béraud
db8d62e17b
ci: don't build with documentation on Windows/MSVC
2025-09-18 23:02:22 -04:00
Adrien Béraud
7226775987
crypto: disable Oaep test for win32
2025-09-18 22:26:50 -04:00
Adrien Béraud
9c264e1cad
python: add debug information for python install
2025-09-18 22:19:41 -04:00
Adrien Béraud
deee57b6dd
ci/github: call ctest directly
2025-09-14 18:27:19 -04:00
Adrien Béraud
95f0b27eae
cmake: build tests as separate executables
2025-09-14 17:55:59 -04:00
ovari
b6f98a8488
Update crypto.cpp
2025-09-14 13:38:35 -04:00
ovari
73acc27a11
Update CheckAtomic.cmake
2025-09-14 13:38:35 -04:00
ovari
d46e302b3f
Update network_engine.h
2025-09-14 13:38:35 -04:00
ovari
6f57e03b48
Update network_engine.h
2025-09-14 13:38:35 -04:00
ovari
a5e39768e4
Update securedht.cpp
2025-09-14 13:38:35 -04:00
ovari
6f6fdba8dd
Update value.cpp
2025-09-14 13:38:35 -04:00
ovari
e5ef0a8900
Update dhtrunner.h
2025-09-14 13:38:35 -04:00
ovari
b6f21933ab
Update securedht.h
2025-09-14 13:38:35 -04:00
ovari
e4b8b0259d
Update http.cpp
2025-09-14 13:38:35 -04:00
ovari
8134d6201a
Update network_engine.cpp
2025-09-14 13:38:35 -04:00
ovari
db4cd7dcc1
Update peer_discovery.cpp
2025-09-14 13:38:35 -04:00
ovari
9d6107c01c
Update storage.h
2025-09-14 13:38:35 -04:00
ovari
de46d55b13
Update crypto.cpp
...
“ !” → “.”
bits → bit
can’t → unable to
wrong → incorrect
2025-09-14 13:38:35 -04:00
Adrien Béraud
75afd9d9dc
ci/msvc: build without documentation
2025-09-14 13:36:45 -04:00
Adrien Beraud
99c56d13bb
crypto: fix build on GnuTLS 3.8.3 and bellow
2025-09-08 16:38:25 -04:00
Adrien Béraud
95fa29d2ec
securedht: add CertificateStoreQuery by PkId
2025-09-08 00:14:44 -04:00
Adrien Béraud
f3d9d8414d
crypto: add test for RSA OAEP
2025-09-07 23:45:40 -04:00
Adrien Béraud
0c9d715d6d
crypto: allow to generate RSA OAEP private keys
2025-09-07 23:44:47 -04:00
Adrien Béraud
cfff247e06
crypto: support RSA OAEP encryption and decryption
2025-09-07 22:15:00 -04:00
Adrien Béraud
04edc70fee
dhtrunner: update documentation for join()
2025-09-06 17:14:10 -04:00
Adrien Béraud
fdc4bdee68
ci: install cmake on Debian 12
2025-09-06 16:35:34 -04:00
Adrien Béraud
69bf7afe31
BUILD.md: add pkg-config and support for Debian 12
2025-09-06 16:33:48 -04:00
Adrien Béraud
7b3ee44175
ci: add proxy dependencies for Debian 12
2025-09-06 16:33:21 -04:00
Adrien Béraud
122c30cce8
ci: add Debian 12
2025-09-06 16:08:03 -04:00
Adrien Béraud
957e05319f
BUILD.md: cleanup
2025-09-05 00:35:46 -04:00
Adrien Béraud
58f83ab3c6
build/cmake: python cleanup
2025-09-05 00:35:28 -04:00
Adrien Béraud
6151ee8c0b
pyproject: remove unneeded install command
2025-09-04 23:23:27 -04:00
Adrien Béraud
c08b6a7f5d
add support for version
2025-09-04 23:22:34 -04:00
Adrien Béraud
0139e7a2d4
update README.md
2025-09-04 23:22:10 -04:00
Adrien Béraud
416de4b4f8
update version to 3.5.4
2025-09-02 23:52:56 -04:00
Adrien Béraud
b45f32e8f8
README: update for new Python API
2025-09-02 23:51:36 -04:00
Adrien Béraud
cda5b0afa2
python: update pingpong example for asyncio
2025-09-02 23:48:43 -04:00
Adrien Béraud
f66a57b033
python: cleanup asynio layer
2025-09-02 23:48:34 -04:00
Adrien Béraud
72a688cd14
ci/release-package: remove deprecated python wheels build
2025-09-02 23:07:48 -04:00
Adrien Béraud
e882efe89e
build/cmake: use VCPKG_INSTALLED_DIR for python
2025-09-02 21:49:30 -04:00
Adrien Beraud
7b49ed873c
build/python: install build for ci job
2025-09-02 19:49:02 -04:00
Adrien Béraud
3fec6e7636
pht: don't export IndexEntry::ValueType
2025-09-02 09:22:40 -04:00
Adrien Béraud
67ac7a4d86
python: update pingpong example for asyncio
2025-09-02 01:57:09 -04:00
Adrien Béraud
615534fa0f
python: add initial asyncio implementation
2025-09-02 01:45:29 -04:00
Adrien Béraud
4250336951
.gitignore: add cmake files
2025-09-02 01:45:29 -04:00
Adrien Béraud
932cacbda3
python: use single to argument for putEncrypted
2025-09-02 01:40:28 -04:00
Adrien Béraud
3b254663ca
build/python: install delvewheel from ci job
2025-09-02 01:37:59 -04:00
Adrien Béraud
18f74693e9
ci/github: merge windows python wheels
2025-09-01 21:06:11 -04:00
Adrien Béraud
e0cc973aa4
build/cmake: enable python in full vcpkg preset
2025-09-01 20:17:42 -04:00
Adrien Béraud
c866d46798
build/cmake: filter more windows dlls
2025-09-01 20:17:42 -04:00
Adrien Béraud
c762e4e43f
build/cmake: remove python from all taregts
2025-09-01 20:17:42 -04:00
Adrien Béraud
3eed83c22d
ci/github: build windows python wheel
2025-09-01 20:17:42 -04:00
Adrien Béraud
234f47a018
python/setup.py: use appropriate flags for windows build
2025-09-01 20:17:42 -04:00
Adrien Béraud
615463e103
ci/python: add support for windows/msvc wheel build
2025-09-01 20:17:42 -04:00
Adrien Béraud
d50585188d
utils: add missing header
2025-09-01 19:42:41 -04:00
Adrien Béraud
dd247d15ba
python: call gnutls_global_init/gnutls_global_deinit on module load/unload
2025-09-01 19:40:20 -04:00
Adrien Béraud
4a34045c0f
python/setup.py: add appropriate build definitions
2025-09-01 19:33:18 -04:00
Adrien Béraud
edfdb39970
vcpkg: update description
2025-09-01 19:27:59 -04:00
Adrien Béraud
89551496c7
python: update readme
2025-08-31 00:21:46 -04:00
Adrien Beraud
becb878f5f
python: add bindings for sign, checkSignature
2025-08-31 00:04:00 -04:00
Adrien Beraud
a94f99dcd2
python: add annotations and checks
2025-08-30 23:52:40 -04:00
Adrien Beraud
8de9584b72
dhtrunner: mark getId() deprecated
2025-08-30 22:20:32 -04:00
Adrien Beraud
303a3c2c5a
python: unify putEncrypted
2025-08-30 22:18:49 -04:00
Adrien Beraud
e6dcc3226d
python: cleanup
2025-08-30 19:54:33 -04:00
Adrien Beraud
ab71e5a59e
python: add support for putEncrypted with PkId
2025-08-30 19:30:20 -04:00
Adrien Beraud
bf9561c4af
python: add binding for getLongId, getPublicKey
2025-08-30 19:27:57 -04:00
Adrien Beraud
c139fc9791
python: add binding for PkId
2025-08-30 19:13:59 -04:00
dependabot[bot]
31ddf3cc27
build(deps): bump actions/download-artifact from 4 to 5
...
Bumps [actions/download-artifact](https://github.com/actions/download-artifact ) from 4 to 5.
- [Release notes](https://github.com/actions/download-artifact/releases )
- [Commits](https://github.com/actions/download-artifact/compare/v4...v5 )
---
updated-dependencies:
- dependency-name: actions/download-artifact
dependency-version: '5'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-08-25 10:50:51 -04:00
Adrien Béraud
1bbdc3e673
add BUILD.md
2025-08-24 20:05:55 -04:00
Adrien Béraud
60ecb95cf6
build/python: copy README.md to build dir
2025-08-24 16:01:29 -04:00
Adrien Béraud
075ea59244
build/cmake: fix including jsoncpp on linux
2025-08-24 15:52:39 -04:00
Adrien Béraud
2f98f1f987
ci/pipy: build for Python 13
2025-08-24 11:22:49 -04:00
Adrien Béraud
2b22fe9055
setup.py: update metadata
2025-08-24 11:22:32 -04:00
Adrien Béraud and Copilot Autofix powered by AI
e144460869
Potential fix for code scanning alert no. 17: Workflow does not contain permissions
...
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2025-08-24 01:47:50 -04:00
Adrien Béraud
6b54c42fdb
build python with appropriate flags for public dependencies
2025-08-24 01:47:50 -04:00
Adrien Béraud
57587b6cd8
build/cmake: improve msgpack lookup logic
2025-08-24 01:47:50 -04:00
Adrien Béraud
0fd642f92d
ci: add python-wheels.yml
2025-08-24 01:47:50 -04:00
Adrien Béraud
91310c83a7
setup.py.in: remove unneeded cythonize
2025-08-24 01:47:50 -04:00
Adrien Béraud
daf2f8edaf
value: add OPENDHT_PUBLIC to default store policy
2025-08-24 01:25:47 -04:00
Adrien Béraud
a957cdba86
python: update copyright
2025-08-18 09:58:54 -04:00
Adrien Béraud
5a9a8dc67a
dependabot: add cargo ecosystem for rust
2025-08-18 09:58:52 -04:00
Adrien Béraud
5fe0dad574
build/python: replace calls to setup.py
2025-08-17 22:08:13 -04:00
Adrien Béraud
a051b391a8
python: update setup.py to use a SPDX license expression
2025-08-17 00:17:14 -04:00
Adrien Béraud
ec27ff6c49
docker: update for Ubuntu 24.04
2025-08-17 00:00:09 -04:00
Adrien Béraud
0e1042124e
docker: update to Ubuntu 24.04, drop Ubuntu 18.04
2025-08-16 23:45:42 -04:00
dependabot[bot]
f7e7101abc
build(deps): bump alpine from 3.19 to 3.22 in /docker
...
Bumps alpine from 3.19 to 3.22.
---
updated-dependencies:
- dependency-name: alpine
dependency-version: '3.22'
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-08-16 23:30:13 -04:00
dependabot[bot]
26957ee632
build(deps): bump actions/checkout from 4 to 5
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 4 to 5.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v4...v5 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: '5'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-08-16 23:29:14 -04:00
dependabot[bot]
04fa07edfe
build(deps): bump actions/download-artifact from 4 to 5
...
Bumps [actions/download-artifact](https://github.com/actions/download-artifact ) from 4 to 5.
- [Release notes](https://github.com/actions/download-artifact/releases )
- [Commits](https://github.com/actions/download-artifact/compare/v4...v5 )
---
updated-dependencies:
- dependency-name: actions/download-artifact
dependency-version: '5'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-08-16 23:28:15 -04:00
dependabot[bot]
6cf763dfa4
build(deps): bump docker/build-push-action from 5 to 6
...
Bumps [docker/build-push-action](https://github.com/docker/build-push-action ) from 5 to 6.
- [Release notes](https://github.com/docker/build-push-action/releases )
- [Commits](https://github.com/docker/build-push-action/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: docker/build-push-action
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com >
2025-08-16 23:27:13 -04:00
Adrien Béraud
c41e42e58c
Create dependabot.yml
2025-08-16 23:20:39 -04:00
Adrien Béraud and Copilot Autofix powered by AI
1b238083d3
Potential fix for code scanning alert no. 7: Workflow does not contain permissions
...
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2025-08-16 22:12:56 -04:00
Adrien Béraud
0784270c2e
ci/github: use codeql for github actions
2025-08-16 21:49:02 -04:00
Adrien Béraud
e675bb62fd
update version to 3.5.1
2025-08-16 21:34:13 -04:00
Adrien Béraud
43ac0e14e0
python: fix syntax error in setup.py.in
2025-08-16 21:22:57 -04:00
Adrien Béraud
f4d494cb3d
python: build inplace in build directory
2025-08-16 21:22:57 -04:00
Adrien Béraud
b3dfbf13d8
tools: header cleanup
2025-08-16 21:22:57 -04:00
Adrien Béraud
93538e89c6
build/cmake: add appropriate llhttp flags to opendht.pc
2025-08-16 21:22:57 -04:00
Adrien Béraud
947e845dcd
meson: require meson 1.1
2025-08-16 21:22:57 -04:00
Adrien Béraud
6b49de7e4b
build/cmake: update presets
2025-08-16 21:22:57 -04:00
Adrien Béraud
f6191fa2a5
devcontainer: update
2025-08-16 21:22:57 -04:00
Adrien Béraud
b167887d51
build/cmake: move WIN32_WINNT version detection to dedicated script
2025-08-05 20:25:12 -04:00
Adrien Béraud
77769898ea
ci/release: install wix
2025-08-04 09:45:43 -04:00
Adrien Béraud
42189e3cf7
build/cmake: cleanup
2025-08-04 09:45:29 -04:00
Adrien Béraud
73f8000e49
ci/release: build with cpack
2025-08-04 09:25:46 -04:00
Adrien Béraud
298e334482
build/cmake: always find asio by header
2025-08-04 09:25:32 -04:00
Adrien Béraud
bb982b8cf9
build/cmake: always find asio by header
2025-08-04 09:15:40 -04:00
Adrien Béraud
80145c37bb
build/cmake: enable OPENDHT_DOWNLOAD_DEPS by default
2025-08-04 09:15:19 -04:00
Adrien Béraud
bc8503a21e
ci/release: create vcpkg directories before install
2025-08-03 23:31:50 -04:00
Adrien Béraud
2947dbfe5f
update version to 3.5.0
2025-08-03 23:25:57 -04:00
Adrien Béraud
bf9ddfc72f
build/cmake: add build presets
2025-08-03 23:25:43 -04:00
Adrien Béraud
c848a7e70b
ci/release: build static dhtnode
2025-08-03 22:53:00 -04:00
Adrien Béraud
e7c5b0e36f
ci/windows: use dependency cache
2025-08-03 22:48:48 -04:00
Adrien Béraud
41282c99f9
build/cmake: dhtscanner, dhtchat are examples
2025-08-03 22:31:43 -04:00
Adrien Béraud
e25f6f131a
build/vcpkg: update to 2025.07.25
2025-08-03 21:37:39 -04:00
Adrien Béraud
e69f0fd01e
ci/vcpkg: cache vcpkg binary output
2025-08-02 10:19:04 -04:00
Adrien Béraud
30c9534bc5
build/vcpkg: link to appropriate target for jsoncpp
2025-08-02 10:19:04 -04:00
Adrien Béraud
6d56fb7510
build/cmake: add vcpkg_manifest_static
2025-08-02 10:19:04 -04:00
Adrien Beraud
e46d03b440
ci: enable back OPENDHT_DOWNLOAD_DEPS in CI
2025-07-21 16:30:57 -04:00
Adrien Beraud
8255596171
cmake: various fixes on Linux
2025-07-21 15:49:34 -04:00
Adrien Beraud
baae3ba701
cmake/presets: build ninja with proxy
2025-07-21 13:28:36 -04:00
Maxim Cournoyer
6c43be2a03
configure.ac: Improve the error message when readline is missing.
...
* configure.ac[tools]: Mention that the requirement is due to the
tools.
2025-07-21 08:24:03 -04:00
Maxim Cournoyer
ee4c8a19d6
configure.ac: Error out when doc is requested but Doxygen is missing.
...
Previously, documentation would be automatically disabled when Doxygen
was found missing.
* configure.ac: Change AC_MSG_WARN into AC_MSG_ERROR and adjust error
message.
2025-07-21 08:24:03 -04:00
Maxim Cournoyer
e8cf9dd25f
configure.ac: Make the Python option depend on the indexation option.
...
Mimic what is done already in the CMakeLists.txt file, with one
distinction: do not automagically turn on indexation when Python is
selected; rather, stop and tell the user that it is required for
Python support. Remove the automatic downgrade to --disable-python
when Cython is not found.
* configure.ac: Enforce dependencies on indexation and Cython when
Python support is requested.
2025-07-21 08:24:03 -04:00
Maxim Cournoyer
df21c4524c
configure.ac: Fix the description of the '--without-openssl' option.
2025-07-21 08:24:03 -04:00
Maxim Cournoyer
ccec6c2f67
replace usleep with nanosleep
...
* src/compat/msvc/unistd.h (usleep): Delete.
* tools/dhtcnode.c (main) <usleep>: Replace with nanosleep on non
Windows platform, or Sleep on Windows.
Fixes : #607
2025-07-20 22:25:28 -04:00
Adrien Béraud
5ab450491c
Merge remote-tracking branch 'origin/master' into pulls/1772757862/750
2025-07-20 11:59:30 -04:00
Adrien Béraud
3b0cce8c25
Added and tested build scenarios for Windows (MSYS2, MSVC)
2025-07-20 11:55:40 -04:00
copilot-swe-agent[bot] and aberaud
d6b6f30275
Replace hardcoded documentation path with CMAKE_INSTALL_DOCDIR
...
Co-authored-by: aberaud <101827+aberaud@users.noreply.github.com >
2025-07-19 23:08:08 -04:00
Adrien Béraud
c9f18c8349
Pull Request #750 : Added and tested build scenarios for Windows (MSYS2, MSVC)
2025-07-19 14:36:26 -04:00
Adrien Beraud
df3186ad95
proxy server: export ServerStats
2025-07-16 11:29:18 -04:00
Andrey Vukolov
58956549b8
Merge branch 'savoirfairelinux:master' into winbuild
2025-07-15 16:47:24 +02:00
Adrien Beraud
74ed041791
tests/dhtrunner: create value as shared_ptr
2025-07-10 13:50:42 -04:00
Adrien Beraud
312f883387
proxy server: move ServerStats impl to cpp
2025-07-10 13:46:17 -04:00
Andrey Vukolov
fad4093183
CI fix (squashed 17 commits)
2025-06-27 14:27:48 +02:00
Andrey Vukolov
5c005e097e
Harmonizing CMakeLists
2025-06-26 16:20:27 +02:00
Andrey Vukolov
69f23e49c4
Preparing for rebase and merge #750
...
Addresses:
- https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2157723135
- https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2157794234
- https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2157795386
- https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2161542551
- https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2161546768
2025-06-24 18:06:52 +02:00
Andrey Vukolov
f53976dc2f
Merge branch 'savoirfairelinux:master' into winbuild
2025-06-23 10:34:11 +02:00
Adrien Béraud
1d80a77e55
build/cmake: avoid overriding "" for CMAKE_MSVC_RUNTIME_LIBRARY
2025-06-20 19:06:08 -04:00
Adrien Béraud
fb8734c448
c: use c++ linkage for some non-exported functions
2025-06-20 19:04:59 -04:00
Andrey Vukolov
090fe75b7f
OpenSSL link MSVC workflow workaround
2025-06-19 12:56:44 +02:00
Andrey Vukolov
173ca3d923
OpenSSL link Clang workflow workaround
2025-06-19 12:52:30 +02:00
Andrey Vukolov
f5c875a19d
OpenSSL link CMake workflow check
2025-06-19 12:46:20 +02:00
Andrey Vukolov
6780013f50
Unit tests workaround for possible issue with OpenSSL link
2025-06-19 12:17:10 +02:00
Andrey Vukolov
2f21a6e35a
Unit tests workaround for possible issue with OpenSSL link
2025-06-19 12:07:36 +02:00
Andrey Vukolov
9e9e364048
C tools CFLAGS workaround for STATIC builds
2025-06-19 11:59:50 +02:00
Andrey Vukolov
2c3296542b
Crypt32.dll fix
2025-06-18 17:14:05 +02:00
Andrey Vukolov
72988cca28
Regression fix
2025-06-18 16:53:54 +02:00
Andrey Vukolov
a105513750
Attempt to fix OpenSSL for MSYS2 builds on CI
2025-06-18 16:48:05 +02:00
Andrey Vukolov
bece03eab8
Attempt to fix llhttp for MSYS2 builds on CI
2025-06-18 16:32:28 +02:00
Andrey Vukolov
0fdb6979dd
Attempt to fix OpenSSL for MSYS2 builds on CI
2025-06-18 16:21:57 +02:00
Andrey Vukolov
a77c1d9538
Attempt to fix llhttp for MSYS2 builds on CI
2025-06-18 16:13:10 +02:00
Andrey Vukolov
4a7e1aba15
Attempt to fix llhttp for MSYS2 builds on CI
2025-06-18 16:08:38 +02:00
Andrey Vukolov
a4263b9b54
Attempt to fix llhttp for MSYS2 builds on CI
2025-06-18 15:59:41 +02:00
Andrey Vukolov
e26ed26e05
Attempt to fix restinio for MSYS2 builds on CI
2025-06-18 15:47:31 +02:00
Andrey Vukolov
526b11f973
C binding fixes, libreadline support for MSVC
2025-06-18 15:30:51 +02:00
Andrey Vukolov
627af36085
MSYS2 Crypto library fix
2025-06-18 12:07:51 +02:00
Andrey Vukolov
a22c84d013
MSVC static runtime fix
2025-06-18 11:41:52 +02:00
Andrey Vukolov
3707f6294e
libreadline fix for C tools
2025-06-18 11:29:26 +02:00
Andrey Vukolov
94cb17ef63
libreadline fix, WINVER typo fix
2025-06-18 11:22:55 +02:00
Andrey Vukolov
9bb08fa194
Merge branch 'master' into winbuild
2025-06-18 10:40:02 +02:00
Adrien Béraud
425cd58ea6
ci: build a static windows release
2025-06-17 20:49:05 -04:00
Adrien Béraud
43eb062ac5
build/cmake: use appropriate definitions for shared c lib
2025-06-17 20:25:56 -04:00
Adrien Béraud
29d878fad7
build/cmake: inherit build dir for msvc
2025-06-17 20:22:22 -04:00
Adrien Béraud
a3a95a8f59
build/cmake: use appropriate definitions for shared c lib
2025-06-17 20:22:22 -04:00
Adrien Béraud
550721e233
build/cmake: use global MSVC_RUNTIME_LIBRARY
2025-06-17 20:22:22 -04:00
Adrien Béraud
fa11d60672
c: use OPENDHT_C_PUBLIC for all symbols
2025-06-17 20:22:22 -04:00
Andrey Vukolov
6f8c681b26
Boost fix
2025-06-17 20:23:45 +02:00
Andrey Vukolov
718e445370
typo fix
2025-06-17 19:37:05 +02:00
Andrey Vukolov
5e469cba0f
Boost fetcher (MSYS2/MinGW dependency)
2025-06-17 19:26:40 +02:00
Andrey Vukolov
a05479e2dc
Merge branch 'master' into winbuild
...
- Built and tested on MSVC for static and dynamic builds, tested.
2025-06-17 18:59:51 +02:00
Andrey Vukolov
7f6e47c7aa
Fixed OPENDHT_C to avoid compatibility warnings
2025-06-16 14:16:04 -04:00
Andrey Vukolov
2e7c1a7272
Generalization of CMake build presets
...
- Generalized MSVC build with root presets
- Separated build pipelines into 'minimal' and
'full' variants
- Added VCPKG_MANIFEST_MODE to handle local vcpkg
- Inspected VCPKG_TARGET_TRIPLET and added
VCPKG_OVERLAY_TRIPLETS as fallback options
2025-06-16 14:16:04 -04:00
Adrien Béraud
0f69153900
build/cmake: set appropriate CRT linkage for windows
2025-06-16 09:07:37 -04:00
Adrien Béraud
e1885a17d9
Revert "ci: enable tests on mingw"
...
This reverts commit 87a9df28c6 .
2025-06-15 15:16:08 -04:00
Adrien Béraud
87a9df28c6
ci: enable tests on mingw
2025-06-15 15:07:48 -04:00
Adrien Béraud
bf7cb5a848
ci: only run tests for the release job for now
2025-06-15 13:55:11 -04:00
Adrien Béraud
d24ffb8a1d
build/cmake: use release/static triplets as needed
2025-06-15 12:47:54 -04:00
Adrien Béraud
962aed25fe
build/cmake: add cpack support for wix
2025-06-15 12:47:16 -04:00
Adrien Béraud
a1582220d6
tests: bind connect to loopback address on Windows
2025-06-15 12:46:36 -04:00
Andrei Vukolov
a3bd1416d4
Removed OPENDHT_PUBLIC specifier from templatized classes
2025-06-14 17:45:41 -04:00
Adrien Béraud
f49dabaadc
build/cmake: add MSVC_RUNTIME_LIBRARY for dhtcnode
2025-06-14 14:03:21 -04:00
Adrien Béraud
2e38ec093d
tools/dhtscanner: use client mode
2025-06-14 14:03:21 -04:00
Adrien Béraud
7995c2283d
Workaround for MSVC runtime mismatch on STATIC builds
2025-06-12 20:04:13 -04:00
Adrien Béraud
7bb457d851
Pull Request #762 : Workaround for MSVC runtime mismatch on STATIC builds
2025-06-12 20:00:59 -04:00
Adrien Béraud
80d0648d6d
tools/dhtnode: use utf-8 for console output on Windows
2025-06-12 19:14:56 -04:00
Adrien Béraud
44508cd040
build/cmake: use relative install directories
2025-06-12 10:37:16 -04:00
Andrey Vukolov
e5cc48c068
Merge branch 'master' into msvc-runtime-static
2025-06-12 16:35:29 +02:00
Adrien Beraud
520a15118c
ci: add release job for Windows
2025-06-12 10:32:20 -04:00
Adrien Béraud
81931a211f
ci: add github workflow for windows
2025-06-12 10:32:20 -04:00
Adrien Béraud
9a895d71d9
tools/dhtscanner: cleanup
2025-06-12 10:32:20 -04:00
Adrien Béraud
9d2b3e0b35
build/dev: use build directory
2025-06-12 10:32:20 -04:00
Adrien Béraud
14dbd3341c
build/cmake: enable test feature for vcpkg
2025-06-12 10:32:20 -04:00
Adrien Béraud
f032c7a52b
build/vcpkg: add host tools
2025-06-12 10:32:20 -04:00
Adrien Béraud
cee24974d6
build/vcpkg: add support for tests
2025-06-12 10:32:20 -04:00
Adrien Béraud
d3e2fd1099
fixes for msvc
2025-06-12 10:32:20 -04:00
Adrien Béraud
dd9d74e227
fixes for mingw
2025-06-12 10:32:20 -04:00
Adrien Béraud
e1744ef950
build/cmake: add preset for Unix Makefiles
2025-06-12 10:32:20 -04:00
Adrien Béraud
3f64c32b7a
build/cmake: define WINVER and _WIN32_WINNT on Windows
2025-06-12 10:32:20 -04:00
Adrien Béraud
6b0e154bd5
build/cmake: add vcpkg support for msvc
2025-06-12 10:32:20 -04:00
Andrey Vukolov
11bca9e307
Workaround for MSVC runtime mismatch on STATIC builds
...
- Added CMP0091 policy handler
- Added generator expression for MSVC_RUNTIME_LIBRARY property
to avoid "Runtime Mismatch" linker error on MSVC STATIC builds
2025-06-12 09:36:53 +02:00
Andrey Vukolov
fb630e29b9
Merge branch 'savoirfairelinux:master' into winbuild
2025-06-12 09:28:10 +02:00
Andrey Vukolov
3a0b09816b
Merge remote-tracking branch 'refs/remotes/twdragon/winbuild' into winbuild
2025-06-12 09:23:14 +02:00
Andrey Vukolov
8ab6b5b06e
Fixes for current MSVC build, presets deleted
2025-06-12 09:22:30 +02:00
Adrien Beraud
28ea18671f
http: use appropriate log level for DNS result
2025-06-11 16:08:36 -04:00
Adrien Béraud
01e9c341df
tests: use loopback address if peer bound any
...
fixes some tests on Windows
2025-06-10 18:37:19 -04:00
Adrien Béraud
94006f2fe1
sockaddr: add setLoopback()
2025-06-10 18:35:48 -04:00
Andrey Vukolov
9ca1c45ae7
CMakeLists.txt - remove occasional regression to cjson
2025-06-10 14:01:14 +02:00
Andrey Vukolov
b9a6b1001c
Merge branch 'master' into winbuild
2025-06-10 09:31:47 +02:00
Andrey Vukolov
cc7c48a07e
.gitignore for vcpkg in MANIFEST mode
2025-06-09 11:29:00 -04:00
Andrey Vukolov
798adefcde
Fixes for MSYS2
...
- Set populated only for msgpack-cxx that does not exist for
MinGW GCC x86_64
https://packages.msys2.org/base/mingw-w64-msgpack-cxx
- .gitignore fix for vcpkg (incorporated #760 )
- GnuTLS version handler fix (#755 , #758 )
2025-06-09 15:31:38 +02:00
Andrey Vukolov
72afb61079
Merge branch 'savoirfairelinux:master' into winbuild
2025-06-09 09:40:26 +02:00
Adrien Béraud
e6fc8b7586
dhtrunner: add putEncrypted with PkId 'to' argument
2025-06-09 00:52:05 -04:00
Adrien Béraud
09da6db5e7
securedht: add putEncrypted with PkId 'to' argument
2025-06-09 00:52:05 -04:00
Adrien Béraud
e870c3b486
dhtrunner: allow to find certificates by PkId
2025-06-09 00:52:05 -04:00
Adrien Béraud
dcf31b2c5f
securedht: allow to find certificates by PkId
2025-06-09 00:52:05 -04:00
Adrien Béraud
f2eb234fd9
securedht: put certificate at PkId
2025-06-09 00:52:05 -04:00
Adrien Béraud
c3f120f8f1
build/cmake: build C binding with vcpkg preset
2025-06-08 18:51:14 -04:00
Adrien Béraud
305f437f74
c: use appropriate includes for Windows
2025-06-08 18:51:14 -04:00
Andrey Vukolov
c27f0f8fdc
Merge branch 'master' into winbuild
2025-06-07 22:32:26 +02:00
Adrien Béraud
701e8c89fb
vcpkg: add support for tools
2025-06-07 16:23:59 -04:00
Adrien Béraud
aa212c4b2d
c/tools: use memset instead of bzero
2025-06-07 16:23:59 -04:00
Adrien Béraud
48254a6759
build/cmake: add opendht_EXPORTS as public definition
2025-06-07 16:23:59 -04:00
Adrien Béraud
37ccc2f3a2
build/meson: fix typo
2025-06-07 16:23:59 -04:00
Adrien Béraud
2819047649
build/cmake: define C standard used
2025-06-07 16:23:59 -04:00
Andrey Vukolov
8d8b082ae2
Temporary fix https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2129833074
2025-06-06 11:09:43 +02:00
Andrey Vukolov
5377a48074
Rebase regression fix in tools_common.h
2025-06-06 11:00:35 +02:00
Andrey Vukolov
ca8998e62b
Merge branch 'winbuild' of github.com:twdragon/opendht into winbuild
2025-06-05 18:38:49 +02:00
Andrey Vukolov
62359d9011
Edited CMakeLists.txt file for building over vcpkg only
2025-06-05 18:38:21 +02:00
Andrey Vukolov
3022c4b378
Merge branch 'savoirfairelinux:master' into winbuild
2025-06-05 17:52:47 +02:00
Adrien Béraud
03e4be3974
build/cmake: add presets for vcpkg and unix
2025-06-03 11:46:36 -04:00
Adrien Beraud
91b241599d
build: add vcpkg file
2025-06-03 11:46:36 -04:00
Adrien Beraud
fcf2e7f94e
Create codeql.yml
2025-06-03 11:33:04 -04:00
Adrien Béraud
f1ff618dc8
Create codeql.yml
2025-06-03 11:30:01 -04:00
Adrien Beraud
5dcb342308
ci/github: use autobuild mode
2025-06-03 11:29:07 -04:00
Adrien Beraud
2d9d0761c9
ci/github: use autobuild mode
2025-06-03 11:23:25 -04:00
Adrien Beraud
4df297df6c
ci/github: use autobuild mode
2025-06-03 11:16:48 -04:00
Adrien Beraud
70e8f7efb5
ci/github: udpate CodeQL workflow
2025-06-03 10:58:33 -04:00
Andrey Vukolov
de8b441dae
Merge branch 'master' into winbuild
2025-06-02 16:37:57 +02:00
Andrey Vukolov
5c4997d07e
Merge master branch changes
...
- Applies master branch changes from #753 #754 #755 #756
and commits for version 3.4.0 by @aberaud to winbuild branch
for #750
- CMake version handler for MINIMUM requirement setup to 3.5
2025-06-02 16:26:45 +02:00
Andrey Vukolov
9b33ff8a15
Fix meson.build
2025-06-01 10:26:18 -04:00
Andrey Vukolov
5c21401728
constexpr fixes for preparation of MSVC build
...
- Addresses https://github.com/savoirfairelinux/opendht/pull/750/files#r2089281221 in #750
- Adds infohash.cpp file for correct build of the DLL nametables in SHARED mode with MSVC
- Reverted commits 352e36500c and 6a264d6f73
- Fixes DLL build issues on Windows due to OPENDHT_PUBLIC definitions described in #750
- Prepares the build system for merging changes from #750 (@aberaud)
2025-06-01 10:26:18 -04:00
Adrien Béraud
acae4bc4ff
peer_discovery: use string_view for service type
2025-05-31 19:28:30 -04:00
Andrey Vukolov
68dc6a64be
Definitions fix for #756
2025-05-30 23:05:59 -04:00
Andrey Vukolov
54a8fef0ee
Windows build fixed for tools (wingetopt, signals)
...
- Addresses https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2089286643
- Structures wingetopt and win32 compatibility files for builds on Windows with MSVC
- Adjusts opendht_EXPORTS definition when building tools on MSVC
2025-05-30 23:05:59 -04:00
Andrey Vukolov
a722726196
GNUTLS_INTERNAL_BUILD fix
...
- Removed GNUTLS_INTERNAL_BUILD definition to avoid problems with gnutls_free()
function (https://github.com/savoirfairelinux/opendht/pull/750#issuecomment-2832005765 )
https://github.com/ShiftMediaProject/gnutls/blob/f78e2e673e84601283fb5ec353bfdd53204becd2/SMP/gnutls/gnutls.h#L2286
2025-05-23 18:24:35 -04:00
Andrey Vukolov
b9bd954dfd
GnuTLS version handler routine for versions 3.8.7 and later
...
- Added GnuTLS version handler directives for versions 3.8.7 and later
https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2089284896
2025-05-23 18:24:35 -04:00
Andrey Vukolov
49b1daec38
Indentation fix
2025-05-23 15:43:08 +02:00
Andrey Vukolov
aeb0b163cf
MS Visual Studio .gitignore fix for CMake implicit builds
...
- Addresses review https://github.com/savoirfairelinux/opendht/pull/750#discussion_r2089277264 in #750
- Allows clean clone and build in MS Visual Studio with different settings
2025-05-23 08:59:14 -04:00
Andrey Vukolov
1eba919dbd
Trailing newline fix
2025-05-23 14:42:43 +02:00
Adrien Béraud
c4e75ae66c
update copyright year
2025-05-22 19:07:32 -04:00
Adrien Beraud
d9afd2631b
update version to 3.4.0
2025-05-22 12:05:31 -04:00
Adrien Beraud
405220795b
http: check for cb in async_read_until
2025-05-22 11:53:05 -04:00
Adrien Beraud
3e407e65fa
storage: remove previous value size from quota when appropriate
2025-05-22 11:53:05 -04:00
Adrien Béraud
a2dff6a123
dhtrunner: registerCertificate: take certificate by const ref
2025-05-20 21:55:04 -04:00
Adrien Béraud
8d030f75f6
valuetype: compare certificate using longId
2025-05-19 23:57:09 -04:00
Adrien Béraud
13af7a6002
dhtrunner: registerCertificate: take certificate by const ref
2025-05-19 23:57:09 -04:00
Adrien Béraud
2bc46e9657
build/cmake: search llhttp with pkg_search_module
2025-05-19 23:55:49 -04:00
Adrien Béraud
b3b050ca26
build/cmake: declare support for cmake up to 3.31
2025-05-19 23:55:46 -04:00
Adrien Béraud
38b0b2248f
crypto: add Certificate::getDN() to read RFC4514 distinguished name
2025-05-19 23:55:42 -04:00
Adrien Béraud
5cfb1c6c9c
tests/dhtrunner: wait separately for two conditions
2025-05-19 23:55:37 -04:00
Adrien Béraud
7aad21b7ed
value: cleanup
2025-05-19 23:55:31 -04:00
Andrey Vukolov
3cd5338890
opendht_EXPORTS fix for shared builds
2025-04-27 22:53:17 +02:00
Andrey Vukolov
2fc81ad2dd
GnuTLS build fix for MSVC
...
- Removed GNUTLS_INTERNAL_BUILD definition to avoid
usage of POSIX free() function
- Autotools build fix
2025-04-26 16:55:58 +02:00
Andrey Vukolov
63a49896bf
Fix Meson build
2025-04-24 16:00:04 +02:00
Andrey Vukolov
80755e5f15
Fix Meson build
2025-04-24 15:55:06 +02:00
Andrey Vukolov
ba25b8aeba
Incorporated commits for version 3.3.1 + MSVC build fixes
...
- Incorporated code for version 3.3.1
- Reverted constexpr commits for hex_map:
- 352e36500c
- 6a264d6f73
as they created a lot of problems during builds on
Windows/MSVC.
- Tested binaried linked dynamically with:
- MSYS2 (production-ready)
- MSVC (only for testing) !!!danger of memory leaks!!!
- Tested binaries linked statically on win32 x64 platform
- Populated libasio for both MSYS2 and MSVC builds on Windows
- Pipeline fixes to build on Windows using only:
- vcpkg for MSVC
- MSYS2 pacman for MinGW
and remove the external dependency directory
The reference Windows builds are accessible in the following IPFS directory:
https://bafybeihsrak7orgubrnl5lvpcyzb4xf6kc7cd4tfvctucftg6vfqdhphlq.ipfs.dweb.link/
2025-04-24 14:50:23 +02:00
Andrey Vukolov
279589fa78
Pre-master
2025-04-23 18:18:58 +02:00
Adrien Béraud
c3669cfd36
ci/github: update restinio tag name
2025-04-22 22:37:39 -04:00
Adrien Béraud
45f04a7b6f
ci/github: update restinio
2025-04-22 22:33:59 -04:00
Adrien Béraud
33f9570ecb
adapt for Asio 1.34
2025-04-22 20:02:37 -04:00
Andrey Vukolov
1c1c99974a
Added and tested build scenarios for Windows (MSYS2, MSVC static)
...
- Based on Windows build adjustment code from @novemus
(see his magnificient code merge request #716 )
- Determined full-static and dynamic link libraries for
Windows if built using MSYS2 or MSVC
- Built without restinio and llhttp [TODO]
- Set for automatic fetching and population from the network
the following libraries for MSYS2:
- GnuTLS 3.8.4 for 64-bit Windows (tested for dynamic
and static builds)
- Auto name adjustments for GnuTLS
- GnuTLS 3.8.9 for 32-bit Windows (untested)
- cJSON as a dependency for msgpack
- msgpack 6.1.1
- jsoncpp 1.9.5
- libfmt 11.1.2
- libasio 1.30.2
for MSVC:
- cJSON (used by msgpack in dynamic builds)
- jsoncpp 1.9.5
- libfmt 11.1.2
- Various build scenario fixes for MSVC dynamic builds
- Added modular codebase for infohash.cpp to avoid header
treatment mismatches in MSVC when compiling DLL
- Added convenience prints in the build scenario
- Fixed inconvenient usage of pkgconfig in Windows, the
link scenarios adjusted accordingly
- Fixed hardcoded find_library calls
- Added standard CMake handler for Boost library using
BOOST_ROOT variable, including environmental definition
- Fixed libreadline linkage on POSIX when the default link
point is turned off for OPENDHT_TOOLS (Mint Linux)
- Added versioned handler for CMP0167 policy (from CMake 3.30)
- Code fixes for compatibility headers in Windows (crypto.cpp,
network_utils.h, utils.h)
- Urgent fix for improper redefinition of _WINNT_VERSION for
Windows 10/11
(https://github.com/savoirfairelinux/opendht/pull/716#issuecomment-2793129052 )
- Compile definitions fixed for opendht_EXPORTS and OPENDHT_BUILD
in build scenario for OPENDHT_TOOLS
- Urgent fix for GnuTLS version handler in the code (type
redefinition in version 3.8.7 and later)
https://github.com/savoirfairelinux/opendht/pull/716#issuecomment-2792592951
- Various fixes for proper dynamic linking in Windows
- Built and tested in dynamic and static build scenarios under
MSYS2 in Windows 10 and Windows 11, proven working. The
static build does not seem fully static, the redevelopment
of the MSVC build scenario is proposed by @novemus
- Built and tested in static mode under MSVC/Visual Studio 2022.
Proven working
- Improper usage of the C's free() function is detected in GnuTLS
dynamically linked in Windows (shiftmedia-gnutls 3.7.2 to 3.8.7)
- Added a MSVC-specific source hack to avoid using gnutls_free()
function when built in Windows using dynamic link.
!!! CAUTION !!!
This implementation should be considered as a dirty hack likely
leading to memory leaks! The code should be thoroughly tested
and refactored to avoid memory leaks, but the true origin of
errors is still not revealed [TODO]
- My respect to @novemus and his works over #716
2025-04-22 14:46:41 +02:00
François-Simon Fauteux-Chapleau
c2d8b19380
http: fix service name resolution failure
2025-04-14 22:12:56 -04:00
Adrien Béraud
9bd957da48
build/cmake: update CheckAtomic.cmake
2025-04-05 10:29:06 -04:00
Adrien Béraud
352e36500c
utils: make HexMap constexpr
2025-04-05 09:49:58 -04:00
Adrien Béraud
7397bd615f
infohash: always write end of string terminator
2025-03-24 23:37:07 -04:00
Adrien Béraud
6a264d6f73
infohash: constexpr HexMap constructor
2025-03-24 23:29:32 -04:00
François-Simon Fauteux-Chapleau
b0fa19d6f8
Merge pull request #747 from savoirfairelinux/proxy_push_result
...
proxy client: provide result for pushNotificationReceived
2025-02-20 15:29:58 -05:00
Adrien Beraud
b2860e1731
proxy client: provide result for pushNotificationReceived
2025-02-20 14:13:16 -05:00
Adrien Beraud
ad65ce872b
docker: update llvm image to Ubuntu 24.04
2025-02-14 12:03:55 -05:00
Adrien Beraud
0cdc828953
docker: update restinio
2025-02-14 11:50:46 -05:00
Adrien Beraud
65e13fff4e
ci/github: update llhttp
2025-02-14 11:48:42 -05:00
Adrien Beraud
748247d660
ci/github: update actions
2025-02-14 11:46:05 -05:00
Adrien Beraud
456f266be3
update restinio
2025-02-14 11:41:16 -05:00
Adrien Beraud
2c26030108
build/cmake: accept both llhttp and libllhttp
2025-02-14 11:28:50 -05:00
Adrien Beraud
efc26245ae
update version to 3.3.0
2025-02-11 16:01:27 -05:00
Adrien Beraud
b9e00c7a0f
tools/cnode: show value ID when put completes
2025-02-11 15:48:59 -05:00
Simon Désaulniers
5bf19c875c
c: dht_value_with_id_new for setting an ID
...
Necessary for cancelling put values. Otherwise, the user doesn't have
the value ID for asking to cancel the permanent put.
2025-02-04 13:24:54 -05:00
Simon Désaulniers
5c18c980aa
c/opendht: check for server_ca null
2025-01-25 09:32:15 -05:00
Simon Désaulniers
b8d6fdc8eb
c/opendht: dht_runner_run_config, consider client_identity
2025-01-25 09:32:15 -05:00
Simon Désaulniers
27bfd547c5
c/opendht: dht_runner_run_config, consider server_ca
2025-01-25 09:32:15 -05:00
ovari
5237f0a3b3
Update dht.cpp
2025-01-05 10:01:40 -05:00
ovari
23af860532
Update pht.h
2024-12-19 15:29:21 -05:00
ovari
4c98f7c8f4
pht.h: cleanup
2024-12-19 15:29:21 -05:00
Adrien Beraud
2a4b357420
ci: update libargon2 on Ubuntu
2024-12-19 15:22:58 -05:00
Adrien Beraud
a26ac441ba
proxy: cleanup
2024-12-17 16:04:22 -05:00
Adrien Beraud
80cfed38a1
build/cmake: make using io_uring optional
2024-12-17 16:04:22 -05:00
Lucas Dias
83ae498008
Catch exception of DeserializeNodes
...
Fix calls to DeserializeNodes. They must
catch possible exceptions
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-12-17 14:06:36 -05:00
Adrien Béraud
7c184e1c8c
Revert "build/cmake: accept both llhttp and libllhttp"
...
This reverts commit 7cf43f53ac .
2024-11-26 11:22:58 -05:00
Andreas Traczyk
4aa417802f
deps: win32: migrate from http_parser to llhttp
2024-11-26 11:09:21 -05:00
Adrien Béraud
cdba5b33cc
proxy server: add options to listen route
2024-11-20 11:40:12 -05:00
Adrien Béraud
81bd05fe84
proxy node: remove jquery, update for new APIs
2024-11-20 11:40:12 -05:00
Adrien Béraud
cf135d18b4
c node: fix typo
2024-11-20 11:40:12 -05:00
Adrien Béraud
c7ba7f6703
utils: use fmt::format for time
2024-11-20 11:40:12 -05:00
Adrien Beraud
c73c8c77f2
search: combine callbacks in case of multiple equivalent puts
2024-11-20 11:39:19 -05:00
Adrien Beraud
c3bb16e92f
tests: add testPutDuplicate
2024-11-20 11:39:19 -05:00
Adrien Beraud
3f27cd7069
proxy client: resubscribe on token change
2024-11-18 11:07:55 -05:00
Adrien Beraud
b222efe638
proxy client: pass push parameters to constructor
2024-11-18 11:07:55 -05:00
Adrien Béraud
3c62026b5c
proxy server: move time_point using statement before use
2024-11-05 20:20:45 -05:00
Adrien Béraud
7cf43f53ac
build/cmake: accept both llhttp and libllhttp
2024-11-05 20:12:13 -05:00
François-Simon Fauteux-Chapleau
df189e3e12
dht_proxy_server: add push notification statistics
2024-11-05 15:13:39 -05:00
Adrien Beraud
7e0e7d5483
github/ci: update macOS job to macOS 15
2024-11-04 16:44:36 -05:00
Adrien Beraud
1aeb596b04
crypto: fix warning
2024-11-04 16:39:35 -05:00
Adrien Beraud
950194f68e
proxy client: allow to configure user agent for proxy
2024-11-04 16:34:02 -05:00
AmnaSnene
5dc3d3cfd7
Raise an error if any Identity file fails to save
2024-11-04 12:08:34 -05:00
François-Simon Fauteux-Chapleau
5397f80b87
value: preserve priority when encrypting
...
All encrypted values put on the DHT currently have the default priority
of 0 because the priority information is ignored by the Value::encrypt
function.
2024-10-22 15:22:43 -04:00
Adrien Beraud
88d0af9e3d
meson: fix conf_data used before definition
2024-10-03 15:33:03 -04:00
François-Simon Fauteux-Chapleau
792b851d77
dht_proxy_server: fix Android push notifications
...
This commit updates the format of the push notification requests sent by
the DHT proxy server to conform to FCM's HTTP v1 API. (The previously
used API was deprecated in 2023, see:
https://firebase.google.com/docs/cloud-messaging/migrate-v1 )
The "priority" and "ttl" (time to live) options are specific to Android
and therefore need to be put in the "android" block, as documented here:
https://firebase.google.com/docs/reference/fcm/rest/v1/projects.messages
2024-09-19 12:48:36 -04:00
Adrien Béraud
9da832c1d1
http: use appropriate string format syntax
2024-08-11 11:44:47 -04:00
liufei
44f6d21c83
DecryptError cause by low level error
2024-07-23 11:37:26 -04:00
AmnaSnene
38454eaf6e
peer discovery: add a timer to schedule connectivityChanged with a maximum interval of one minute
2024-07-16 14:25:01 -04:00
novemus
3be70cd90d
msvc build adjustment
2024-07-13 09:42:34 +03:00
Matthew Webb
76a2bd234a
Get off of deprecated GCM AES methods
...
Multiple compiler warnings note that the gcm_aes_* family of functions are deprecated. They have been replaced with gcm_aes<key_length>_*. This change uses the correct set of functions based on the given key size. Resolves #571 .
Sample compiler warning:
/home/noviv/opendht/src/crypto.cpp: In function ‘dht::Blob dht::crypto::aesEncrypt(const uint8_t*, size_t, const dht::Blob&)’: /home/noviv/opendht/src/crypto.cpp:97:20: warning: ‘void nettle_gcm_aes_set_key(gcm_aes_ctx*, size_t, const uint8_t*)’ is deprecated [-Wdeprecated-declarations]
97 | gcm_aes_set_key(&aes, key.size(), key.data());
| ^
In file included from /home/noviv/opendht/src/crypto.cpp:27:
/usr/include/nettle/gcm.h:276:1: note: declared here
276 | gcm_aes_set_key(struct gcm_aes_ctx *ctx,
| ^~~~~~~~~~~~~~~)
https://github.com/gnutls/nettle/commit/6a19845e6f71791ca98765d490ec08e776494bee marked the functions as deprecated.
2024-07-11 10:07:05 -04:00
Adrien Beraud
972d4d28a1
pkgconfig: add optional liburing dependency
2024-07-05 11:38:32 -04:00
Matthew Webb
72e0a4fb6b
Fix an unused parameter warning in dhtrunnertester
...
This change eliminates the following compiler warning without reducing readability:
/home/noviv/opendht/tests/dhtrunnertester.cpp: In lambda function:
/home/noviv/opendht/tests/dhtrunnertester.cpp:292:89: warning: unused parameter ‘expired’ [-Wunused-parameter]
292 | node2.listen(key2, [&](const std::vector<std::shared_ptr<dht::Value>>& values, bool expired){
| ~~~~~^~~~~~~
2024-07-03 21:59:07 -04:00
AmnaSnene
3e2fd5e8fa
peer discovery: address requested changes
2024-06-25 13:27:35 -04:00
AmnaSnene
8b3f7f2480
peer discovery: re-publish and re-discover immediately when a node disconnects, instead of on the connectivityChanged signal.
2024-06-25 13:27:35 -04:00
AmnaSnene
57c855e1cb
peer discovery: post reDiscover() and publish() to the ioContext when connectivity changes.
2024-06-25 13:27:35 -04:00
Adrien Beraud
56e7cd94a5
cmake, meson: allow to use io_uring
2024-06-21 12:09:29 -04:00
Adrien Beraud
074e05cc32
ci/github: update to latest action versions
2024-06-10 16:39:55 -04:00
Lanius-collaris
251f66dfce
fix getif_workaround_android.h
...
char may be signed
2024-06-10 08:21:57 -04:00
Lucas Dias
227a7aa0d9
make crypto error messages more readable
...
Add verifications to gnutls calls and throw expcetion
with readable messages.
For example, if call loadIdentity and crt file has name
different of private key exception message was
Can't get certificate public key ID: ASN1 parser: Value was not found.
However, the real problem is that crt file was not found.
Now, for the same problem the exception message will be:
Error while reading file.
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-06-09 16:56:29 -03:00
Lucas Dias
e12e344a79
make crypto error messages more readable
...
Add verifications to gnutls calls and throw expcetion
with readable messages.
For example, if call loadIdentity and crt file has name
different of private key exception message was
Can't get certificate public key ID: ASN1 parser: Value was not found.
However, the real problem is that crt file was not found.
Now, for the same problem the exception message will be:
Error while reading file.
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-06-09 16:55:10 -03:00
Lucas Dias
d4fc4fd658
Merge branch 'crypto_error_messages' of https://github.com/lucassdiass/opendht into crypto_error_messages
...
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-06-09 16:53:32 -03:00
Lucas Dias
08d67cc8d8
Merge branch 'crypto_error_messages' of https://github.com/lucassdiass/opendht into crypto_error_messages
...
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-06-09 16:52:09 -03:00
Lucas Dias
208afd22f2
Merge branch 'crypto_error_messages' of https://github.com/lucassdiass/opendht into crypto_error_messages
2024-06-09 15:55:31 -03:00
Lucas Dias
9eea01202a
make crypto error messages more readable
...
Add verifications to gnutls calls and throw expcetion
with readable messages.
For example, if call loadIdentity and crt file has name
different of private key exception message was
Can't get certificate public key ID: ASN1 parser: Value was not found.
However, the real problem is that crt file was not found.
Now, for the same problem the exception message will be:
Error while reading file.
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-06-09 15:46:34 -03:00
Lucas Dias
304a9992fe
make crypto error messages more readable
...
Add verifications to gnutls calls and throw expcetion
with readable messages.
For example, if call loadIdentity and crt file has name
different of private key exception message was
Can't get certificate public key ID: ASN1 parser: Value was not found.
However, the real problem is that crt file was not found.
Now, for the same problem the exception message will be:
Error while reading file.
Signed-off-by: Lucas Dias <lucas_dias@redes.ufsm.br >
2024-06-09 09:45:21 -03:00
Adrien Beraud
ae62216bf4
rust: update to 2021, fix memory issues
2024-06-07 10:29:26 -04:00
Adrien Beraud
cd92eeaae5
dht: add support to behave as a client node
2024-06-07 09:52:01 -04:00
Adrien Beraud
9dad7c69fd
peer discovery: cleanup
2024-06-07 09:31:48 -04:00
Lanius-collaris
5cc5b98aeb
fix android workaround
2024-06-07 09:21:05 -04:00
Lanius-collaris
c03ce419ca
peer_discovery: add a workaround for Android hotspot
2024-06-07 09:21:05 -04:00
Adrien Béraud
ceef3f048c
README: add llhttp dependency
2024-06-03 08:32:17 -04:00
Adrien Béraud
8dd926182c
ci/github: update before install
2024-06-03 08:26:52 -04:00
Adrien Béraud
c8b528b3f4
update version to 3.2.0
2024-05-31 06:58:09 -04:00
Adrien Béraud
a65148cd08
ci: build proxy client for Autotools build
2024-05-31 06:58:09 -04:00
Adrien Béraud
5a2a20a32f
http: migrate from http-parser to llhttp
2024-05-31 06:58:09 -04:00
Lanius-collaris
318d02c55a
update http, dht_proxy_client
...
http: simplify Connection::async_connect()
dht_proxy_client: add listenKeepIdle setting
2024-05-25 23:57:52 -04:00
Lanius-collaris
a69da52f89
update http.h, http.cpp
2024-05-25 23:57:52 -04:00
Lanius-collaris
ac0ea6ac57
proxy client: decrease the frequency of keepalive for listen op
2024-05-25 23:57:52 -04:00
Lanius-collaris
88d65a55a7
http: allow to modify keepalive option
2024-05-25 23:57:52 -04:00
Lanius-collaris
dffe7d91ee
return to 386943de
2024-05-25 23:57:52 -04:00
Lanius-collaris
da638b3ae6
cleanup
2024-05-25 23:57:52 -04:00
Lanius-collaris
379568ae0d
Update http.cpp
2024-05-25 23:57:52 -04:00
Lanius-collaris
24adfbf2c4
Adjust TCP keepalive options for listen op
2024-05-25 23:57:52 -04:00
François-Simon Fauteux-Chapleau
89179cad4f
network_utils: use poll instead of select
...
select is limited to file descriptor numbers below FD_SETSIZE (1024),
and calling FD_SET with a higher value can cause a buffer overflow. This
can be problematic for applications using OpenDHT as a library.
2024-05-22 11:57:38 -04:00
François-Simon Fauteux-Chapleau
f2cee8e9ce
thread pool: add function to detach threads
2024-04-23 14:02:32 -04:00
Adrien Béraud
386943de39
tests/proxy: use random port
2024-04-06 23:29:38 -04:00
Adrien Béraud
60b810af7e
meson: disable long tests by default
2024-04-06 23:29:35 -04:00
Adrien Béraud
aa2c0c2da9
meson: add test for PeerDiscovery
2024-04-06 23:01:41 -04:00
Adrien Béraud
62debfa58a
meson: add test prefix for unit tests
2024-04-06 22:59:12 -04:00
Adrien Béraud
9741dba974
update version to 3.1.11
2024-04-06 22:26:56 -04:00
Adrien Béraud
93ac28ead2
meson: configure pkgconfig files
2024-04-06 20:10:33 -04:00
Adrien Beraud
a0a3cd3028
proxy: add long test
2024-04-06 19:42:42 -04:00
Adrien Béraud
611ecbd06a
meson: add ability to build static or shared
2024-04-06 19:18:27 -04:00
Adrien Béraud
70c465b006
meson: link tests with msgpack
2024-04-06 18:43:36 -04:00
Adrien Beraud
59c8d9b9be
op cache: return cache result in onValue
2024-04-06 18:24:16 -04:00
Adrien Beraud
7f70fcd316
proxy client: cancel http request on listen cancel
2024-04-06 18:24:16 -04:00
Adrien Beraud
17e9ad5093
meson: fix build with proxy server
2024-04-06 15:51:11 -04:00
Adrien Beraud
42435bdd4f
meson: allow to build unit tests
2024-04-06 15:51:11 -04:00
Adrien Beraud
c125a2af1f
meson: build thread pool
2024-04-06 15:51:11 -04:00
Andreas Traczyk
c0a1356049
dht_proxy_server: use lambda instead of std::bind for listen callback
...
Avoids issues compiling with MSC.
Also move PushSessionContext definition outside the OPENDHT_PUSH_NOTIFICATIONS condition.
2024-04-04 14:20:01 -04:00
Adrien Béraud
5e6679139b
update version to 3.1.10
2024-04-03 14:35:42 -04:00
Andreas Traczyk
c118f85886
Merge pull request #694 from savoirfairelinux/push-value-IDs
...
provide value IDs for push notifications
2024-04-03 11:52:01 -04:00
Andreas Traczyk
b40d604ef7
provide value IDs for push notifications
2024-04-02 17:34:16 -04:00
SASANO Takayoshi
f630b013ee
replace CPPFLAGS += ... (2)
2024-04-02 13:04:52 -04:00
SASANO Takayoshi
36167c3e45
replace CPPFLAGS += ...
2024-04-02 13:04:52 -04:00
Adrien Béraud
4eaa53a4a6
update version to 3.1.9
2024-03-24 23:42:44 -04:00
Adrien Béraud
4859e9c4e7
meson: support building with push notification support
2024-03-24 23:42:01 -04:00
Adrien Béraud
c82c393102
ci: use Cython from pip
2024-03-24 23:31:18 -04:00
Adrien Béraud
5dc162a4ec
meson: support building python
2024-03-24 23:26:05 -04:00
Adrien Béraud
5a4c599139
meson: support building with indexation
2024-03-24 23:25:40 -04:00
Adrien Béraud
07ca10a451
Revert "ci: build proxy client for Autotools build"
...
This reverts commit 2dc9f25ff4 .
2024-03-24 22:14:32 -04:00
Adrien Béraud
0e556b88be
docker: use cython, meson from pip
2024-03-24 22:08:03 -04:00
Adrien Béraud
0b242e62c5
update version to 3.1.8
2024-03-24 21:46:15 -04:00
Adrien Béraud
acde8fa6ec
crypto: remove legacy decrypt
2024-03-24 18:12:27 -04:00
Adrien Béraud
c8b5611386
dhtnode: fix small typo in put encrypted log
2024-03-24 15:45:55 -04:00
Adrien Béraud
f7e4533282
crypto: always zero-initialize gnutls_datum_t
2024-03-24 15:45:52 -04:00
Adrien Beraud
5abbef547b
use new log format
2024-03-22 13:49:44 -04:00
Adrien Beraud
3c27b2c777
dhtrunner: avoid blocking when stopping
...
A deadlock was possible when if shutdown operation occured when the dht was in "connecting" state.
2024-03-22 13:49:44 -04:00
Adrien Beraud
903eba6a31
proxy client: cancel resolver on stop
2024-03-22 13:49:44 -04:00
Adrien Beraud
a37e42af37
Request: cancel resolver on cancel
2024-03-22 13:49:44 -04:00
Adrien Beraud
cc6cce6157
http: allow to cancel resolver
2024-03-22 13:49:44 -04:00
Adrien Béraud
2dc9f25ff4
ci: build proxy client for Autotools build
2024-03-17 16:38:35 -04:00
Adrien Béraud
7ca39b4a20
http: use OCSP_check_validity to check OCSP validity
2024-03-17 15:56:48 -04:00
Adrien Béraud
fcffcee383
build/cmake: require cmake 3.16
2024-03-17 13:38:17 -04:00
Adrien Béraud
e371bddd48
ci/github: use Cython from pip on Ubuntu 22.04
2024-03-17 13:16:44 -04:00
Adrien Béraud
26d23cf94f
ci/github: use recent Meson for build
2024-03-17 12:48:10 -04:00
Adrien Béraud
b608349e94
ci/github: use BUILD_TESTING instead of OPENDHT_TESTS
2024-03-17 12:19:02 -04:00
Lanius-collaris
f9b46168d0
dht_proxy_server: Allow user to specify non-standard ports in UnifiedPush endpoint
2024-01-17 15:54:04 -05:00
Adrien Béraud
88d15be4ea
build: update version to 3.1.7
2024-01-02 16:25:16 -05:00
Adrien Béraud
0c4942439b
move secure_vector to its own file
2024-01-02 16:22:02 -05:00
Adrien Béraud
b03df3f7a6
aesEncrypt: allow to provide salt
2024-01-02 15:18:44 -05:00
Adrien Béraud
6a6816ada7
build/meson: allow to build c binding
2023-12-11 22:16:58 -05:00
Adrien Béraud
372c87ac12
build: remove rng.cpp
2023-12-11 21:18:15 -05:00
Adrien Béraud
728c99999f
getDerivedRandomEngine: use 32 bit input for std::seed_seq
2023-12-11 21:12:50 -05:00
Adrien Béraud
2017473156
build: update version to 3.1.6
2023-12-11 09:57:51 -05:00
Adrien Béraud
08d6367fdc
pht: move to std::random_device
2023-12-10 16:02:56 -05:00
Adrien Béraud
23d07dae38
rng: drop custom random_device implementation for MinGW/Windows
...
MinGW now has std::random_device support on Windows:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85494
2023-12-10 15:18:59 -05:00
Adrien Béraud
29c83d9c97
rng: improve getSeededRandomEngine
...
* Make sure to use 32 bit input for std::seed_seq
* Retry using random device every use
* Adjust delays and retry count to keep approx. the same max timeout.
In practice the actual average timeout should be reduced, because
the algo doesn't lose existing data and can move forward in case
of occasional failure/retry.
2023-12-10 15:07:39 -05:00
Adrien Béraud
abbc77744e
dhtrunner: allow to configure rng used by the dht
2023-12-10 15:07:39 -05:00
Adrien Béraud
7a61fa371f
dht: allow to provide rng to constructor
2023-12-10 15:06:51 -05:00
Adrien Béraud
ce7f592b1c
search: return if added node is actually removed
2023-12-08 11:02:21 -05:00
Adrien Béraud
111bfea6f3
build: update version to 3.1.4
2023-12-03 22:09:34 -05:00
Adrien Béraud
e35a11a495
tests: add test for aesBuildEncrypted
2023-12-03 22:03:22 -05:00
Adrien Béraud
0592b9ff51
crypto: add aesBuildEncrypted
2023-12-03 22:03:22 -05:00
Adrien Béraud
297e182576
crypto: fix typo in comment
2023-11-28 19:57:01 -05:00
Adrien Béraud
b285e6fd2b
ci/github: use macOS 12
2023-11-28 18:34:37 -05:00
Adrien Béraud
8ed72e204b
build: update version to 3.1.3
2023-11-28 18:18:05 -05:00
Amin Bandali
4592663fd2
build/cmake: Link libatomic where needed for 64-bit atomic ops.
...
Link against libatomic also on architectures that need it for 64-bit
atomic operations. ARM EABI (armel) and little-endian MIPS (mipsel)
are two such architectures.
2023-11-28 10:52:01 -05:00
Adrien Béraud
4c1c6cf8e9
python: add aesEncrypt, aesDecrypt with password
2023-11-28 10:49:41 -05:00
Adrien Béraud
09046ec698
tests: add tests for AES encryption and key streching
2023-11-28 10:49:41 -05:00
Adrien Béraud
24e7b00e4e
crypto: add aesGetKey, aesGetSalt, aesGetEncrypted
...
Allows to retrieve the encryption key and salt from
an encrypted blob, leading the way for biometry support.
2023-11-28 10:49:41 -05:00
Adrien Béraud
95fdadf16b
build: update version to 3.1.2
2023-11-07 13:15:56 -05:00
Adrien Béraud
a271ab1680
python: add putSigned, putEncrypted to DhtRunner
2023-11-07 13:15:56 -05:00
Moreno Giussani
ac9d7942ce
Add loadIdentity
2023-11-07 09:29:46 -05:00
Adrien Béraud
5ca7b8d6dc
python: add cancelPut
2023-11-07 09:15:11 -05:00
Adrien Béraud
805cdbed1d
python: add biding for missing DhtConfig fields
2023-11-06 22:57:50 -05:00
Adrien Béraud
29efd42de3
python: add binding for SockAddr.resolve
2023-11-06 22:57:50 -05:00
Adrien Béraud
ae2a1d83cf
python: use shared_ptr, make_shared from Cython
2023-11-06 21:59:22 -05:00
Adrien Béraud
bad8bdfe13
python: support 'permanent' argument for put
2023-11-06 21:55:16 -05:00
Adrien Béraud
13194b66d3
proxy client: retry permanent put after reconnect
2023-11-02 15:58:11 -04:00
Adrien Béraud
601758f5fd
proxy server: use isMember for timeout
2023-09-27 13:56:43 -04:00
Adrien Béraud
3191498855
update version to 3.0.0
2023-09-24 18:13:22 -04:00
Adrien Béraud
4882826f58
ci, docker: update restinio
2023-09-24 18:13:22 -04:00
Kateryna Kostiuk
61f43c6b05
iOS: use high priority for resubscribe notifications
2023-09-18 15:27:41 -04:00
Adrien Béraud
8b91c24414
python: make callbacks noexcept
2023-09-11 11:52:55 -04:00
Adrien Béraud
dbebaae1f3
callbacks: make raw callbacks except
2023-09-11 11:42:05 -04:00
Adrien Béraud
7cc743ff5e
callbacks: make raw callbacks noexcept
2023-09-11 11:30:22 -04:00
Adrien Béraud
3b02cee495
python: update classifiers
2023-09-11 11:30:04 -04:00
Adrien Béraud
2e520bea4f
unit tests: make testListen run 256 times
...
Makes the test pass in many more cases.
2023-09-09 12:51:15 -04:00
Adrien Béraud
f9f57b50b1
update README.md
2023-09-09 12:41:16 -04:00
Adrien Béraud
fb9e6eee48
Revert "build: do not define ASN1_time_parse when using openssl"
...
This reverts commit 3a8adb4e17 .
2023-08-30 17:59:07 -04:00
Adrien Béraud
b53af75a7f
meson, autotools: link with fmt
2023-08-30 17:58:45 -04:00
Adrien Béraud
2ed40aeefe
proxy client: use [[maybe_unused]]
2023-08-30 17:58:45 -04:00
Adrien Béraud
bb61b8468b
proxy client: implement OnPublicAddressChanged
2023-08-30 17:58:45 -04:00
Adrien Béraud
55688a25aa
http: don't encode whole url
...
url encoding should be used for url components
by users of the library,
otherwise characters like '/' get escaped.
2023-08-30 17:58:45 -04:00
Adrien Béraud
21fd58a39c
tools: show log on PublicAddressChanged
2023-08-30 17:58:45 -04:00
Adrien Béraud
ae56d4e9be
dht: implement OnPublicAddressChanged
2023-08-30 17:58:45 -04:00
Adrien Béraud
982896a718
dht interface: add OnPublicAddressChanged
2023-08-30 17:58:45 -04:00
Adrien Béraud
2ae092e266
storage: remove unused variable
2023-08-30 17:58:45 -04:00
Adrien Béraud
27ce8b00ed
add syncLevel to send announce/listen early
2023-08-30 16:31:47 -04:00
Kateryna Kostiuk
3a8adb4e17
build: do not define ASN1_time_parse when using openssl
2023-08-27 16:54:16 -04:00
Adrien Béraud
899d18968e
thread pool: add missing header
2023-08-20 23:44:49 -04:00
Adrien Béraud
285105c8d1
thread pool: simplify cleanup logic
2023-08-20 23:02:41 -04:00
Adrien Béraud
9e0ad9d926
thread pool: wait for tasks to complete on stop
2023-08-19 18:48:53 -04:00
Adrien Béraud
0fdded0606
thread pool: allow pool to reduce in size after some time
2023-08-19 18:48:53 -04:00
Adrien Béraud
9947172abb
tests/http: wait for the server to start
2023-08-19 18:48:53 -04:00
Adrien Béraud
b034a823a9
dhtcnode: reduce exposed stack storage
2023-08-19 18:48:53 -04:00
Jakob Haufe
7baee925f6
doc: fix dhtnode(1) man page formatting
...
This fixes the following lintian issue:
22: warning: macro 'mF' not defined [usr/share/man/man1/dhtnode.1.gz:1]
2023-08-16 22:44:06 -04:00
Adrien Béraud
ed6c5381d8
http: remove incorrect static usage
2023-07-29 00:02:48 -04:00
Adrien Béraud
d58e4c8a89
build/cmake: remove unsupported attribute
2023-07-28 23:58:46 -04:00
Léo Banno-Cloutier
2f2ed9bca7
url_encode: escape url query
...
For routes such as /api/auth/directory/search, when searching for names such as
"Léo", jams would not respond to the request
since the URL contained invalid characters defined in RFC3986. `url_encode`
turns such characters into their equivalent escaped characters.
2023-07-25 10:28:22 -04:00
Amna
3e888d8e2d
network engine: remove link-local condition from isMartian()
2023-07-05 19:38:24 -04:00
Adrien Béraud
f461eaa191
log: cleanup, avoid using default constructor
2023-06-28 11:27:03 -04:00
Adrien Béraud
411d8dbe62
network_engine: add missing headers
2023-06-28 11:27:03 -04:00
Lanius-collaris
825cf98bf4
dhtnode.cpp: fix void print_usage()
...
Print pushserver parameter instead of openpush
2023-06-28 09:08:52 -04:00
Adrien Béraud
aff1ed4575
network engine: make UA private, constexpr
2023-06-27 20:07:03 -04:00
Adrien Béraud
6b1e7513b3
logger: make class public
2023-06-26 18:25:43 -04:00
Adrien Béraud
8c94dc8f89
dht: update User-Agent (UA) to "o2"
...
The update reflects the slow evolution of the protocol.
Also, saves two bytes in every packet.
2023-06-26 18:25:31 -04:00
Adrien Béraud
a7f459eab9
log: fix build on Windows
2023-06-26 16:10:11 -04:00
Adrien Béraud
7383e3ea29
node cache: increase cleanup period
2023-06-19 18:36:58 -04:00
Adrien Béraud
a416d472fb
node: properly skip id 0
2023-06-19 18:36:17 -04:00
Adrien Béraud
8fb707824e
dockerfile: use deps from ghcr
2023-06-13 20:40:00 -04:00
Adrien Béraud
e646636bde
docker/alpine: use Alpine 3.18
2023-06-13 20:21:34 -04:00
Adrien Béraud
fafd2f0233
update copyright year
2023-06-02 23:16:04 -04:00
Adrien Béraud
9f031303a2
securedht: destroy dht before other fields
2023-06-02 21:50:25 -04:00
Adrien Béraud
9a2e69ea9c
log: simplify logger
2023-06-02 21:50:25 -04:00
Sébastien Blin
54eff3b0aa
proxyServer: no need for a pushServer_ for type==UnifiedPush
2023-06-02 13:18:58 -04:00
Adrien Béraud
817a5baef2
build/cmake: apply OPENDHT_SANITIZE to the C binding
2023-06-01 14:26:22 -04:00
Adrien Béraud
79dfc0403a
dht: remove deprecated constructor
2023-06-01 14:25:45 -04:00
Adrien Béraud
675d892fc1
update version to 2.6.0
2023-05-18 13:13:25 -04:00
Adrien Béraud
2654970499
logger: remove OPENDHT_LOG, rename to logger.h
2023-05-18 12:31:42 -04:00
Adrien Béraud
b3c5c2fcfa
hash: add fmt formatter
2023-05-18 12:31:42 -04:00
Adrien Béraud
6919df592f
sockaddr: add fmt formatter
2023-05-18 12:31:42 -04:00
Adrien Béraud
6cfede0868
logs: use fmt
2023-05-18 12:31:42 -04:00
Adrien Béraud
e176e4baa6
logs: use fmt
2023-05-17 23:43:55 -04:00
Adrien Béraud
4041b69800
DhtRunner, dht_interface: remove setLoggers
2023-05-17 23:43:55 -04:00
Adrien Béraud
da6579132c
log: move Color, printLog as private
2023-05-17 23:43:55 -04:00
Adrien Béraud
24628ff13d
meson: build dhtchat, dhtscanner
2023-05-17 23:43:55 -04:00
Adrien Beraud
d2f29b72c3
update version to 2.5.5
2023-04-24 18:37:47 -04:00
Adrien Beraud
546a960951
cmake: use full path for pkgconfig
2023-04-24 18:36:24 -04:00
Adrien Béraud
27978f3b9f
update version to 2.5.4
2023-04-21 18:34:24 -04:00
Adrien Béraud
a831afdc1e
docker: build using current repo state
2023-04-21 18:33:29 -04:00
Adrien Béraud
13bb50b863
CMake: handle missing SYSTEMD_UNIT_INSTALL_DIR
2023-04-21 18:32:49 -04:00
Adrien Béraud
d16d30c483
Hash: add Hash<N>::get(Hash<M>) to compute an hash from another
2023-04-21 12:00:15 -04:00
Adrien Béraud
4480436cb3
securedht: allow certificate to be stored on longId hash
2023-04-20 22:41:38 -04:00
Adrien Béraud
d4114830be
update version to 2.5.3
2023-04-20 22:41:38 -04:00
Adrien Béraud
9fbac2707d
build/cmake: handle empty SYSTEMD_UNIT_FILE_LOCATION
2023-04-20 22:41:38 -04:00
Adrien Béraud
7cdd6948bf
misc: use bootstrap.jami.net instead of ring.cx
2023-04-20 22:41:38 -04:00
Adrien Beraud
d9c5ff9624
build/cmake: don't use testing on MSVC
2023-04-20 22:41:35 -04:00
Adrien Beraud
47691b8242
cmake: fix msvc build
2023-04-10 11:45:50 -04:00
Adrien Beraud
adf57ce2f0
update version to 2.5.2
2023-04-10 11:39:37 -04:00
Adrien Beraud
aea84977fd
msgpack: support more package names
2023-04-10 11:27:38 -04:00
Adrien Beraud
2f1aef272a
msgpack: support more package names
2023-04-10 11:12:51 -04:00
Adrien Beraud
76089d09a4
msgpack: support more package names
2023-04-10 10:51:14 -04:00
Adrien Beraud
f88f99959b
update version to 2.5.1
2023-04-05 15:57:47 -04:00
Sébastien Blin
dc6aca83c6
Makefile: add node_export
2023-04-05 09:41:22 -04:00
Adrien Beraud
b0e18e9ca4
docker: use dep alpine base image
2023-03-25 18:51:41 -04:00
Adrien Beraud
8516e35e5f
ci/github: cleanup
2023-03-25 18:40:22 -04:00
Adrien Beraud
41eabc7261
thread pool: handle exceptions starting threads
2023-03-25 18:22:58 -04:00
Adrien Beraud
424fe61a49
dht: send large amounts of values in multiple messages
2023-03-25 17:49:16 -04:00
Adrien Beraud
02e03771d4
docker: add Alpine deps
2023-03-25 17:49:08 -04:00
Adrien Beraud
e35f8c29ee
ci/github: don't run ci with autotools
2023-03-25 17:17:40 -04:00
Adrien Beraud
64e3bcf0dc
ci/github: use ninja with meson
2023-03-25 15:08:31 -04:00
Adrien Beraud
a9f3883bfa
meson: install, include public dir from tools
2023-03-25 15:04:11 -04:00
Adrien Beraud
3c3b3dc303
ci/github: add meson build
2023-03-25 14:42:46 -04:00
Adrien Beraud
970e71d215
ci/github: add meson build
2023-03-25 14:38:48 -04:00
Adrien Beraud
b6552ec300
NodeExport: add missing include
2023-03-25 10:46:12 -04:00
Adrien Béraud
58bc772256
NodeExport: use SockAddr, move to separate header
2023-03-23 16:50:19 -04:00
Adrien Béraud
31af08feaa
build/meson: build durl with http and tools
2023-03-23 16:50:19 -04:00
Adrien Béraud
9e60a681f3
use ostringstream instead of stringstream where possible
2023-03-23 16:50:19 -04:00
Adrien Beraud
51525d144b
certificate: add public key cache
2023-03-15 20:44:29 -04:00
Adrien Beraud
965fbb43c7
more attempts to find msgpackc-cxx in a universal way
2023-03-15 12:50:06 -04:00
Adrien Béraud
133d77d985
thread pool: increase max io pool size to 512
2023-03-14 13:11:29 -04:00
Adrien Béraud
9451861f51
update version to 2.5.0
2023-03-13 13:24:21 -04:00
Adrien Béraud
4b489fb7d7
build/meson: make tools an option
2023-03-13 13:24:05 -04:00
Adrien Béraud
7fcaf19ca3
meson: add initial support
2023-03-12 23:57:32 -04:00
Adrien Béraud
c51d59a3a3
Revert "cmake: update msgpack package name"
...
This reverts commit b9d7957bf6 .
2023-03-11 22:30:19 -05:00
Adrien Béraud
bcc02837d3
use proper image name for github action
2023-03-11 22:25:22 -05:00
Adrien Béraud
611017e187
add Alpine image
2023-03-11 22:21:50 -05:00
Adrien Béraud
7f7bff6a28
readme: cleanup
2023-03-11 22:18:52 -05:00
Adrien Béraud
b9d7957bf6
cmake: update msgpack package name
2023-03-11 22:18:27 -05:00
Adrien Béraud
fa31cec73e
pkgconfig: gnutls jsoncpp, openssl are public dependencies
2023-03-09 00:37:46 -05:00
Adrien Béraud
550a8cf362
cmake: use CTest
2023-02-28 19:45:05 -05:00
Adrien Béraud
50996eaf7e
build/cmake: unify static and shared build
2023-02-28 12:58:13 -05:00
Adrien Béraud
813c3b43d2
move filter
2023-02-28 12:58:13 -05:00
Adrien Béraud
4ce9292b28
proxy server: allow to ping push
2023-02-23 15:43:16 -05:00
Adrien Béraud
655aa074bf
update version to 2.4.11
2023-01-31 23:47:01 -05:00
Adrien Béraud
2e9c119dca
build/cmake: add SOVERSION for c binding
2023-01-31 23:45:48 -05:00
Adrien Béraud
7bf2d2a7a9
update version to 2.4.11
2023-01-30 12:05:02 -05:00
Adrien Béraud
d9a97e2cec
use pkg-config for gnutls, fix msgpack
2023-01-29 18:30:28 -05:00
Adrien Béraud
6395399c2d
cmake: use IMPORTED_TARGET with pkg_search_module
2023-01-29 18:30:28 -05:00
Adrien Béraud
e6971c196b
dht: fix value edition, add unit test
2023-01-27 17:31:59 -05:00
Adrien Béraud
b1009a54e3
crypto: compare public keys with longId
2023-01-27 17:31:59 -05:00
Adrien Béraud
33d73d5d55
securedht: compare public key content instead of pointer
2023-01-27 17:31:59 -05:00
Amin Bandali
f42d94da59
build/cmake: Set variables needed by pkg-config files.
...
Up until now, these were only set by the GNU Build System in
configure.ac, and so the pkg-config files generated from CMake builds
did not have the right Libs.private and Requires.private, especially
useful when linking statically.
2023-01-26 21:31:59 -05:00
Adrien Béraud
2418b355d7
ci: build macOS with push notifications
2023-01-25 19:53:53 -05:00
Adrien Béraud
2cb57251a1
proxy client: protect resolver
2023-01-25 19:53:53 -05:00
Adrien Béraud
446da4b792
value: use move in where
2022-12-30 20:42:16 -05:00
Adrien Béraud
aa958b0f1d
value: inline filter
2022-12-30 20:42:14 -05:00
Adrien Béraud
58be07a8b0
infohash: add to_view()
2022-12-30 20:42:11 -05:00
Adrien Béraud
6c61ac53c4
proxy client: cleanup
2022-12-30 20:42:08 -05:00
Sébastien Blin
6e73a78a8b
unifiedpush: remove unifiedpush parameter
...
Because there is multiple unifiedpush endpoint (ntfy.sh is one),
we should not pass it as an option to dhtnode, but use the one
provided by the user in the token (from unified push library).
2022-12-30 20:36:49 -05:00
Amin Bandali
f2623bd51d
build/cmake: Set opendht-c-static's OUTPUT_NAME to opendht-c.
2022-12-30 20:35:17 -05:00
Sébastien Blin
d6a99d0edd
proxyclient: add possibility to set the platform
...
This allow android to change the platform to "unifiedpush".
2022-11-17 11:46:09 -05:00
Sébastien Blin
b9ccc968b2
proxyserver: add support for UnifiedPush standard
...
Make the proxy able to support the UnifiedPush platform, so that
applications using the proxy server can use any UnifiedPush provider.
Documentation: https://unifiedpush.org/
How to test:
+ Install a UnifiedPush provider on a device (e.g. https://ntfy.sh )
+ Run dhtnode with a proxyserver and --unifiedpush https://ntfy.sh
+ Subscribe to a random topic on ntfy (e.g. "dhtproxytest")
+ Subscribe to a hash on the DHT:
curl -X SUBSCRIBE http://my.dht.proxy:8000/key/foo \
-d '{"key":"dhtproxytest", "platform":"unifiedpush"}'
+ Send data on the subscribed hash
Note: the topic should be completely random.
2022-10-11 15:14:51 -04:00
Sébastien Blin
7e33c4fc76
dht_proxy_server: fix push notifications if tls is enabled
...
If the proxy got TLS enabled, this doesn't mean that the REST
endpoint for push notifications is also using TLS.
Also, fix an incorrect log.
2022-10-11 11:54:37 -04:00
Adrien Béraud
39bb520339
proxy server: don't send refresh notification for non-push operations
2022-09-22 12:46:54 -04:00
Sébastien Blin
18e53b9ec8
proxyserver: send correct value id to client
...
when searching for a value to put, the proxy server returned
a json with value->id = 0, causing the client to not refreshing
correctly the values later (when timeout-ing, the value to refresh
is not found).
2022-09-15 11:45:11 -04:00
Sébastien Blin
0b5379380a
rust: update os_socketaddr to latest version
2022-09-08 11:47:02 -04:00
Sébastien Blin
b800012c57
proxyserver: add topic to msgpack
2022-09-08 11:15:28 -04:00
Sébastien Blin
ebeff20215
dht_proxy_server: fix permanent put
...
When a second permanent put request was received, we didn't call
async_wait after changing the expiration, causing push to not be
sent the second day and presence to expire on some devices after
~3 days.
2022-09-07 16:47:37 -04:00
Adrien Béraud
16ff16bd39
docker, ci: update restinio
2022-09-02 17:15:29 -04:00
Adrien Béraud
0d28a7bdab
ci/github: update restinio
2022-09-02 17:14:58 -04:00
Adrien Béraud
69a1bdfc45
update version to 2.4.10
2022-09-02 17:01:23 -04:00
Adrien Béraud
af7d88b057
crypto: allow to build all from std::string_view
2022-08-11 14:52:14 -04:00
Sébastien Blin
abe2e018b6
Merge pull request #629 from AmarOk1412/fix/request_timeout
...
http: modify timeout behaviour
2022-08-11 14:41:10 -04:00
Sébastien Blin
2e79ee4f11
dht_proxy_client: fix not contextually convertible to 'bool' error
...
The current master is broken with clang, this fix the issue.
2022-08-11 14:30:59 -04:00
Sébastien Blin
8b022d0022
Merge branch 'master' into fix/request_timeout
2022-08-11 13:49:44 -04:00
Sébastien Blin
5399dbdfbc
proxy_client: reconnect account if local ip changes
...
When switching between two network interfaces, local address will
change but not the public ip. This generally cause the client to
not correctly updates its candidates.
In this patch, we inject in the proxy client the local candidates
and use it to check if the network changed.
2022-08-11 12:32:44 -04:00
Sébastien Blin
0e3bca1dde
http: modify timeout behaviour
...
In the previous version, the timeout for the connection could be
set only after async_connect while the request is sending.
This means if async_connect is slow (it can happen as if there is
an ipv6 endpoint, it can try to resolve it during dozens of seconds
before falling back on ipv4).
In this patch, it moves the timeout callback in the request. This
callback will be set just before async_connect, to be sure that we
are using the callback while connecting.
2022-08-11 11:17:30 -04:00
Adrien Béraud
a992aa1f05
crypto: allow to build all from std::string_view
2022-07-28 17:11:25 -04:00
Adrien Béraud
1a267418dd
thread pool: release tasks on stop
2022-07-28 17:08:08 -04:00
kkostiuk
0f8d891476
iOS: drop support for voip notifications
2022-07-25 15:26:57 -04:00
Adrien Béraud
b9c79a1de5
thread pool: release tasks on stop
2022-07-20 16:35:47 -04:00
Adrien Béraud
2c7edb695f
update version to 2.4.9
2022-07-18 11:43:35 -04:00
Adrien Béraud
c3ad33687e
misc: fix various warnings
2022-07-17 14:41:41 -04:00
Adrien Béraud
9c5e5cd7b7
proxy server: export symbols for ProxyServerConfig
2022-07-17 14:41:02 -04:00
Adrien Béraud
9048e4a31c
peer discovery: cleanup, reduce memory usage
2022-07-17 14:29:54 -04:00
Adrien Béraud
ba1b3c26c5
procy client: use new routes
2022-07-17 13:00:05 -04:00
Adrien Béraud
c6b4e317df
dhtrunner: only start peer discovery if proxy is disabled
2022-07-17 13:00:05 -04:00
Adrien Béraud
44267a72de
ci/github: cleanup
2022-07-17 13:00:05 -04:00
Adrien Béraud
8c1c5d09c7
build: use Wno-deprecated
2022-07-17 13:00:05 -04:00
Adrien Béraud
acadeb220a
docker: add dhtnode image
2022-07-05 20:02:45 -04:00
Adrien Béraud
ff7c80d416
build/dev: build in sanitize mode
2022-07-05 19:39:36 -04:00
Adrien Béraud
577f2a0645
proxy server: allow to configure address to bind
2022-07-05 19:32:29 -04:00
Adrien Béraud
48e718ffd8
ci/github: update release action
2022-07-05 16:49:54 -04:00
Adrien Béraud
07d25a4140
docker: install systemd
2022-07-05 16:48:23 -04:00
Adrien Béraud
2f7fabf1c7
ci/github: use secrets.AUTH_TOKEN
2022-07-05 16:25:42 -04:00
Adrien Béraud
60274655dd
ci/github: release on tag
2022-07-05 16:20:20 -04:00
Adrien Béraud
eace3d91b2
docker: add python3-virtualenv
2022-07-05 15:21:32 -04:00
Adrien Béraud
86cc41f446
docker: use Ubuntu 22.04 for LLVM build
2022-07-05 15:12:27 -04:00
Adrien Béraud
3ac5b9466a
ci/github: don't build static lib
2022-07-05 15:10:02 -04:00
Adrien Béraud
c95c3de136
docker: use Ubuntu 22.04
2022-07-05 15:09:07 -04:00
Adrien Béraud
a865d6854c
ci/github: use unique names for steps
2022-07-05 14:57:31 -04:00
Adrien Béraud
52b735b1b9
ci/github: build Python Wheel
2022-07-05 14:27:02 -04:00
Adrien Béraud
f862305f78
ci/github: build LLVM Docker images
2022-07-05 14:18:24 -04:00
Adrien Béraud
ce7ffbf2cd
build/python: add dist target
2022-07-05 14:18:24 -04:00
Adrien Béraud
687f643059
build/python: add pyproject.toml
2022-07-05 14:18:24 -04:00
Adrien Béraud
f6e3fc99e6
build/cmake: refactor library linking
2022-07-05 14:18:24 -04:00
Adrien Béraud
293662a710
proxyserver: cleanup, avoid ref-to-temporary
2022-07-05 12:16:41 -04:00
Adrien Béraud
437252bfcc
proxyserver: add bundleId at the end of ProxyServerConfig
2022-07-04 18:20:32 -04:00
kkostiuk
ead21d24a0
proxyserver: add application bundle id option
2022-07-04 18:17:12 -04:00
Adrien Béraud
53de63e829
update version to 2.4.8
2022-06-30 16:10:25 -04:00
Adrien Béraud
633a03d76a
ios: support multiple notification types
...
- VOIP notifications for iOS < 14.5
- alert and background notifications for iOS >= 14.5
2022-06-30 15:44:16 -04:00
Adrien Béraud
3e5fbb0b5c
Update codeql-analysis.yml
2022-06-30 10:48:25 -04:00
Adrien Béraud
6d13e301f9
Create codeql-analysis.yml
2022-06-30 10:43:18 -04:00
Adrien Béraud
4d356b6dca
ci/github: add experimental docker build action
2022-06-29 16:39:49 -04:00
Adrien Béraud
44a251de56
build/autotools: don't export internal symbols
2022-06-28 16:23:40 -04:00
Adrien Béraud
1c536a4c51
update version to 2.4.7
2022-06-28 14:23:23 -04:00
Adrien Béraud
502a649f42
build/cmake: use max version for cmake_minimum_required
2022-06-28 14:22:49 -04:00
Adrien Béraud
12a52c78ac
x509: make PrivateKey::getPublicKey() thread-safe
2022-06-28 14:12:45 -04:00
Adrien Béraud
df2a775927
build/autotols: allow to build with header-only msgpack-cxx installation
2022-06-28 14:12:45 -04:00
Adrien Béraud
2c86ccbe15
build/pkgconfig: update project description
2022-06-28 14:12:45 -04:00
Adrien Béraud
b9321a338b
buiild/autotools: use -fvisibility=hidden in release mode
2022-06-28 14:12:45 -04:00
Adrien Béraud
dc9a211fb0
crypto: protect Id caching with atomic_bool
2022-06-27 15:40:45 -04:00
Adrien Béraud
d49b394eae
crypto: cache public key id
2022-06-27 15:40:45 -04:00
Adrien Béraud
f82c68a871
crypto: remove support for GnuTLS < 3.4
2022-06-27 15:40:45 -04:00
Sébastien Blin
3f4235da69
infohash: fix alignment warning
2022-06-27 15:32:50 -04:00
Sébastien Blin
e259cb0847
infohash: remove optimization due to weird warnings
...
Current operator== creates a very weird warning about using an
uninitialized value (no warning without the reinterpret_cast).
2022-06-27 14:37:25 -04:00
Adrien Béraud
08f9b424de
cmake: allow to build with header-only msgpack-cxx installation
2022-06-23 14:26:26 -04:00
Adrien Béraud
d33c3515f8
update version to 2.4.6
2022-06-23 10:05:28 -04:00
Adrien Béraud
0a70b0f80f
dhtrunner: don't bind port if proxy is used
2022-06-22 22:20:15 -04:00
Adrien Béraud
949cbb9fc7
sockaddr: allow to release ownership
2022-06-22 22:20:15 -04:00
Adrien Béraud
37cfbffdca
dhtcnode: cleanup
2022-06-22 22:20:15 -04:00
Adrien Béraud
efad2ada89
dhtrunner: make getPublicAddress const
2022-06-22 22:20:15 -04:00
Adrien Béraud
d825f4e5ae
misc: use std::make_unique
2022-06-08 13:14:09 -04:00
Adrien Béraud
baa2a5d21c
dhtrunner: remove support for running both dht and proxy client
...
If configured to run as a proxy client, no port will be bound and the local dht node
won't be instantiated.
2022-06-08 13:14:09 -04:00
Sébastien Blin
b3f9683018
securedht: avoid to update cache if not necessary
2022-06-08 13:07:06 -04:00
Adrien Béraud
6d1819acb9
securedht: fix warning
2022-06-07 15:58:16 -04:00
Adrien Béraud
d6ee44b640
dhtrunner: use consistent path for state
2022-06-07 15:38:44 -04:00
Peter Saveliev
383c53d71f
python/tools: network builder v2
...
* `-n`: interfaces number check (1 <= ifnum <= 245)
* `-b`: turn on NDB debug logging, very chatty, dump topology DB files
* `-v`: verbose mode, print main operations
* fix code formatting (isort, flake8, black)
* code refactoring
2022-06-07 15:29:07 -04:00
Peter Saveliev
833c647524
python/tools: update network builder
...
Use updated pyroute2 API:
* NSPopen import from the root
* NDB instead of IPDB
No logic changes, only translated obsoleted API calls.
No code formatting.
2022-06-07 15:29:07 -04:00
Adrien Béraud
7f6f50411c
autotools: fix check for CppUnit
2022-05-30 10:07:04 -04:00
Adrien Béraud
1c7089c055
github: add minimal build
2022-05-25 11:27:15 -04:00
Adrien Béraud
4641780fe6
update version to 2.4.5
2022-05-25 11:05:34 -04:00
Adrien Béraud
c67df2ead3
tasks: generate compile commands
2022-05-25 11:04:59 -04:00
Adrien Béraud
5f743344e5
value: cleanup, move sign & encrypt to cpp
2022-05-25 11:04:46 -04:00
Michael Cho
56442acc84
value: fix build without jsoncpp
2022-05-25 09:49:30 -04:00
Adrien Béraud
41c9104b8a
value: add inline specifier to inline methods
2022-05-05 11:33:53 -04:00
Adrien Béraud
126f0ca966
update version to 2.4.4
2022-05-03 14:46:07 -04:00
Adrien Béraud
adeca7fa1f
tests/dhtrunner: split count per key
2022-04-25 13:48:57 -04:00
Adrien Béraud
5527b6553d
c: use void for dht_version
2022-04-25 13:43:59 -04:00
Adrien Béraud
5a6b9db60c
securedht: move crypto ops to Value
2022-04-25 13:43:57 -04:00
Adrien Béraud
8f1c075897
update version to 2.4.3
2022-04-22 21:12:54 -04:00
Adrien Béraud
fca11e621c
tools/dhtcnode: use version arg, cleanup
2022-04-22 21:10:53 -04:00
Adrien Béraud
38a7234ae3
dht: increase max hashes to 1G
2022-04-22 21:01:36 -04:00
Adrien Béraud
115a0c683f
c: add dht_infohash_from_hex_null
2022-04-22 21:00:18 -04:00
Adrien Béraud
61b7bed0f8
network engine: minor refactoring
2022-04-22 20:25:18 -04:00
Adrien Béraud
dcd8ec7394
tests/dhtrunner: use unlimited store size
2022-04-22 20:25:18 -04:00
Adrien Béraud
51880afcce
tests/dhtrunner: consider value expiration for counting
2022-04-22 20:25:18 -04:00
Adrien Béraud
db3a4e52b2
dht: add config max_store_keys
2022-04-22 20:24:59 -04:00
Adrien Béraud
af8e66b813
tools/dhtnode: show basic storage stats on "ll"
2022-04-20 16:11:21 -04:00
Adrien Béraud
9646eb9374
NodeInfo: add storage stats
2022-04-20 16:10:25 -04:00
Adrien Béraud
0df2fbe5de
tools/dhtcnode: print version on startup
2022-04-20 16:09:24 -04:00
Adrien Béraud
c39eceeddf
tools/dhtcnode: include stdio.h before readline.h
2022-04-20 16:09:08 -04:00
Adrien Béraud
11396c315e
c: add dht_version()
2022-04-20 16:08:12 -04:00
Adrien Béraud
955af06e29
dht: add getStorageLimit
2022-04-20 15:56:14 -04:00
Adrien Béraud
e207e59226
tools/dhtcnode: count values in listen, add "ll"
2022-04-20 12:23:25 -04:00
Adrien Béraud
0302cee8d5
tools/dhtcnode: use memset instead of bzero
2022-04-19 17:45:14 -04:00
Adrien Béraud
8f4031c8cb
update version to 2.4.2
...
Fix typo in 2.4.1 release
2022-04-19 15:37:46 -04:00
Adrien Béraud
f72d1ffa64
update version to 2.4.1
2022-04-19 15:07:55 -04:00
Adrien Béraud
90c65fb0be
tests/dhtrunner: increase put count
2022-04-19 15:07:13 -04:00
Adrien Béraud
c8eb704a92
dhtrunner: prevent integer underflow in UDP rx callback
2022-04-19 14:51:24 -04:00
Adrien Béraud
4c5e26922c
net: increase max queue size
...
Queue is also time-bounded.
Allow for larger bursts of packets.
2022-04-18 17:24:27 -04:00
Adrien Béraud
724c3e431c
dht: notify listeners when value is removed because of limits
2022-04-18 17:19:32 -04:00
Adrien Béraud
a9ddf49ecc
storage: check size before returning oldest
2022-04-18 17:18:08 -04:00
Adrien Béraud
de3dba7ce4
cmake/c: respect OPENDHT_STATIC/SHARED flags
2022-04-15 21:07:56 -04:00
Adrien Béraud
cd9eda6511
tools/dhtcnode: increase shutdown pooling period
2022-04-15 21:06:45 -04:00
Adrien Béraud
ed972fd365
dht: allow to store up to 64k values per hash
2022-04-15 20:12:48 -04:00
Adrien Béraud
75834fb08f
dht: fix potential of-by-one largest computation, cleanup
2022-04-15 20:12:48 -04:00
Adrien Béraud
9991c976ff
dht: prevent potential use-after-free in storageChanged
2022-04-15 20:12:48 -04:00
Adrien Béraud
92b08bbbc9
dht: pass value directly to storageChanged
2022-04-15 20:12:48 -04:00
Adrien Béraud
4f9b50dd60
print_addr: use ostringstream insted of stringstream
2022-04-15 19:18:24 -04:00
Adrien Béraud
d6d73efa37
dht: update storage bucket on refresh
2022-04-15 19:14:12 -04:00
Adrien Béraud
19a4729bf2
test/dhtrunner: use random port, add more assertions
2022-04-14 20:12:57 -04:00
Adrien Béraud
405b8739ab
dhtrunner: always call opEnded once per op
2022-04-14 20:12:55 -04:00
Adrien Béraud
7ed11a02ae
c: cleanup dhtcnode
2022-04-12 17:04:55 -04:00
Adrien Béraud
3442e0acd9
build/dev: cleanup launch.json
2022-04-12 15:38:48 -04:00
Adrien Béraud
59f86861d2
docker: install libtool
2022-04-12 15:38:48 -04:00
Adrien Béraud
091d01a799
c: update dhtcnode
2022-04-12 15:38:48 -04:00
Adrien Béraud
1ed45cdcf9
c: support log to stdout/stderr
2022-04-12 15:38:48 -04:00
Adrien Béraud
c40ba83cb3
c: support building with autotools
2022-04-12 15:38:48 -04:00
Adrien Béraud
7dc5aa9dfd
build/dev: build in build_dev
2022-04-06 12:19:11 -04:00
Adrien Béraud
808eb688b3
tests: wait for put callback before retrieving certificate
2022-04-06 12:18:42 -04:00
Adrien Béraud
12b75a612c
misc: fix various clang-tidy warnings
2022-04-06 12:18:20 -04:00
Sprite
ac79dc5761
cmake: fix incorrectly linking to libatomic on macOS
2022-04-03 20:44:23 -04:00
Adrien Béraud
fe6676f2e6
unit tests: run on pull request
2022-04-03 20:23:37 -04:00
Adrien Béraud
7915b987ec
misc: use more string_view
2022-04-02 17:14:36 -04:00
Adrien Béraud
29bdc1a46f
Revert "cmake: check atomic for RISC-V architecture"
...
Reason for partial revert:
Adding the atomic library is meant by CheckAtomic
to be automatic through CMAKE_REQUIRED_LIBRARIES.
2022-04-01 19:35:15 -04:00
Adrien Béraud
e0d32e80fb
build/dev: use gdb on linux, llvm on macOS with vscode tasks
2022-04-01 19:17:44 -04:00
Sprite
e753d200c6
cmake: fix incorrect variable name
2022-04-01 11:30:47 -04:00
Sprite
85fd395c52
cmake: simplify atomic checks
2022-04-01 11:30:47 -04:00
Sprite
0f146a354b
cmake: check atomic for RISC-V architecture
2022-04-01 11:30:47 -04:00
Adrien Béraud
9fcaca9232
build/dev: add tests to vscode tasks
2022-04-01 11:09:01 -04:00
Adrien Béraud
1bc65bc5f5
network engine: use string_view for better performance
2022-04-01 11:04:59 -04:00
Adrien Béraud
478d28a326
dhtnode: display total count of values for get and listen
2022-03-30 17:56:39 -04:00
Adrien Béraud
4d544d53a8
ci: use scan-build with debug mode
2022-03-29 15:07:24 -04:00
Adrien Béraud
694c44bbec
value: use namespace std::literals
2022-03-29 14:54:59 -04:00
Adrien Béraud
16915ff424
build/dev: add vscode devcontainer and dhtnode task
2022-03-29 14:47:42 -04:00
Adrien Béraud
a22566599c
proxy client: fix building Listener map
2022-03-29 14:47:42 -04:00
Adrien Béraud
f9b2285593
use string view literals where relevant
2022-03-29 14:47:01 -04:00
Adrien Béraud
9c2268fa41
fix various cppcheck warnings/errors
2022-03-29 10:15:00 -04:00
Adrien Béraud
d4e6fd545a
search: use const for iterator comparison
2022-03-24 21:33:51 -04:00
Adrien Béraud
dfd0a09361
ci/github: add Clang static analysis
2022-03-23 18:32:26 -04:00
Adrien Béraud
0afa40820a
autotools: update m4 for C++17
2022-03-23 17:49:14 -04:00
Adrien Béraud
f984a6a69a
ci/github: update to checkout@v3
2022-03-23 17:25:23 -04:00
Adrien Béraud
b4bbc6ae38
update readme
2022-03-23 15:43:31 -04:00
Adrien Béraud
bc98d974cb
ci: remove travis
2022-03-23 15:43:24 -04:00
Adrien Béraud
785e54838b
docker: fix Bionic (Ubuntu 18.04) support
2022-03-23 15:19:29 -04:00
Adrien Béraud
bb7611fc3d
docker: build with tools, peer discovery
2022-03-23 14:42:02 -04:00
Adrien Béraud
f675a6bdd3
python: adapt for C++17
2022-03-23 14:28:12 -04:00
Adrien Béraud
21a71b1559
proxy server: support c++17
2022-03-23 13:35:30 -04:00
Adrien Béraud
ca5455302d
value: support std::string_view
2022-03-23 13:35:14 -04:00
Adrien Béraud
f206a8ac9e
infohash: support std::string_view
2022-03-23 13:15:37 -04:00
Adrien Béraud
0c4cec66ff
update Dockerfiles, remove Travis
2022-03-23 12:04:26 -04:00
Adrien Béraud
a03124d889
build: use C++17
2022-03-22 17:02:31 -04:00
Adrien Béraud
9691746fde
build: remove OPENDHT_LTO
2022-03-22 17:02:31 -04:00
Adrien Béraud
d7c9311014
update dockerfiles
2022-03-22 17:02:31 -04:00
Adrien Béraud
290e8594b6
update copyright
2022-03-21 11:32:56 -04:00
Adrien Béraud
c59f951e5a
update copyright
2022-03-10 19:51:25 -05:00
Adrien Béraud
6919a34f88
c: add license header
2022-03-10 19:49:53 -05:00
Adrien Béraud
3480bb1098
c: include errno.h
2022-03-10 19:49:00 -05:00
Adrien Béraud
27b8c870f3
c: add dht_privatekey_decrypt, handle crypto exceptions
2022-03-10 19:46:25 -05:00
Adrien Béraud
be43212a73
c: add callback to dht_runner_ping
2022-03-10 19:45:29 -05:00
Adrien Béraud
f0b9bc56a6
c: add dht_runner_is_running, dht_runner_get_bound_port
2022-03-10 19:43:58 -05:00
Adrien Béraud
5654816f5a
dhtrunner: re-throw exception directly in init
2022-03-10 19:43:10 -05:00
Adrien Béraud
b0fb476d97
dhtrunner: pass function argument by value
2022-03-10 19:42:37 -05:00
Adrien Béraud
fada8d067d
c: handle exception during initialization
2022-03-10 19:10:24 -05:00
Adrien Béraud
90022ee3e8
build: update version to 2.3.5
2022-03-09 14:33:25 -05:00
Adrien Béraud
de68a47a16
dhtrunner: handle exception during initialization
2022-03-09 14:32:22 -05:00
Adrien Béraud
714af68292
c: specify void argument for dht_runner_new
2022-03-03 14:44:52 -05:00
Adrien Béraud
e6768edaf0
build: update version to 2.3.4
2022-03-01 19:54:43 -05:00
Adrien Béraud
6145e54543
cmake: update CheckAtomic
2022-02-28 12:37:49 -05:00
Adrien Béraud
ac51c2300e
dht: remove canceled tasks from scheduler
2022-02-27 03:34:36 -05:00
Adrien Béraud
f590980c3e
infohash: include cstddef
2022-02-27 03:34:36 -05:00
Adrien Béraud
5dbade3d0b
value cache: move to lambda
2022-02-26 22:16:15 -05:00
Adrien Béraud
2028d4b13e
build: update version to 2.3.3
2022-02-25 23:52:26 -05:00
Adrien Béraud
a6f7b49b92
build: use msgpack cmake
2022-02-25 23:52:15 -05:00
Adrien Béraud
c2415f38fa
dht: avoid job & search leak
2022-02-24 13:33:42 -05:00
Adrien Béraud
9cf717ab43
tools/c: adapt include directory
2022-02-22 11:49:44 -05:00
Adrien Béraud
d4589bb6f6
tools/c: use new api
2022-02-22 11:49:44 -05:00
Adrien Béraud
484878aec3
c: add missing value apis
2022-02-22 11:49:44 -05:00
Adrien Béraud
ace3a94e08
scheduler: remove debug log
...
This reverts commit 5d771e119c .
2022-02-19 16:32:07 -05:00
Adrien Béraud
5d771e119c
c: install header to opendht directory
2022-02-19 12:33:31 -05:00
Adrien Béraud
8dcc695947
value: cleanup
2022-02-19 10:53:31 -05:00
Adrien Béraud
1ae28e07b6
storage: cleanup
2022-02-19 10:53:31 -05:00
Adrien Béraud
2de0737443
cmake: support some policies
2022-02-19 10:53:31 -05:00
Adrien Béraud
bc32f848cb
thread pool: cleanup
2022-02-19 10:53:31 -05:00
Adrien Béraud
edee6d63d6
build: use msgpack without boost
2022-02-19 10:49:25 -05:00
Adrien Béraud
af3f6f40bb
c: install header
2022-02-19 10:48:28 -05:00
Adrien Béraud
32f72c245d
dht: add max bootstrap period
2022-02-19 09:23:57 -05:00
Adrien Béraud
043ef8da72
dht: reset bootstrap period on connectivity change
...
Also starts a bootstrap if disconnected.
2022-02-19 09:23:57 -05:00
Adrien Béraud
6812b733bb
dht: respect exponential backoff
2022-02-19 09:23:57 -05:00
Adrien Béraud
2ec28dcb83
dhtrunner: use configured logger for dropped packets
2022-02-19 09:23:57 -05:00
Adrien Béraud
db000a2f88
build: update version to 2.3.2
2022-01-26 14:17:57 -05:00
Adrien Béraud
59880df60e
perftest: cleanup
2022-01-26 14:16:33 -05:00
Adrien Béraud
75f1b07e7a
crypto: cleanup
2022-01-26 14:16:33 -05:00
Adrien Béraud
f191c4f636
storage: 0-init size_diff
2022-01-26 14:16:33 -05:00
Sébastien Blin
1b2bc7b1e3
crypto: add parameter to change Certificate's validity period
...
This allow to create certificate with a different validity than
10 years and be able to change the expiration of a certificate
2022-01-19 14:51:45 -05:00
Bruno Pagani
a89e4d626e
tests: fix building with GCC11
...
Fixes `error: ‘sleep_for’ is not a member of ‘std::this_thread’`
2021-11-13 12:31:17 -05:00
Sébastien Blin
dbbfdaab0f
proxyclient: onConnectedCallbacks must be launched if started by notif
2021-10-27 13:45:30 -04:00
Sébastien Blin
536f30ec84
opendht.cpp: fix build
2021-10-22 11:03:12 -04:00
Adrien Béraud
b7aec1310c
crypto: make cachedId mutable
2021-09-16 11:28:59 -04:00
Adrien Béraud
31d76b1080
github: remove argon2 build
2021-09-16 11:19:10 -04:00
Adrien Béraud
2fbafc3591
crypto: cache Certificate Id
2021-09-16 11:08:02 -04:00
Adrien Béraud
19fe34415a
thread pool: fix build on MSVC
2021-09-15 16:45:56 -04:00
Sébastien Blin
2a50f85a30
proxy_server: set expiration for iOS devices
2021-09-10 10:21:31 -04:00
Sébastien Blin
26b71ab993
proxyclient: do not play with stop when resubscribing
...
At this point we do not care for the request. Subscribes are
instantaneous, so the request will be terminated at this point.
Changing the stop status can cause some push notifications to be
dropped if coming at this moment.
2021-09-10 10:21:31 -04:00
Sébastien Blin
04a78445c6
dht_proxy_server: increase ttl for push to 24 hours
...
If the android device is offline during more than 10 minutes, it
can misses push notifications and cause an incorrect state with
values not expired even if the re-subscribe is correct.
2021-09-10 10:21:31 -04:00
Adrien Béraud
fa19897016
HexMap: align on 64 bits
2021-08-09 18:20:12 -04:00
Adrien Béraud
3806355509
gitignore: add DS_Store
2021-08-09 18:20:12 -04:00
Adrien Béraud
3f6738185b
tests: fix testIdOps()
2021-08-05 12:42:29 -04:00
Adrien Béraud
e58d09e5da
dht: always display value ID as hex
2021-08-05 12:42:29 -04:00
heroku-miraheze
71cd9d22c6
Moved to Libera.chat.
2021-07-19 11:25:59 -04:00
Adrien Béraud
6c58d4f2e9
build: update version to 2.3.0
2021-06-09 16:56:19 -04:00
Adrien Béraud
4070eecea7
gitignore: add tools
2021-06-09 16:56:19 -04:00
Adrien Béraud
ffb53ceb1d
thread pool: add ExecutionContext
2021-06-09 13:59:33 -04:00
Adrien Béraud
0c00544798
remove embedded argon2, HTTP_PARSER_FORK
2021-06-09 13:57:10 -04:00
Adrien Béraud
471d443e4a
tests: add multithread test
2021-06-07 14:45:58 -04:00
Adrien Béraud
ba9a445263
securedht: clenup
2021-06-07 14:45:58 -04:00
Adrien Béraud
056bc2850b
test putEncrypted(pk)
2021-06-07 14:45:58 -04:00
Adrien Béraud
b668d6ad68
dhtrunner: add putEncrypted with public key
2021-06-07 14:45:58 -04:00
Adrien Béraud
29fab5560f
dhtrunner: add getPublicKey()
2021-06-07 14:45:58 -04:00
Adrien Béraud
8aef63ce4a
crypto: cache public key
2021-06-07 14:45:58 -04:00
Adrien Béraud
1ea7a2994e
value: use non-const PublicKey
2021-06-07 14:45:58 -04:00
Adrien Béraud
208b3fa6fe
SignedValue: add owner
2021-06-07 14:45:58 -04:00
Adrien Béraud
d9ff95da49
Revert "dhtrunner: force execution of pending ops on shutdown"
...
This reverts commit c8a0b443f3 .
2021-06-07 14:45:58 -04:00
Adrien Béraud
c8a0b443f3
dhtrunner: force execution of pending ops on shutdown
2021-06-03 16:54:31 -04:00
Adrien Béraud
00e595d737
dht: fail if op key is null
2021-06-03 16:54:31 -04:00
Adrien Béraud
a178a8f820
dht, dhtrunner: add shutdown stop argument
2021-05-31 14:43:57 -04:00
Adrien Béraud
ec359d50fb
proxy tester: increase shutdown timeout
2021-05-31 14:43:57 -04:00
Adrien Béraud
3c5aeccd53
dhtrunner: don't read port config if already configured
2021-05-28 13:17:25 -04:00
Adrien Béraud
f99fe16a46
subset: use const ref
2021-05-28 13:17:25 -04:00
Adrien Béraud
43dc7cf222
sockaddr: fix warning
2021-05-28 13:17:25 -04:00
Sébastien Blin
ad549098f8
proxyServer: use lockListener_ to protect pushListeners_
2021-05-25 16:05:03 -04:00
Adrien Béraud
6795ba3838
cmake: fix building with peer discovery and without http
2021-05-20 15:49:11 -04:00
Adrien Béraud
efb5f8e36a
crypto: avoid generating 0 or negative certificate serial numbers
2021-05-15 01:08:07 -04:00
JUAN MÉNDEZ
8aa24f1289
Add python bindings for TypeValue
...
Signed-off-by: JUAN MÉNDEZ <vpsink@gmail.com >
2021-05-10 14:54:16 -04:00
Sébastien Blin
14d882d220
http: add support for TCP keep alive and handle broken pipes
2021-05-03 10:09:31 -04:00
Adrien Béraud
f4c6c54a08
unit tests: add test for identityAnnouncedCb, putEncrypted
2021-04-16 16:11:02 -04:00
Adrien Béraud
4dc7a5ca0a
dhtrunner: log warning if calling run() while already running
2021-04-16 15:54:45 -04:00
Adrien Béraud
40fdd04cb3
dht: cleanup handling of onConnectCallback
2021-04-16 15:13:07 -04:00
Adrien Béraud
a24dedd225
proxy client: move callbacks to lambda
2021-04-16 15:04:19 -04:00
Adrien Béraud
ae2445fd07
proxy client: schedule connectCallbacks in callback queue
2021-04-16 15:01:23 -04:00
Adrien Béraud
7ba53cb4b3
proxy client: use unique_ptr for timers
2021-04-16 15:00:48 -04:00
Adrien Béraud
fbff8389c5
dhtrunner: build proxy with identity callback, logger
2021-04-16 14:45:33 -04:00
Adrien Béraud
827fdacc4b
securedht: build with logger
2021-04-16 14:45:14 -04:00
Adrien Béraud
3efc27e9f3
securedht: avoid use-after-free
2021-04-16 14:42:45 -04:00
Adrien Béraud
f7104199e3
securedht: fix typo
2021-04-15 12:50:31 -04:00
Adrien Béraud
5c0fbf7e68
securedht: pass IdentityAnnouncedCb by value, don't store
2021-04-15 12:47:18 -04:00
Adrien Béraud
55c595330a
securedht: use onConnect callback
2021-04-15 12:36:57 -04:00
Adrien Béraud
d3fc75589f
dht: add onConnect callback
2021-04-15 12:36:03 -04:00
Sébastien Blin
f8605f45f7
securedht: add IdentityAnnouncedCb to detect when identity is announced
2021-04-14 18:55:22 -04:00
Adrien Béraud
d541b17fe1
sockaddr: cleanup
2021-04-13 21:35:31 -04:00
Adrien Béraud
29eb1d97f8
tests: add unit test for Dhtrunner::run(config, context)
2021-04-13 21:35:31 -04:00
Adrien Béraud
623b1c4585
dhtrunner: add async version of getPublicAddress
2021-04-13 21:35:31 -04:00
Adrien Béraud
74f7d7811e
dhtrunner: use default bound address if not set
2021-04-13 21:35:31 -04:00
Adrien Béraud
7774331a20
dhtrunner: allow to provide address to bind in configuration
2021-04-13 21:35:31 -04:00
Sébastien Blin
aae30c5891
docker: update restinio version
2021-04-12 11:55:45 -04:00
Adrien Béraud
41760e4b65
ocsp response: improve exception message
2021-03-25 00:02:51 -04:00
Adrien Béraud
9ca0de250b
tests: add testOcsp
2021-03-24 23:29:53 -04:00
Adrien Béraud
d0156b4637
crypto: add OcspRequest
2021-03-24 23:29:18 -04:00
Adrien Béraud
f6cca88593
ocsp response: verifyDirect now returns revocation status
2021-03-24 23:11:59 -04:00
Adrien Béraud
c6da80573e
ocsp: fix leak
2021-03-24 23:09:24 -04:00
Adrien Béraud
5527869d13
Revert "dht: don't send unnecessary findNode"
...
This reverts commit 0b4caeda73 .
2021-03-22 13:55:04 -04:00
Adrien Béraud
5c599b2feb
ocsp: check the appropriate field for status
2021-03-22 13:54:39 -04:00
Adrien Béraud
122d814a33
TrustRequest: add default empty parameter for conversationId
2021-03-18 17:08:54 -04:00
Adrien Béraud
a1a8adbe4b
update to version 2.2.0
2021-03-18 10:39:59 -04:00
Adrien Béraud
5a370cabb5
crypto: disable legacy encryption
...
Require OpenDHT 2.x to decrypt encrypted data
2021-03-18 10:37:28 -04:00
Adrien Béraud
639ae26ac1
PEMCache: cleanup
2021-03-18 10:35:35 -04:00
Adrien Béraud
896b6de60c
dht: remove default constructor
2021-03-18 10:35:35 -04:00
Adrien Béraud
d025f9d1b5
crypto: add methods to sign/decrypt raw data
2021-03-18 10:35:35 -04:00
Sébastien Blin
0b029bc0bf
types: add conversationId to TrustRequest
2021-03-18 09:13:43 -04:00
Adrien Béraud
2256434ec7
dht: add inspection methods
2021-03-09 17:43:57 -05:00
Adrien Béraud
0b4caeda73
dht: don't send unnecessary findNode
2021-03-09 17:43:35 -05:00
Adrien Béraud
18a1a1c47f
callbacks: move function argument to lambda
2021-03-09 17:43:35 -05:00
Sébastien Blin
6702956521
infohash: add xor operator
2021-03-09 17:27:04 -05:00
Lucas Dias
c996220685
network_engine::process could throw an exception in message type MessageType::ValueUpdate if rsocket does not exist. processMessage called process out of try-catch
2021-01-19 12:55:02 -05:00
Adrien Béraud
df85abfabe
cmake: use THREADS_PREFER_PTHREAD_FLAG
2020-12-30 10:32:27 -05:00
Bruno Pagani
e6c760ec6b
Fix use of OPENDHT_SYSTEMD_UNIT_FILE_LOCATION
...
For some reason 1778f64048 reverted part of 4d70c214b0
This commit fixes that.
2020-12-22 18:03:31 -05:00
Adrien Béraud
a77dc855f0
OCSP: use RFC-mandated parameters
...
* use 32 bytes nounce
* use SHA-1 for the certificate ID
2020-12-17 12:35:33 -05:00
Adrien Béraud
2524e167d9
tests: add test for toHex
2020-12-08 14:39:25 -05:00
Adrien Béraud
638d1c91f1
toHex: use proper std::string constructor
2020-12-08 14:34:33 -05:00
Amin Bandali
ba4058dfd9
cmake: fix atomic check, hopefully
2020-12-04 16:55:03 -05:00
Adrien Béraud
ab90a170af
http: checkOcsp is void
2020-11-24 16:16:11 -05:00
Adrien Béraud
f780499241
ocsp response: add string constructor
2020-11-24 16:11:02 -05:00
Adrien Béraud
91709bc999
proxytester: disable https for now
2020-11-24 15:59:42 -05:00
Adrien Béraud
72725dc5c1
http: make OCSP check optional
2020-11-24 15:34:19 -05:00
Adrien Béraud
3098439db2
proxy client: set CA for every request
2020-11-24 15:22:14 -05:00
Adrien Béraud
6441a09e09
ocsp: fix memleaks
2020-11-20 14:42:55 -05:00
Adrien Béraud
57e7699723
update to version 2.1.9
2020-11-20 11:39:01 -05:00
Adrien Béraud
17e1cfbbbe
crypto: export OCSP request as string
2020-11-20 11:38:11 -05:00
Adrien Béraud
bfe1311ca8
crypto: cleanup OCSP result check
2020-11-19 17:12:54 -05:00
Adrien Béraud
537a1650f2
infohash: add toHex(const std::string&)
2020-11-19 17:07:06 -05:00
Kateryna Kostiuk
8c852c20e7
os_cert: do not load for iOS
2020-11-18 15:47:10 -05:00
Adrien Béraud
1da46382d3
cmake: add missing include in CheckAtomic
2020-11-17 16:30:36 -05:00
Adrien Béraud
4953888af3
update to version 2.1.8
2020-11-17 16:24:30 -05:00
Adrien Béraud
22de868c6c
cmake: check for 64 bits atomic support
2020-11-17 16:23:43 -05:00
Adrien Béraud
0998707e03
automake: add os_cert
2020-11-17 15:48:13 -05:00
Adrien Béraud
b5fcd49b7b
os_cert: only build with http
2020-11-17 15:20:46 -05:00
Adrien Béraud
81cdd9650b
os_cert: cleanup
2020-11-17 14:37:03 -05:00
Adrien Béraud
e028cea687
os_cert: only define timegm on Windows
2020-11-17 13:15:22 -05:00
Adrien Béraud
17ed4a9e26
os_cert: include crypto/x509 from OpenSSL 3.0
2020-11-17 12:27:41 -05:00
Adrien Béraud
3ff318b9e4
os_cert: cleanup detection of ASN1_time_parse
2020-11-17 11:35:07 -05:00
Adrien Béraud
0c11c25c66
infohash: make toHex inline
2020-11-17 11:34:40 -05:00
Adrien Béraud
0d31139402
crypto: throw in case of certificate generation error
2020-11-16 17:35:00 -05:00
Adrien Béraud
e970cac4d7
infohash: expose toHex
2020-11-16 14:58:35 -05:00
Adrien Béraud
7c8eecd745
update to version 2.1.7
2020-11-15 17:25:12 -05:00
Adrien Béraud
4d87c2267b
os_cert: build ASN1_time_parse if not libressl
2020-11-15 00:42:29 -05:00
Adrien Béraud
88b2439deb
http: use string for body, fix log arguments
2020-11-14 18:07:05 -05:00
Federico Ceratto
766a06c69a
Remove line
2020-11-13 09:33:11 -05:00
Federico Ceratto
aa502553bb
Put @bindir@ back
2020-11-13 09:33:11 -05:00
Federico Ceratto
05ff4205d2
Configure dhtnode service sandboxing
...
Tested on Debian Sid
2020-11-13 09:33:11 -05:00
Adrien Béraud
9d937bb277
http: factor setting CA source
2020-11-12 19:00:02 -05:00
Andreas Traczyk
1621515b3c
http: use local cache to store pre-decoded certs
...
- pre-decode certs from DER->PEM and store them so http connections
can add them the ssl context x509 store
- fixes the windows build by adding the crypto/x509 header
2020-11-12 18:58:18 -05:00
Adrien Béraud
30261e70ad
cache: cleanup, small perf improvements
2020-11-12 12:53:57 -05:00
Adrien Béraud
c2a4f667a7
http: look for CA path in env
2020-11-12 12:53:03 -05:00
Adrien Béraud
05b95331d8
cmake: add CheckAtomic
2020-11-04 16:24:52 -05:00
Kateryna Kostiuk
c986f44704
http: fix linking on macOS
2020-10-29 14:04:45 -04:00
Adrien Béraud
7f62073d93
cmake: add proper ssl build/link flags
2020-10-28 16:51:37 -04:00
Adrien Béraud
1a562962ba
cmake: look for asio
2020-10-28 14:49:54 -04:00
Adrien Béraud
065be0621d
ssl: fix build on non-MSVC platforms
2020-10-28 14:06:08 -04:00
Andreas Traczyk
6c085ed975
http: load ca certs from platform specific stores into x509 store
2020-10-28 12:23:53 -04:00
Adrien Béraud
4c5776f9d2
http: add support for OCSP verification
2020-10-28 12:23:53 -04:00
Adrien Béraud
c84fac6823
http: add Request::await
2020-10-28 12:23:53 -04:00
Andreas Traczyk
1778f64048
cmake: remove vcxproj files and use cmake on windows
2020-10-20 13:04:26 -04:00
Sébastien Blin
d1000635dd
dht_proxy_client: do not launch loopSignal_ while searchLock_ is locked
2020-10-08 18:34:21 -04:00
Adrien Béraud
1273b062e1
update to version 2.1.6
2020-09-24 17:09:10 -04:00
Adrien Béraud
961b96ca3d
update to version 2.1.5
2020-09-23 15:00:48 -04:00
Adrien Béraud
bcb29c3588
build/cmake: support new pkgconfig macros
2020-09-23 14:45:04 -04:00
Sébastien Blin
5d9395b16f
stats: use /node/stats
2020-09-18 10:40:12 -04:00
Sébastien Blin
23a75a3f50
proxyclient: do not lock loopSignal_
2020-09-15 10:54:44 -04:00
Adrien Béraud
7b87d32c0a
python scanner: update for new APIs
2020-09-01 17:33:08 -04:00
Adrien Béraud
d5f4f81566
http tester: adapt to API changes
2020-09-01 16:26:52 -04:00
Adrien Béraud
a69863da4e
search: avoid comparing invalidated iterators
2020-09-01 15:55:43 -04:00
Doron Behar
4d70c214b0
Enable to configure systemd unit installation dir
2020-08-22 10:24:37 -04:00
Doron Behar
11afc2b468
Enable to disable network tests
2020-08-02 11:32:28 -04:00
Adrien Béraud
879e4f4e02
tests/http: update for new API
2020-07-06 10:37:20 -04:00
Adrien Béraud
b5b4eea253
dht: reschedule search step
2020-07-06 10:26:08 -04:00
Adrien Béraud
67adc09d52
http: add non-Linux exception for current libressl limitation
2020-07-03 16:33:12 -04:00
Adrien Béraud
e2b39dd3a0
http/request: make terminate public
2020-06-30 10:42:49 -04:00
Adrien Béraud
9dc0ce7392
http: cleanup
2020-06-29 23:06:42 -04:00
Adrien Béraud
1a025c5cea
http: log peer subject name during TLS certificate verification
2020-06-29 20:52:53 -04:00
Adrien Béraud
732e9af439
http: set SNI when using TLS
2020-06-29 19:17:16 -04:00
Adrien Béraud
4e5666fc3a
http: add verify path for Android
2020-06-29 19:17:16 -04:00
Sébastien Blin
b41f5b04f5
proxyclient: only restart listeners when connected
...
restartListeners() must be called only when the proxy is connected. Else, the
client will receive a lot of http errors
2020-06-29 15:18:58 -04:00
Adrien Béraud
cfa21df8b3
http: cleanup, always verify host in TLS mode
2020-06-29 12:12:22 -04:00
Adrien Béraud
6ac451a5de
update to version 2.1.4
2020-06-19 15:45:26 -04:00
Adrien Béraud
9efb8bb662
dockerfile: build with proxy
2020-06-19 15:44:47 -04:00
Adrien Béraud
f0aee6f909
docker: update restinio
2020-06-19 15:44:35 -04:00
Adrien Béraud
f72bfc9df2
http: use hostname for certificate authentication
2020-06-19 15:21:34 -04:00
Adrien Béraud
c9ebfd1119
tests: cleanup
2020-06-15 18:33:04 -04:00
Adrien Béraud
cf1874baaa
crypto: free token before return
2020-06-15 18:25:23 -04:00
Adrien Béraud
c221cfdafe
http/Request: add get json constructor
2020-06-15 17:47:32 -04:00
Adrien Béraud
31b84e6d92
thread pool: unlock after notify
2020-06-15 17:47:32 -04:00
Adrien Béraud
ae05bc8ea5
crypto: avoid goto
2020-06-15 17:47:32 -04:00
Seva
acbf7cfcf0
crypto: cleanup ocsp api & tests
2020-06-15 17:47:32 -04:00
Seva
8250116946
crypto: embed ocsp response into class
2020-06-15 17:47:32 -04:00
Seva
45e9458373
crypto: add get ocsp response in readable format
2020-06-15 17:47:32 -04:00
Seva
2623b86274
crypto/cert: add generate ocsp request & verify response
2020-06-15 17:47:32 -04:00
Seva
2e1dda8189
crypto: enable test certificate serial number
2020-06-15 17:47:32 -04:00
Seva
e26256b819
crypto: add get ocsp response certificate status
2020-06-15 17:47:32 -04:00
Seva
18e59ad7c8
crypto: test certificate serial number
2020-06-15 17:47:32 -04:00
Seva
a7a3d23f50
crypto: add get serial number of cert.
2020-06-15 17:47:32 -04:00
Adrien Béraud
323a2b5093
dht: move socket to SearchNode
2020-06-15 17:46:43 -04:00
Adrien Béraud
563811ebf8
dht: add error handler for sendRefreshValue
2020-06-15 17:46:43 -04:00
Adrien Béraud
190c7f2063
network engine: complete request in case of error
2020-06-15 17:46:43 -04:00
Adrien Béraud
6158751a32
network engine: auth success in case of refresh
2020-06-12 02:51:08 -04:00
Adrien Béraud
4c7d126782
network engine: fix sendError with non-default netId
2020-06-11 15:10:48 -04:00
Sébastien Blin
3e24ea1212
rng.h: fix build
2020-05-25 18:50:35 -04:00
Adrien Béraud
a7ac979da6
update to version 2.1.3
2020-05-25 15:18:51 -04:00
Adrien Béraud
87f48f0a28
getSeededRandomEngine: retry in case of exception
2020-05-25 15:18:51 -04:00
Adrien Béraud
15586a3cb1
travis: update configuration
2020-05-24 14:24:30 -04:00
Adrien Béraud
2195c0ed3e
proxy server: allow build without push notification support
2020-05-24 14:11:13 -04:00
Adrien Béraud
af1e904895
dockerfile: add pkg-config
2020-05-24 11:52:56 -04:00
Adrien Béraud
a4fbf7ced0
docker: update
2020-05-24 02:04:45 -04:00
Adrien Béraud
1b7e0679d5
proxy server: check push token when loading state
2020-05-24 02:04:45 -04:00
Sébastien Blin
9292c1116c
proxy: count permanent put values by hash in stats
2020-05-24 01:25:31 -04:00
Adrien Béraud
a2afb5bb31
network engine: send confirmation for value update
2020-05-24 00:20:27 -04:00
Adrien Béraud
15fbfdebcc
dht: only load id if set in configuration
2020-05-22 12:28:25 -04:00
Adrien Béraud
15eb221cd1
dht: save id, port when saving state
2020-05-22 12:15:10 -04:00
Adrien Béraud
7d3781acc8
dht: use pseudo-rng for ID generation
2020-05-22 12:14:47 -04:00
Sébastien Blin
f3100a6752
proxyclient: avoid to generate tokens with \0
2020-05-20 12:23:59 -04:00
Adrien Béraud
e3cd2a9d02
proxy server: add missing listener type
2020-05-19 19:52:51 -04:00
Adrien Béraud
19ccc3a327
proxy server: restart timers on resubscribe
2020-05-19 19:50:20 -04:00
Adrien Béraud
4587c0925f
utils: always check length in findMapValue
2020-05-19 19:50:20 -04:00
Adrien Béraud
fc96245891
cmake: cleanup
2020-05-19 19:50:20 -04:00
Adrien Béraud
a27815b4a9
proxy server: persist ops on disk
2020-05-19 19:50:20 -04:00
Adrien Béraud
5daaf372b4
proxyserver: generate id before put
2020-05-11 12:31:07 -04:00
Sébastien Blin
cc51d2684c
proxy: only keep last total stat
...
The rest is not needed.
2020-05-05 17:00:07 -04:00
Sébastien Blin
28b5893239
listener: fully migrate to requests
...
This patch migrates tellListenerRefreshed and tellListenerExpired
to the new behavior
2020-05-05 10:38:03 -04:00
Adrien Béraud
c754b5cfce
update to version 2.1.0
2020-04-30 14:58:25 -04:00
Adrien Béraud
b0c1249710
network engine: check for logger
2020-04-29 20:23:19 -04:00
Adrien Béraud
c41ee417fb
tools: cleanup
2020-04-29 19:22:24 -04:00
Adrien Béraud
47ba0415ca
tools: use bootstrap split/default port from dht
2020-04-29 17:12:11 -04:00
Adrien Béraud
99857e25cc
dhtnode: use async version of getNodeInfo
2020-04-29 16:13:36 -04:00
Adrien Béraud
7f832ba9d5
NodeInfo: add bound ports
2020-04-29 16:00:02 -04:00
Sébastien Blin
8c4a894f93
misc: replace TransId to Tid
2020-04-28 13:55:29 -04:00
Sébastien Blin
dd3de412fb
dht: move updateValues logic into network_engine
2020-04-28 13:55:29 -04:00
Sébastien Blin
4ad5e6c9ba
misc: clean
2020-04-28 13:55:29 -04:00
Sébastien Blin
b445818521
tests: enable test for listening with lot of values
2020-04-28 13:55:29 -04:00
Sébastien Blin
7c14ea1730
network_engine: fix pack for sendUpdateValues
2020-04-28 13:55:29 -04:00
Sébastien Blin
7bf9f861a5
dht: send update values for listeners
2020-04-28 13:55:29 -04:00
Sébastien Blin
4cf5c87761
network_engin: move to pack(socket)
2020-04-28 13:55:29 -04:00
Sébastien Blin
e1c6fec581
dht: starts to add update and version support
2020-04-28 13:55:29 -04:00
Sébastien Blin
31da5b91fa
[WIP]net: add updateValues to replace Listen operations
...
Actually, packets are not retransmitted for listen operations. This
leads to some problems when they are already several values present
at one hash. Ideally, packets should be transmitted inside a request
to avoid packet loss and get all datas.
This patch breaks the compatibility with previous versions
2020-04-28 13:55:29 -04:00
Adrien Béraud
01bcb1a750
network engine: completely remove TransId
2020-04-24 18:46:46 -04:00
Adrien Béraud
35348bf77f
dht: use default port for bootstraping
2020-04-24 17:45:40 -04:00
Adrien Béraud
ae58ea8312
search: expire only after candidate expiration
2020-04-24 16:32:07 -04:00
Adrien Béraud
f30d21e96f
move bootstrap logic from DhtRunner to Dht
2020-04-24 16:32:07 -04:00
Vladimir Stoiakin
7628aab230
opendht.pc: change -lpthread to -pthread
2020-04-19 14:13:56 -04:00
Adrien Béraud
f4cba56b3c
dht: optimize getStatus()
2020-04-17 02:09:57 -04:00
Adrien Béraud
7155dc4fb7
stats: add search, cached node count
2020-04-16 02:08:00 -04:00
Adrien Béraud
c961e2e99f
dht: allow to configure max searches & store size
2020-04-16 02:08:00 -04:00
Adrien Béraud
2fb8e1c7ee
Update README.md
2020-04-12 15:56:23 -04:00
Vladimir Stoiakin
4d689ef51a
update opendht.pc
2020-04-10 09:24:31 -04:00
Adrien Béraud
face9f12b2
request: cleanup
2020-03-30 18:39:28 -04:00
Adrien Béraud
c92f553a24
network engine: retransmit value parts
2020-03-30 17:54:50 -04:00
Adrien Béraud
8564cf3b86
tests/dhtrunner: test put/listen for large values
2020-03-30 17:54:47 -04:00
Adrien Béraud
e7c810d5d6
value: don't print large values
2020-03-30 17:54:42 -04:00
Adrien Béraud
e76c80b8be
tests: disable rate limiting
2020-03-30 17:54:34 -04:00
Adrien Béraud
69f8969883
utils: fix build in 32 bit
2020-03-25 23:39:54 -04:00
Adrien Béraud
bc200cd76d
utils: fix indentation
2020-03-25 23:08:39 -04:00
Adrien Béraud
187c7dbce3
http: preserve headers during redirect
2020-03-25 23:00:16 -04:00
Adrien Béraud
81131f1c4e
utils: check time bounds
2020-03-25 23:00:16 -04:00
Adrien Béraud
ce9445a93f
pseudo-rng: improve fallback seed
2020-03-25 23:00:16 -04:00
Adrien Béraud
16372cba0c
Update README.md
2020-03-21 12:45:11 -04:00
Adrien Béraud
a2cbef315a
dht: avoid crash in persistent put when logging
2020-02-22 19:59:36 -05:00
Adrien Béraud
bc7c43dfd1
value: cleanup
2020-02-22 19:59:36 -05:00
Adrien Béraud
771b300622
durl: cleanup, fix on macOS
2020-02-22 19:59:36 -05:00
Adrien Béraud
5ffb5c628d
dht: avoid use-after-free when sending probe query
2020-02-14 13:52:55 -05:00
Adrien Béraud
cfa4ce61b4
cmake: add option to build http without proxy
2020-02-13 16:55:59 -05:00
Adrien Béraud
5f15043f03
tools: add durl for http client testing
2020-02-12 16:46:06 -05:00
Adrien Béraud
f445b2536d
http: handle redirects
2020-02-12 16:45:25 -05:00
Adrien Béraud
6c2f791c4d
network utils: don't block on mutex in rx thread (2)
2020-02-11 17:07:53 -05:00
Adrien Béraud
780726c66d
network utils: don't block on mutex in rx thread
2020-02-11 16:20:30 -05:00
Adrien Béraud
8703cfdaee
dht: erase announce form search nodes on cancelPut
2020-02-09 15:15:47 -05:00
Adrien Béraud
1c536cbf5e
permanent put: set clientId
2020-02-09 10:34:42 -05:00
Adrien Béraud
a39e2443a0
dht: reuse probe query, avoid leak
2020-02-09 00:51:58 -05:00
Adrien Béraud
57528e7aab
scheduler: don't sync time on run
2020-02-08 22:04:50 -05:00
Adrien Béraud
e9d70f204a
tools: add perftest
2020-02-08 22:04:41 -05:00
Adrien Béraud
ceb35c05c1
securedht: add option to disable cache
2020-02-08 20:27:44 -05:00
Adrien Béraud
55ccec5871
securedht: putEncrypted, putSigned fail if no key
2020-02-07 00:54:18 -05:00
Adrien Béraud
95028e3770
dht: always use pseudo-RNG for non-critical random numbers
2020-02-07 00:36:42 -05:00
Adrien Béraud
abede1e72a
pingpong: print execution time
2020-02-07 00:21:13 -05:00
Adrien Béraud
859d8dc9cf
proxy server: check clientId for merging put
2020-02-07 00:21:13 -05:00
Sébastien Blin
1a67140463
proxyserver: enable keep alive packets
2020-02-06 14:15:47 -05:00
Adrien Béraud
9ae3d3c4d4
proxy: move info if possible
2020-02-05 14:25:03 -05:00
Adrien Béraud
d3508c80f5
dhtrunner: take bound address by reference
2020-02-04 16:21:24 -05:00
Adrien Béraud
6c43efa4da
http: use proper target in requests
2020-02-04 16:21:24 -05:00
Sébastien Blin
c5c4c217dd
tools: add script for following dhtproxy's stats
2020-01-28 16:27:20 -05:00
Sébastien Blin
5cfcf4861d
proxyserver: set permanent put pushToken
2020-01-28 16:27:20 -05:00
Adrien Béraud
8597267c63
dht: add 'public stable' node configuration
2020-01-27 16:27:21 -05:00
Adrien Béraud
1b81d707f3
value: fix potential crash in contentEquals
2020-01-27 12:13:17 -05:00
Adrien Béraud
7791163d49
proxy: receive values in blocks
2020-01-22 16:02:26 -05:00
Adrien Béraud
56db1bba19
proxy server: merge identical put requests
2020-01-22 15:56:48 -05:00
Adrien Béraud
a7092c2dc7
dhtnode: show value id in put response
2020-01-22 13:15:37 -05:00
Adrien Béraud
fc95c85983
proxy server: send values in batches
2020-01-22 13:15:37 -05:00
Adrien Béraud
3490b19fe3
proxy client: cleanup
2020-01-22 13:15:37 -05:00
Adrien Béraud
4a20814d59
proxy client: let the server choose the value id
2020-01-22 13:15:37 -05:00
Adrien Béraud
707fb39975
net: fix sending query in sendGetValues
2020-01-20 12:15:33 -05:00
Adrien Béraud
cbb2406a12
utils: improve duration display
2020-01-19 17:47:54 -05:00
Adrien Béraud
7764620460
proxy client: fix warning
2020-01-19 14:32:57 -05:00
Adrien Béraud
5af0f0c3d0
proxy server: flush response after all values are sent
2020-01-19 14:32:57 -05:00
Adrien Béraud
ec8beec427
proxy server: update stats on startup
2020-01-19 14:32:57 -05:00
Adrien Béraud
7b8ebbc54d
proxy server: catch more exceptions, cleanup
2020-01-19 14:32:57 -05:00
Adrien Béraud
dc46c2274c
net: exponential backoff, randomize packet expiration time
2020-01-19 14:32:57 -05:00
Adrien Béraud
052ed1f58c
proxy server: handlePrintStats on startup
2020-01-18 22:20:01 -05:00
Adrien Béraud
9096f650f5
dht: increase default max request rate to 8k req/s
2020-01-18 19:54:54 -05:00
Adrien Béraud
900655b11f
dht: give current time through periodic
2020-01-18 13:58:22 -05:00
Adrien Béraud
2900b1d17f
net: limit recycled packet queue max size
2020-01-18 13:56:50 -05:00
Adrien Béraud
69e71dbeaa
SecureDht: cleanup
2020-01-17 15:58:22 -05:00
Adrien Béraud
3793423b2f
dht: log cleanup
2020-01-17 15:57:32 -05:00
Adrien Béraud
b012878488
dhtrunner: set logger in setLogger
2020-01-17 15:57:32 -05:00
Adrien Béraud
c1005fa334
request: free message memory on clear
2020-01-17 15:17:35 -05:00
Adrien Béraud
0f9f623b31
dht: use unique_ptr for SearchNode
2020-01-17 12:47:14 -05:00
Adrien Béraud
2cfebdf9fa
net: use packet lists and recycle old packet structures
2020-01-17 12:26:03 -05:00
Adrien Béraud
481b1cb3b4
dht: use pseudo-random generator for value ids
2020-01-16 13:51:51 -05:00
Adrien Béraud
7f1d960a56
dhtrunner: add async/non-blocking version of getNodeInfo
2020-01-16 13:24:37 -05:00
Adrien Béraud
91e1e942ab
Update peer_discovery.cpp
2020-01-15 23:16:36 -05:00
Adrien Béraud
ae89365f23
Update peer_discovery.cpp
2020-01-15 23:16:36 -05:00
Adrien Béraud
93cd8d541c
Update peer_discovery.cpp
2020-01-15 23:16:36 -05:00
Paymon
9487bc5e42
implement connectivity change in peer discovery
...
this makes peer discovery pub/sub on connectivity change, it aims to
make peer discovery more energy efficient.
also, stop echo'ing.
TODO:
in its current implementation however, peer_discovery operates in the
dark; it doesn't know routes available to it (v4 vs v6); nor does it
know of the state of the link(s) (UP vs. DOWN) and therefore it merely
tries to, on connectivity change, (re)pub/sub on previous ip version
routes.
IDEA:
open an interface to kernel so that peer discovery, and perhaps others,
can learn about the routes available to them.
don't leave
add query() and direct publish(endpoint)
check if peer discovery was request (run and compile time)
add try/catch routine to DomainPeerDiscovery's constructor
2020-01-15 23:16:36 -05:00
Adrien Béraud
10d48137a9
proxy server: update stats on node info
2020-01-15 17:04:12 -05:00
Adrien Béraud
5b15fdeeef
proxy server: use shared_ptr for stats, remove statsMutex_
2020-01-15 13:54:24 -05:00
Adrien Béraud
3ba43c80a2
http: add weak_ptr to Request in Response
2020-01-15 11:45:26 -05:00
Adrien Béraud
16333f4224
http: add mutex to Request, Connection
2020-01-15 11:45:03 -05:00
Adrien Béraud
0864ac9a39
proxy server: handle put session id provided after first request
2020-01-10 12:26:57 -05:00
Adrien Béraud
616d6fe4b8
update copyright date
2020-01-03 15:14:32 -05:00
Adrien Béraud
dea4b202bf
proxy server: make json type explicit
2020-01-03 15:10:22 -05:00
Adrien Béraud
dc2f354652
proxy: use timestamps to handle reordered notifications
2020-01-03 14:47:22 -05:00
Sébastien Blin
87041e301f
proxyclient: refresh put on restartListeners
...
There is no need to check if the put is ok or not before refreshing it. Indeed,
the first successful put will make the ok flag to true. But, if an expiration
is missed (when not connected for example), the put will not be refreshed when
the connectivity will change (moreover, server and client can have different
timeouts).
2020-01-03 11:39:05 -05:00
Sébastien Blin
189f94442e
dhtproxyclient: setPushNotification before first permanent put
...
When SecureDHT is initialized, a permanent put is done to announce the node
and then the push token is set. This means the the first permanent put will not
get expirations notification because it's considered as a non push device's put.
We should inject the push token as soon as possible.
2020-01-03 11:39:05 -05:00
Adrien Béraud
c5c3695612
logger: use shared_ptr
2019-12-19 15:12:23 -05:00
Adrien Béraud
6a7ad871e2
value: toString prints raw data if text/plain
2019-12-19 15:12:23 -05:00
Adrien Béraud
99890fca64
proxy server: update sessionId when necessary
2019-12-19 14:20:03 -05:00
Adrien Béraud
2dbf57d36b
Update README.md
2019-12-16 23:42:31 -05:00
Adrien Béraud
5438d50578
proxy: add session token
2019-12-16 16:37:07 -05:00
Adrien Béraud
548255073f
docker: build c bindings, use asio 1.12
2019-12-16 12:22:05 -05:00
Adrien Béraud
abaf091772
c binding: fix build
2019-12-16 11:41:49 -05:00
Adrien Béraud
7094b79714
crypto: add PublicKey::pack(uint8_t* out, size_t* out_len)
2019-12-14 15:29:42 -05:00
Adrien Béraud
1f672773ba
proxy server: respect value priority for push notifications
2019-12-14 13:02:07 -05:00
Adrien Béraud
374fdd6cc9
proxy: send normal priority push message for value expiration
2019-12-14 13:02:07 -05:00
Adrien Béraud
54b1314ab8
value: optimize json parsing
2019-12-14 13:02:07 -05:00
Adrien Béraud
51c35d8b54
value: add priority
2019-12-14 13:02:07 -05:00
Adrien Béraud
fea736428e
msgpack: take const reference in unpack
2019-12-14 13:01:24 -05:00
Adrien Béraud
2d358adf0e
utils: add findMapValue(string)
2019-12-14 13:00:13 -05:00
Adrien Béraud
26c2e16a42
value: optimize json parsing
2019-12-14 00:41:41 -05:00
Adrien Béraud
e8b385c220
utils: optimize findMapValue
2019-12-13 23:57:22 -05:00
Adrien Béraud
c1e2a368a8
docker: add ssl, install http-parser to /usr
2019-12-13 16:24:46 -05:00
Adrien Béraud
c62f27c929
tools: add missing include
2019-12-12 17:00:35 -05:00
Adrien Béraud
ec0c3d4d25
docker: build asio without tests and examples
2019-12-12 15:04:45 -05:00
Adrien Béraud
17a1178054
tools: add missing includes for indexation support
2019-12-12 15:00:17 -05:00
Adrien Béraud
6256c576c9
configure: cleanup
2019-12-12 14:51:59 -05:00
Adrien Béraud
9565adf693
proxy server: always depend on jsoncpp
2019-12-12 14:51:59 -05:00
Adrien Béraud
c10aa32596
cpp: include config.h when necessary
2019-12-12 14:51:59 -05:00
Adrien Béraud
21c294f352
docker: update asio
2019-12-12 14:51:59 -05:00
Adrien Béraud
4654f78e08
autotools: allow to build without peer discovery
2019-12-12 14:51:59 -05:00
Adrien Béraud
38644fc934
includes: don't include proxy server, pht by default
2019-12-12 14:44:53 -05:00
Adrien Béraud
fa8dc4c835
callbacks: add missing header
2019-12-12 14:33:00 -05:00
Adrien Béraud
6dab10cac2
github: disable tests and examples when building asio
2019-12-12 12:24:56 -05:00
Adrien Béraud
77a1c27f2b
github: build asio
2019-12-12 11:52:43 -05:00
Adrien Béraud
e8577bfd05
dhtrunner: fix build without peer discovery
2019-12-12 11:42:06 -05:00
Adrien Béraud
c0327a9881
dhtrunner: fix build without peer discovery
2019-12-11 11:43:20 -05:00
Adrien Béraud
2a1eacc949
tests: only link with ssl if required
2019-12-09 16:23:15 -05:00
Adrien Béraud
e705bebc25
github: don't build proxy
2019-12-09 16:06:39 -05:00
Adrien Béraud
a330762f40
build: always use standalone asio
2019-12-09 15:40:48 -05:00
Adrien Béraud
e7972ae897
dockerfiles: update
2019-12-09 15:34:26 -05:00
Adrien Béraud
8d2d40cb7f
peer discovery: simplify includes
2019-12-09 14:53:27 -05:00
Adrien Béraud
aceb548c26
cmake: make peer discovery build optional
2019-12-09 14:43:04 -05:00
Adrien Béraud
afce4639e1
tests/peerdiscover: add missing includes
2019-12-09 14:07:42 -05:00
Adrien Béraud
e5d248bcd0
peer discovery: use asio
2019-12-09 03:28:45 -05:00
Adrien Béraud
0fbebf8e03
http: cleanup, fix handling error when no logger is set
2019-12-08 10:48:34 -05:00
Adrien Béraud
24efa37846
http: cleanup
2019-12-08 00:25:21 -05:00
Linas Vepstas
c0f14ca59d
Fix duplicated, non-functional log message.
...
Inside the if-statement, the log message will always print zero.
Confusingly, its the same message as the one in the loop above it.
Make the message distinct.
2019-12-07 22:28:35 -05:00
Adrien Béraud
05a66cc1f1
proxy client: use common jsonReader
2019-12-07 22:22:37 -05:00
Adrien Béraud
ed6df8869c
proxy: don't use keep-alive by default
2019-12-07 22:22:37 -05:00
Adrien Béraud
b7d410e1aa
tests: add http tester
2019-12-07 16:23:08 -05:00
Adrien Béraud
77a377a406
http: add OnDone callback
2019-12-07 16:23:08 -05:00
Adrien Béraud
e0b6f152f1
proxy client: add LineSplitter
2019-12-07 16:23:08 -05:00
Adrien Béraud
dd3c789916
proxy server: 0-initialize fields
2019-12-07 16:23:08 -05:00
Adrien Béraud
333087bcba
dhtrunner: fix getNodeInfo using proxy client
2019-12-07 16:23:08 -05:00
Adrien Béraud
5b87090cab
http: use http_parser parsing logic
2019-12-07 16:23:08 -05:00
Adrien Béraud
fffee634f1
proxy client: avoid destroying twice
2019-12-05 18:39:39 -05:00
Adrien Béraud
c4aa272dbb
http/request: add constructor
2019-12-05 18:39:39 -05:00
Adrien Béraud
4ce78bdb4d
c wrapper: link statically when required
2019-12-05 18:35:43 -05:00
Adrien Béraud
f331f39c77
c wrapper: add dht_privatekey_export
2019-12-05 18:35:43 -05:00
Adrien Béraud
17fb92654e
http: check parser before use
2019-12-03 16:45:19 -05:00
Adrien Béraud
294034f00f
proxy client: don't report connectivity failure for aborted requests
2019-12-03 16:21:33 -05:00
Adrien Béraud
36857c1f3d
http/request: add aborted flag and actual status code
2019-12-03 16:21:04 -05:00
Adrien Béraud
7e9f5303bd
github: don't run distcheck
2019-12-02 01:30:56 -05:00
Adrien Béraud
c2780b1ca9
build/autoconf: always build python Makefile
2019-12-02 01:15:38 -05:00
Adrien Béraud
16b798324d
github: disable python
2019-12-02 00:53:27 -05:00
Adrien Béraud
bc850bf00c
build/autotools: use proper path for tools build include
2019-12-02 00:30:37 -05:00
Adrien Béraud
0d8d302128
update argon2
2019-12-02 00:11:08 -05:00
Adrien Béraud
97013badfa
github: install argon2 before configure
2019-12-02 00:06:49 -05:00
Adrien Béraud
31185c24f0
build/autoconf: always build doc Makefile
2019-12-01 23:49:04 -05:00
Adrien Béraud
2f6f8e2ac1
cmake/tools: link with readline dependenciess
2019-12-01 22:46:41 -05:00
zhengfish
8f141951ce
fixed a compiling error in openwrt-18.04.5
...
Signed-off-by: zhengfish <zhengfish@gmail.com >
2019-12-01 22:41:29 -05:00
zhengfish
43d111b7dc
fixed a linking error in openwrt-18.06: undefined reference to 'tgetnum'
...
Signed-off-by: zhengfish <zhengfish@gmail.com >
2019-12-01 22:41:29 -05:00
Adrien Béraud
620ba2a89b
proxy server: fix warning
2019-12-01 21:01:42 -05:00
Adrien Béraud
d1598380db
proxy server: fix build without push notifications
2019-12-01 21:00:27 -05:00
Adrien Béraud
69fe399db0
proxy server: cancelListen on destroy
2019-12-01 20:54:48 -05:00
Adrien Béraud
a60dde2e13
tests: use shutdown
2019-12-01 19:41:02 -05:00
Adrien Béraud
201982b1a9
dhtrunner: don't count cancel as ops
2019-12-01 19:40:44 -05:00
Adrien Béraud
83f2b272a7
dhtrunner: add ongoing op count to node info
2019-12-01 15:07:35 -05:00
Adrien Béraud
7e47d0458a
tests/proxy: cleanup
2019-12-01 14:53:50 -05:00
Adrien Béraud
f6d26757fa
dhtrunner: wait for current ops to complete on shutdown
2019-12-01 14:53:36 -05:00
Adrien Béraud
476d0bca4f
proxy client: lock while canceling requests
2019-12-01 14:52:42 -05:00
Adrien Béraud
259986e786
network engine: don't throw in case of unknown transaction
2019-12-01 14:52:21 -05:00
Adrien Béraud
8ff0c979d4
proxy server: cleanup
2019-11-30 20:36:20 -05:00
Adrien Béraud
913cb543c8
crypto: improve exception types
2019-11-30 19:42:02 -05:00
Adrien Béraud
b380c9ffba
http: cleanup
2019-11-30 18:47:29 -05:00
Adrien Béraud
8c717085b4
cmake: cleanup
2019-11-30 18:11:00 -05:00
Adrien Béraud
48742a1058
tests: fix catching exception
2019-11-30 18:11:00 -05:00
Adrien Béraud
fe11285a03
http: close on request end with Connection: close, cleanup
2019-11-30 18:11:00 -05:00
Adrien Béraud
fb34770a54
http: reuse connection istream, cleanup
2019-11-30 17:21:52 -05:00
Adrien Béraud
4a909419e9
http: handle Request lifetime when sharing resolver/connection
2019-11-30 17:21:52 -05:00
Adrien Béraud
dab7099369
proxy server: cleanup
2019-11-28 22:16:22 -05:00
Adrien Béraud
9c84e59bbf
autotools: update to C++14
2019-11-27 12:12:29 -05:00
Adrien Béraud
eae383b3ed
autotools: remove unneeded macros
2019-11-26 12:46:26 -05:00
Adrien Béraud
28bf78408d
network utils: fix some race conditions
2019-11-26 12:24:37 -05:00
Adrien Béraud
7ed6f74e6b
proxy_server: add mutex to protect requests
2019-11-26 12:24:28 -05:00
Adrien Béraud
cf6d9fd8c2
proxy client: add lock for requests
2019-11-25 15:43:23 -05:00
Adrien Béraud
5df34bb752
http: use atomic ids
2019-11-25 15:42:45 -05:00
Adrien Béraud
bebb66490d
tests: fix proxy tester
2019-11-25 13:44:55 -05:00
Adrien Béraud
5f361748eb
Update ccpp.yml
2019-11-19 13:59:55 -05:00
Adrien Béraud
984745624c
Update ccpp.yml
2019-11-19 13:58:46 -05:00
Adrien Béraud
f9e860fdc8
docker/github: use deps base image
2019-11-19 13:52:40 -05:00
Adrien Béraud
06ea3d23e5
docker: add dockerfiles for Ubuntu 18.04 (Bionic)
2019-11-19 13:44:45 -05:00
Adrien Béraud
f0857a5925
Update ccpp.yml
2019-11-19 11:05:00 -05:00
Adrien Béraud
5a993fb902
Create ccpp.yml
2019-11-19 11:02:54 -05:00
Adrien Béraud
8a18c591e9
http: initialize connection type, cleanup
2019-11-12 16:45:00 -05:00
Adrien Béraud
9daa7ec283
dhtrunner: default peer request rate to global/8
2019-11-11 12:58:11 -05:00
Adrien Béraud
01f2ad9ea4
tools: show connectivity change in log
2019-11-11 11:54:44 -05:00
Adrien Béraud
2dd4cde035
tools: factorize print_node_info
2019-11-08 16:52:27 -05:00
Adrien Béraud
cb0005d0eb
tools: factor configuration parsing
2019-11-08 16:12:04 -05:00
Adrien Béraud
eca340b785
tools: add argument to disable rate limiting
2019-11-08 15:29:53 -05:00
Adrien Béraud
cdd035b801
rate limiter: cleanup
2019-11-07 19:17:27 -05:00
Adrien Béraud
cb7d7f6614
dht: allow to configure rate limiter
2019-11-07 16:43:04 -05:00
Adrien Béraud
f5a6801ab9
value: cleanup
2019-11-07 11:52:27 -05:00
Adrien Béraud
0049ba92e6
thread pool: retransmit exception through future
2019-11-07 11:51:44 -05:00
Adrien Béraud
7838e7de0b
docker: add python3-setuptools
2019-11-06 12:51:18 -05:00
Adrien Béraud
e2d7dbc293
proxy client: declare mutex before protected objects
2019-11-05 16:39:03 -05:00
Adrien Béraud
090da49fed
http/Request: cleanup
2019-11-04 15:50:55 -05:00
Adrien Béraud
22594396d2
http/Request: check conn_ on cancel
2019-11-04 15:49:05 -05:00
Adrien Béraud
0c8d0e2e0d
http/Request: atomically exchange terminate
2019-11-04 15:48:39 -05:00
Adrien Béraud
18793cee3b
proxy server: close listener on connection close only
2019-11-01 10:37:19 -04:00
Adrien Béraud
0bde82a218
tests/proxy: cleanup
2019-11-01 10:24:17 -04:00
Adrien Béraud
bc84655f42
proxy server: update for Restinio v.0.6.0.1
2019-10-31 16:00:51 -04:00
Adrien Béraud
ed642b0337
proxy: check that callback is not null
2019-10-31 14:36:34 -04:00
Adrien Béraud
f710df9675
proxy: cleanup
2019-10-31 13:44:05 -04:00
Sébastien Blin
42398a541d
rust: infohash support == operator and from hex
2019-10-31 10:56:52 -04:00
Sébastien Blin
429a5ad1d4
dhtrunner: fix put_encrypted API
2019-10-31 10:56:52 -04:00
Sébastien Blin
01bc43af35
rust: fix import for PrivateKey
2019-10-31 10:56:52 -04:00
Sébastien Blin
555487012b
rust: remove T for no. Anyway we must at least add None
2019-10-31 10:56:52 -04:00
Sébastien Blin
697d554edb
dhtrunner: change put methods
2019-10-31 10:56:52 -04:00
Sébastien Blin
8edd67834c
rust: add some wrappers for value
2019-10-31 10:56:52 -04:00
Adrien Béraud
80f04430c3
proxy client: build resolver if none available
2019-10-30 14:53:07 -04:00
Adrien Béraud
e4853bd29c
proxy: use common Json builder
2019-10-30 14:17:42 -04:00
Adrien Béraud
6863800cfb
dhtrunner: allow to cancelPut with value
2019-10-30 11:33:33 -04:00
Adrien Béraud
1f387a0e95
proxy client: resolve again on connectivity change
2019-10-30 11:33:16 -04:00
Adrien Béraud
142aee12a7
c wrapper: add support for putEncrypted
2019-10-28 17:43:00 -04:00
Adrien Béraud
95a65ce565
c wrapper: add support for putSigned
2019-10-28 17:35:41 -04:00
Adrien Béraud
144fa7ddc8
dhtrunner: allow permanent put for signed/encrypted values
2019-10-28 17:35:19 -04:00
Adrien Béraud
b77fd2336f
c wrapper: return null if no signer
2019-10-28 17:34:03 -04:00
Adrien Béraud
c0e117871e
c wrapper: allow retrieving value owner and recipient
2019-10-28 15:25:31 -04:00
Sébastien Blin
3c88eaa602
rust: add from_slice
2019-10-25 15:29:38 -04:00
Sébastien Blin
8d131449a8
rust: load identity from bytes
2019-10-25 15:29:38 -04:00
Sébastien Blin
fee7e5dd30
rust: fix callback result and add DhtIdentity::new()
2019-10-25 15:29:38 -04:00
Sébastien Blin
4c2a974433
rust: link to certificate C-bindings
2019-10-25 15:29:38 -04:00
Sébastien Blin
a483205976
infohash: add from_bytes
2019-10-25 15:29:38 -04:00
Adrien Béraud
96df1d4339
c wrapper: update callback return types
2019-10-25 11:05:35 -04:00
Seva
432f387423
http: ensure conn callbacks are always invoked
2019-10-24 16:03:07 -04:00
Seva
3abb9114ba
http: ensure sockets exists before invocations
2019-10-24 16:03:07 -04:00
Adrien Béraud
727c5f0e8c
c wrapper: add wrappers for dht::crypto::Certificate
2019-10-24 13:29:50 -04:00
Adrien Béraud
f86abfaf22
crypto: add tests for corrupted data
2019-10-22 13:59:36 -04:00
Adrien Béraud
f84131c820
crypto: improve authenticated encryption performance
2019-10-22 13:59:36 -04:00
Adrien Béraud
28de983166
update to version 2.0.0
2019-10-22 10:52:49 -04:00
Adrien Béraud
4b28278cb1
Update README.md
2019-10-22 10:48:50 -04:00
Sébastien Blin
653a4309bd
rust: value to bytes
2019-10-22 10:47:43 -04:00
Sébastien Blin
48b763f11b
rust: add from_bytes for value
2019-10-22 10:47:43 -04:00
Sébastien Blin
cbfa12a921
rust: add permanent put, get_id(), get_node_id(), get_public_addresses()
2019-10-22 10:47:43 -04:00
Sébastien Blin
3e0d4cd703
rust: link DhtRunnerConfig
2019-10-22 10:47:43 -04:00
Sébastien Blin
4bff6d392a
rust: clean warnings
2019-10-22 10:47:43 -04:00
Sébastien Blin
712b7218a9
rust: clean listen API
2019-10-22 10:47:43 -04:00
Sébastien Blin
5a8e252e32
rust: get2 -> get
2019-10-22 10:47:43 -04:00
Sébastien Blin
b5be4549dc
rust: clean dhtnode.rs
2019-10-22 10:47:43 -04:00
Sébastien Blin
bf8fb6f321
rust: clean listen API
2019-10-22 10:47:43 -04:00
Sébastien Blin
08cf212c53
rust: split in files
2019-10-22 10:47:43 -04:00
Sébastien Blin
fc2a597bb2
rust: update bootstrap api
2019-10-22 10:47:43 -04:00
Sébastien Blin
7212b7a28b
rust: change put api
2019-10-22 10:47:43 -04:00
Sébastien Blin
5c610895fe
rust: add support for all functions available in the C wrapper
2019-10-22 10:47:43 -04:00
Sébastien Blin
a567ca1dc1
rust: add support for listen/cancel_listen
2019-10-22 10:47:43 -04:00
Sébastien Blin
97b20705a1
rust: add put bindings
2019-10-22 10:47:43 -04:00
Sébastien Blin
431da16ba6
dhtnode: add example with get
2019-10-22 10:47:43 -04:00
Sébastien Blin
09818d779e
rust: start dhtnode example
2019-10-22 10:47:43 -04:00
Sébastien Blin
934e36ba13
rust: ffi POC
2019-10-22 10:47:43 -04:00
Adrien Béraud
2e47b9bab5
c wrapper: add dht_runner_get_public_address to dhtcnode
2019-10-21 15:56:35 -04:00
Adrien Béraud
f938d486d5
c wrapper: add listen context to dhtcnode
2019-10-21 15:09:56 -04:00
Adrien Béraud
76b4da089e
c wrapper: add dht_runner_get_public_address
2019-10-21 14:33:37 -04:00
Adrien Béraud
2a72277194
c wrapper: add dht_runner_get_id, get_node_id
2019-10-21 14:19:29 -04:00
Adrien Béraud
e8d96d3b42
c wrapper: add support for permanent put
2019-10-21 14:04:12 -04:00
Adrien Béraud
c92d236c1b
c wrapper: handle null string in config
2019-10-21 12:37:36 -04:00
Adrien Béraud
b680407e9a
c wrapper: add callback to free listen context data
2019-10-21 11:08:42 -04:00
Seva
6caf4b0d0b
http: ensure no data is lost in read_bytes
2019-10-18 15:44:26 -04:00
Seva
7f65fdc7f9
http: try to read full content-length after headers
2019-10-18 10:45:34 -04:00
Adrien Béraud
b00dfdf572
c wrapper: reverse is_zero value
2019-10-17 10:29:37 -04:00
Adrien Béraud
2b1d2fc3f6
c wrapper: use shared_ptr for dht_privatekey
2019-10-16 17:23:04 -04:00
Adrien Béraud
a0566cf695
dhtchat: cancel listen on channel disconnect
2019-10-16 16:18:38 -04:00
Adrien Béraud
a3f2b055a1
c wrapper: don't build by default
2019-10-16 16:17:09 -04:00
Adrien Béraud
01bf8f9303
c wrapper: add dht_infohash_get
2019-10-16 15:07:31 -04:00
Adrien Béraud
22741436e3
python: add wrapper for ValueCallback
2019-10-16 15:02:58 -04:00
Adrien Béraud
d958b0ea5f
c wrapper: add dht_privatekey_delete, handle import failure
2019-10-16 14:40:24 -04:00
Adrien Béraud
6c96a47f13
c wrapper: update dhtcnode, add dht_op_token_delete
2019-10-16 14:27:54 -04:00
Adrien Béraud
15403c0f6e
c wrapper: add dht_runner_put
2019-10-16 14:02:51 -04:00
Adrien Béraud
0eee567c4e
c wrapper: add support to create, ref/unref dht_value
2019-10-16 13:57:31 -04:00
Adrien Béraud
e8843076d9
c wrapper: install library
2019-10-16 13:18:39 -04:00
Adrien Béraud
3a6ce2f499
c wrapper: add initial dht_privatekey support
2019-10-16 13:09:59 -04:00
Adrien Béraud
299e632795
c wrapper: clarify memory management
2019-10-16 12:56:06 -04:00
Adrien Béraud
12aee01ffe
c wrapper: add pkg-config file
2019-10-16 12:26:36 -04:00
Adrien Béraud
83c5014a36
c wrapper: add dht_runner_listen
2019-10-16 12:19:42 -04:00
Adrien Béraud
e9377f2eb6
c wrapper: add Blob, PublicKey
2019-10-16 12:01:52 -04:00
Adrien Beraud
083a28f5d8
c wrapper: add wrapper foundations
...
Wrapper can be enabled/disabled with
-DOPENDHT_C=On/Off when configuring the cmake
project.
This commit add foundations for a C wrapper
by building an opendht-c shared library that
wraps dhtrunner (for now only creation/destruction).
It also adds a test executable, dhtcnode, using the
C wrapper library.
2019-10-16 10:57:10 -04:00
Seva
ab7f36ff85
https: use identity's certificate chain
2019-10-15 14:34:50 -04:00
Seva
8856a70af5
dhtproxy/http: dont store keys in objects
2019-10-15 14:34:50 -04:00
Seva
f24b6ca3e3
dhtproxy/http: dont store keys in asio::const_buffer
2019-10-15 14:34:50 -04:00
Seva
ccfb76d9b4
http: add client identity & fix CA
2019-10-15 14:34:50 -04:00
Seva
104a9e3b28
http: fix target's missing query
2019-10-10 14:24:51 -04:00
Seva
d77c868c55
http: close connection if server requests
2019-10-07 15:02:08 -04:00
Adrien Béraud
347f404a92
dhtchat: respect new arguments
2019-10-07 12:11:46 -04:00
Adrien Béraud
ed1b0220e5
dhtnode: always load node certificate
2019-10-07 11:06:38 -04:00
seva
739f4d0c0d
Merge pull request #448 from AmarOk1412/fix/resubscribe
...
proxy_client: reset correct opstate
2019-10-01 11:47:13 -04:00
Sébastien Blin
8ec0ab0ae4
proxy_client: reset correct opstate
...
opstate is captured by value in callbacks. So reset(new OpState())
will only reset the new one and previously captured will be stopped
forever.
2019-10-01 11:30:32 -04:00
Seva
55c56a5203
http: avoid creating a field in map on new key
2019-09-30 14:28:46 -04:00
Seva
7558444ae0
http: implement chunked transfer-encoding
2019-09-30 14:28:46 -04:00
Adrien Béraud
9bc2ceca68
dhtrunner: use new push_token config option
2019-09-30 10:52:50 -04:00
Seva
ac10afac44
dhtproxy: test put/get mtu with 40k chars
2019-09-30 10:21:35 -04:00
Adrien Béraud
128af52ea2
dhtrunner: allow to specify push token in config
2019-09-30 10:20:09 -04:00
Adrien Béraud
8ed2bf50b3
utils: fix printing negative durations
2019-09-30 10:17:41 -04:00
Seva
dcdfeb0415
http: forward declare json in api
2019-09-24 15:49:03 -04:00
Seva
833dc7f5a7
http: refactor constructors & init default headers
2019-09-24 15:49:03 -04:00
Seva
d0510dcb72
http: add send json & unit test
2019-09-24 15:49:03 -04:00
MingRui Zhang
6f87e9dbc3
Merge pull request #444 from binarytrails/http_fixes
...
http: fix parser reset racing condition
2019-09-23 15:19:26 -04:00
Seva
223260bc7d
http: remove parser reset
2019-09-23 13:24:53 -04:00
Sébastien Blin
c564810b8c
Merge pull request #441 from atraczyk/master
...
msvc: fix compilation with VS 2019 16.0
2019-09-19 14:30:59 -04:00
Sébastien Blin
f9ffb8650a
dht_proxy_client: listener should not be stopped here
...
Moreover, when it's a subscribe, because the subscribe is direct
2019-09-19 13:54:52 -04:00
Andreas Traczyk
e58fc4ef31
msvc: fix compilation with VS 2019 16.0
...
- <stdexcept> used to be included in <vector>
2019-09-18 16:40:12 -04:00
Seva
7fde8f63a8
peerdiscovery: refactor to camelcase & fix warning
2019-09-18 16:17:39 -04:00
Seva
166b5e352c
proxyserver: default push to localhost if empty host
2019-09-18 16:15:53 -04:00
Seva
77356b0539
dhtnode: restore gen identity ifndef proxy server
2019-09-18 15:02:21 -04:00
Seva
c7d633e609
dhtnode: separate proxy privkey, cert & pwd arguments
2019-09-18 15:02:21 -04:00
Seva
2576d95aa0
dhtnode: start ssl node only with valid identity
2019-09-18 15:02:21 -04:00
Seva
b31a29ea26
dhtproxy: run in both http & https
2019-09-18 15:02:21 -04:00
Sébastien Blin
833bd069f4
Merge pull request #439 from binarytrails/request_fixes
...
http: end request on 0 body bytes
2019-09-18 12:51:54 -04:00
Seva
39a186c47d
http: end request on 0 body bytes
...
the latter ensures that the request will be terminate even if the
http_parser on_message_complete callback is not called with an old
version of dhtproxy using restbed
2019-09-18 12:16:10 -04:00
Sébastien Blin
c03af5f5a8
dhtrunner: fix context.logger handling
2019-09-18 12:01:24 -04:00
Sébastien Blin
b03a7732e3
Merge pull request #436 from binarytrails/http_expect_100-continue
...
http: handle expect 100-continue on post
2019-09-16 11:32:43 -04:00
Seva
87f6f3df8b
http: fix & test url with https but empty service
2019-09-13 13:50:45 -04:00
Seva
7270c353df
http: handle expect 100-continue
...
expose raw request & ignore more self-signed
2019-09-12 11:32:54 -04:00
Seva
63afc8c29a
http: fix resolver destruction race condition
2019-09-09 16:28:26 -04:00
Andreas Traczyk
6a760a629c
msvc: update native windows build to use restinio
2019-09-09 15:24:23 -04:00
Seva
5068de7bc0
http: remove x509 subject name logging in verify cb
2019-09-05 15:24:50 -04:00
Seva
2a5f786f8b
http: handle request error codes through terminate
2019-09-05 15:24:50 -04:00
Seva
c690d060f9
http: fix req cancel racing condition
2019-09-05 15:24:50 -04:00
Adrien Béraud
bcf8ab5404
http: check for null callbacks
2019-09-05 11:23:23 -04:00
Adrien Béraud
f7c8168f99
http: cleanup, remove default port
...
Prevents ambiguous function call when just providing a URL.
2019-08-30 17:34:31 -04:00
Adrien Béraud
c37f0083d3
crypto: add CertificateRequest::toString
2019-08-30 11:26:29 -04:00
Adrien Béraud
29e7768c9d
proxy client: cleanup
2019-08-30 11:26:00 -04:00
Adrien Béraud
72a06b1425
http: add Request::set_auth
2019-08-30 11:24:51 -04:00
Adrien Béraud
e4dacc64b5
cmake: find library in argon2_LIBRARY_DIRS
2019-08-30 01:34:09 -04:00
Adrien Béraud
20df5fe845
http: cleanup
2019-08-30 01:28:12 -04:00
Adrien Béraud
5b4f40229d
proxy client: cleanup
2019-08-30 01:08:12 -04:00
Adrien Béraud
6c4af9bfea
proxy server: fix warnings
2019-08-30 01:06:50 -04:00
Adrien Béraud
ef26155b19
proxy client: add missing override
2019-08-30 00:35:51 -04:00
Seva
eb2269625f
http: optimize get_url funcs
2019-08-30 00:13:15 -04:00
Seva
70c92d6cea
http: replace service by url
2019-08-30 00:13:15 -04:00
Seva
fd7f644531
http: init request target with url one
2019-08-30 00:13:15 -04:00
Seva
562bf7124c
http: handle url fragment
2019-08-30 00:13:15 -04:00
Seva
5b344cada7
http: propagate the use of url
2019-08-30 00:13:15 -04:00
Seva
7c4450fdb1
http: add url with tests, handle prefix
2019-08-30 00:13:15 -04:00
Seva
9b8358cdf1
configure: set openssl & fmt flags with pkg_check_modules
2019-08-28 11:03:15 -04:00
Seva
7ae3b3af5b
configure: use cflags,libs,ldflags of openssl
2019-08-28 11:03:15 -04:00
Seva
06d1865446
configure: build with ssl, rm not used cppflag
2019-08-28 11:03:15 -04:00
Seva
83495a94db
dhtproxy: fix client class member redeclaration
2019-08-28 11:03:15 -04:00
Seva
8ee5485767
autotools: fix dhtproxy build
2019-08-28 11:03:15 -04:00
Seva
e7742489ca
http: ignore rw ops on closed connection
2019-08-27 10:11:04 -04:00
Seva
99fc97f3cf
http: return from async_handshake on op abort
2019-08-27 10:11:04 -04:00
Seva
82d5db81e0
http: let the connection terminate
2019-08-27 10:11:04 -04:00
Seva
fbb90a71b7
cmake: add asio standalone flag to avoid boost
2019-08-27 10:11:04 -04:00
Seva
316f3ccfa0
docker: fix ubuntu xenial asio dep comment typo
2019-08-26 12:06:07 -04:00
Seva
185158f460
docker: build shared for libfmt
2019-08-26 12:06:07 -04:00
Seva
baa9fcf820
dhtproxy: disable renegotiation only if supported
2019-08-26 12:06:07 -04:00
Seva
04a383c4fb
docker: fix deps & depsllvm
2019-08-26 12:06:07 -04:00
Adrien Béraud
b7b6fb802d
http: header cleanup
2019-08-22 16:51:05 -04:00
Adrien Béraud
9575f84081
header cleanup
2019-08-22 15:39:15 -04:00
Adrien Béraud
0b0442bd02
proxy server: remove unneeded move
2019-08-21 13:22:36 -04:00
Adrien Béraud
251fe8bf2f
dockerfiles: add restbed
2019-08-21 13:22:20 -04:00
Seva
c211055bf9
tester: add https support to proxy_node
2019-08-20 15:17:10 -04:00
Seva
fafe97194a
dhtproxy: reduce & uniformize logs
2019-08-20 10:46:20 -04:00
Seva
d214bfebf5
dhtproxy: patch client renegotiation
2019-08-20 10:45:05 -04:00
Adrien Béraud
d551b8a54c
Merge pull request #417 from binarytrails/proxy_docker
...
docker: switch dhtproxy build to cmake & remove conan
2019-08-16 10:20:07 -04:00
Seva
4a8397d71b
dhtproxy: fix indirect memleaks from rest router traits
2019-08-16 10:18:36 -04:00
Seva
366f76986f
docker: bump restinio & replace sed fix by new var
2019-08-15 16:38:53 -04:00
Seva
8072092b67
docker: switch to cmake build & remove conan
2019-08-15 16:20:22 -04:00
Adrien Béraud
624f36467e
proxy: don't use shared_ptr for Identity
2019-08-14 17:30:29 -04:00
Adrien Béraud
561a660693
proxy: header cleanup
2019-08-14 17:19:33 -04:00
Adrien Béraud
414e0a2e60
proxy server: move type traits definition to cpp
2019-08-14 15:51:12 -04:00
Adrien Béraud
e0393ff8ad
Merge pull request #403 from binarytrails/proxy_restinio
...
dhtproxy: replace restbed by restinio & asio
2019-08-14 15:50:14 -04:00
Seva
d26bfc58d8
http: align logs
2019-08-14 14:02:43 -04:00
Seva
d50aae0751
dhtproxy: cleanup
2019-08-14 03:58:15 -04:00
Seva
1a79ae45e4
dhtproxy: fix server termination & use https tests
2019-08-14 03:41:32 -04:00
Seva
c6f830f54d
http: fix refactoring memory issues
2019-08-14 02:30:19 -04:00
Seva
f018610ec9
http: fix ssl rfc2818 verif. due to self-signed cert.
2019-08-13 23:16:44 -04:00
Seva
119c162f49
dhtproxy: make optional the http_parser fork in client
2019-08-13 20:30:14 -04:00
Seva
144e254c40
build: add flag for http_parser fork
2019-08-13 17:17:32 -04:00
Seva
6cc84312aa
dhtproxy: run tests in http
2019-08-13 16:55:42 -04:00
Seva
b3a7bdd880
cppflags: rm OPENDHT_PROXY_OPENSSL last occurences
2019-08-13 16:25:33 -04:00
Seva
a797ea9171
dhtproxy: create http & https server instances
2019-08-13 16:21:19 -04:00
Seva
023b4aff61
dhtnode: use generated identity only if specified
2019-08-13 14:53:45 -04:00
Seva
86429aa360
http: support all connections contd.
2019-08-13 13:45:10 -04:00
Seva
fbea6afe5d
http: support all connections idependent of build system
2019-08-13 10:23:15 -04:00
Seva
18bcad33bd
autotools: add openssl support to configure
2019-08-12 15:24:13 -04:00
Seva
8bc43b4e47
dhtproxy: propagate server identity certicate to client
2019-08-12 15:11:37 -04:00
Seva
25f3000a78
http: verify peer only if certificate provided
2019-08-12 14:27:59 -04:00
Seva
96992b803c
dhtproxy: implement https in server
2019-08-10 15:34:36 -04:00
Seva
500ae6ef54
http: handle asio cancel delays
2019-08-10 15:34:02 -04:00
Seva
b01d3cfca5
dhtproxy: add identity to constructor if openssl
2019-08-07 11:57:18 -04:00
Seva
49f6dd3c9c
http: implement secure connection
...
cmake: use provided findopenssl module
2019-08-07 10:35:47 -04:00
Seva
4054ec6af0
opendht: add ssl to build system
...
http: enforce ssl everywhere
2019-08-05 11:09:18 -04:00
Adrien Béraud
3345c1b048
update to version 1.10.1
2019-08-02 21:06:26 -04:00
Adrien Béraud
4b061d0886
dht: cleanup
2019-08-02 19:58:43 -04:00
Adrien Béraud
c1f805e6e2
tools: use default port from network utils
2019-08-02 19:53:39 -04:00
Adrien Béraud
25c9375d95
dhtrunner: add bootstrap method with single arg. host:service
2019-08-02 19:41:42 -04:00
Adrien Béraud
84a9d899d5
dhtrunner: migrate to SockAddr, use default port if not set
2019-08-02 14:42:26 -04:00
Seva
7ea40c292b
dhtproxy: fix indirect mem leak caused by 208758e
2019-08-02 10:19:06 -04:00
Seva
2954158bba
http: handle all content-length cases
2019-08-01 13:44:14 -04:00
Seva
3382195760
http: refactor response funcs to handle mtu
2019-08-01 00:43:37 -04:00
Seva
b67149c98c
http: implement final api changes
2019-07-30 11:44:14 -04:00
Seva
f34cb6440f
http: add comments & log errors on end
2019-07-30 10:14:53 -04:00
Seva
9cf37eb865
dhtproxy: always log client in tests
2019-07-30 09:26:38 -04:00
Seva
c8bed06641
http: rm default conn header & end properly
2019-07-30 09:22:03 -04:00
Seva
51aef18885
dhtproxy: fix operation stop in cancelAllListeners
2019-07-29 13:02:25 -04:00
Seva
49a132a54b
http: fix request termination
2019-07-29 12:51:23 -04:00
Seva
235c48c400
dhtproxy: fail client ipv4/6 query on operation cancel
2019-07-29 09:40:41 -04:00
Seva
5465b08d76
dhtproxy: attempt to connect to an ipv4/ipv6 pair
2019-07-27 00:20:08 -04:00
Seva
a8e24e505d
dhtproxy: design clean persistent destruction
...
http: terminate with eof on_message_complete parser cb
2019-07-26 11:56:36 -04:00
Seva
5c0a8986a7
dhtproxy: fix listener destruction thus, restart
2019-07-26 09:57:00 -04:00
Seva
460205eb78
http: terminate connection with eof
2019-07-25 21:56:26 -04:00
Seva
208758ede3
dhtproxy: remove implicit std::move on a router return
2019-07-25 21:17:41 -04:00
Seva
de9e0906de
http: merge on_message_complete into on_state_change callback
2019-07-25 20:09:59 -04:00
Seva
692304c2e3
tests: log dhtproxy client
2019-07-25 19:25:57 -04:00
Seva
f837c13e31
http: fragment request header & body read/parse
2019-07-24 23:56:32 -04:00
Seva
5812b24d56
http: transform client into request
2019-07-24 15:59:22 -04:00
Seva
a72ddfdb03
dhtnode: fix shutdown deadlock
2019-07-16 15:57:19 -04:00
Seva
e7b03e4d53
dhtproxy: unify client destruction & shutdown with stop()
2019-07-16 15:46:13 -04:00
Seva
baf43d96ff
dhtproxy: encapsulate server expire handlers
2019-07-16 15:12:38 -04:00
Seva
0f9df9a62b
dhtproxy: fix server send push notif underflow
2019-07-16 13:04:37 -04:00
Seva
630112601c
dhtproxy: fix client connectivity change
...
add handle resubscribe
ignore operation aborted signals
2019-07-16 12:48:29 -04:00
Seva
b0500af062
dhtproxy: fix client proxy confirmation
2019-07-15 13:47:31 -04:00
Seva
6c985e8fda
dhtproxy: fix restart client listeners
2019-07-15 13:42:10 -04:00
Seva
9c1e55279c
dhtproxy: fix refresh permanent put timer
2019-07-15 13:29:21 -04:00
Adrien Béraud
593d024f51
proxy client: fix cancelListen, add locks
2019-07-15 11:35:01 -04:00
Seva
a6e57d95d6
dhtproxy: fix cancelListen & rm duplicated logging
2019-07-12 15:59:51 -04:00
Seva
846f495202
dhtproxy: fix indirect mem leak in create router
2019-07-11 11:06:36 -04:00
Seva
6f603bfc0a
dhtproxy: fix options route
2019-07-11 10:46:33 -04:00
Seva
9c106f9efe
http: make connection data unique & fix init warn
2019-07-11 10:26:51 -04:00
Seva
ff288fb4a3
autotools: add dhtproxy dependencies checks
2019-07-09 15:28:57 -04:00
Seva
17ff4c0224
http: one line init of conn context
2019-07-09 14:17:17 -04:00
Seva
45a2c6dadb
dhtproxy: sanitized by fixing client memory leaks
2019-07-09 12:21:56 -04:00
Seva
477ff59e91
dhtproxy: enhance error handling & msg for push
2019-07-09 10:20:39 -04:00
Seva
a001e0cafd
dhtproxy: fix client multi-line data in get/listen
2019-07-08 16:47:52 -04:00
Seva
ac63527e0b
http: split header & body processing
...
this allow to handle a case when an incomplete body is attached to a
header to forward it to the body processing for full recovery.
2019-07-08 16:46:49 -04:00
Seva
4b3d8d1231
dhtproxy: move operations into async_connect handler
2019-07-06 12:25:14 -04:00
Seva
d04a741d5e
http: better error handling
...
use async::connect instead of manually
2019-07-05 18:44:10 -04:00
Seva
ac2b7deda8
http: add set_connection_timeout
2019-07-03 17:03:53 -04:00
Seva
c8b08b5ed1
dhtproxy: fix client stop by cancelling io_context
2019-07-03 14:30:10 -04:00
Seva
f556987e47
http: handle unavailable server
2019-07-03 14:23:49 -04:00
Seva
2daf36c97e
Merge branch 'master' into proxy_restinio
2019-07-03 14:07:35 -04:00
Seva
2a2555f0c2
dhtproxy: fix type nomenclature & compile warnings
2019-07-03 12:10:49 -04:00
Seva
bdfb0148e4
dhtproxy: use legacy listen route in client
2019-07-03 11:27:51 -04:00
Seva
01be4d2eb8
dhtproxy: enhance new api routes
2019-07-03 11:01:32 -04:00
Seva
93f7251805
http: segment resolving & connection from request
...
set connection id to unsigned int
use service string instead of int port
segment connection from request
save endpoint associated with a conn
add Connection is_v6 ip method
propagate resolve errors
2019-07-03 10:30:33 -04:00
Adrien Béraud
a8718242cd
net: fix build on MSVC2017
2019-07-02 14:51:28 -04:00
Adrien Béraud
297a23fb1f
dhtrunner: run shutdown on op queue
2019-07-02 12:09:31 -04:00
Adrien Béraud
0d641161e8
dhtrunner: fix minor warning
2019-07-01 23:22:00 -04:00
Adrien Béraud
27b3c0d47e
dhtrunner: add appropriate lock to setProxyServer
2019-07-01 23:20:03 -04:00
Adrien Béraud
149b33ef57
dht: simplify error message to avoid use-after-move
2019-07-01 15:07:10 -04:00
Adrien Béraud
150e62de0b
sockaddr: fix npe if address is not set
2019-07-01 14:08:41 -04:00
Adrien Béraud
89bdfce840
dhtrunner: add proper locks for push notification
2019-07-01 12:10:51 -04:00
Adrien Béraud
bce41ecd69
proxy client: fix build with push notifications
2019-07-01 01:12:21 -04:00
Adrien Béraud
4374d206ab
op_cache: simplify addListener
2019-07-01 00:34:05 -04:00
Adrien Béraud
b64820af59
proxy client: remove unneeded filter
...
Filters are applied at the SearchCache level
2019-07-01 00:34:05 -04:00
Adrien Béraud
0e509318bb
build: only build http with proxy
2019-06-28 20:56:22 -04:00
Seva
bcc2baa94a
http: ensure http_parser on_message_complete cb is always called
2019-06-28 15:28:12 -04:00
Seva
bbed9d530d
http: remove unnecessary resolve iteration log
2019-06-28 14:49:37 -04:00
Seva
5a3612be98
dhtproxy: default client port to 80
2019-06-28 14:32:24 -04:00
Seva
8202c1f7d7
http: add default port to 80
2019-06-28 13:55:36 -04:00
Seva
a200b0e14c
http: open client to public api
2019-06-27 09:48:33 -04:00
Seva
bd32edc6c5
dhtproxy: uniform client logging
2019-06-25 17:04:38 -04:00
Seva
d0d3ef7394
http: don't process resps & reqs on closed conn
2019-06-25 16:49:48 -04:00
Seva
712da15ae2
readme: change optional restbed mention to restinio
2019-06-25 16:08:19 -04:00
Seva
fcdc997d29
cmake: fix undefined ref to pthreads for dhtnode
2019-06-25 15:45:12 -04:00
Seva
cf18effebb
dhtnode: fix logging
2019-06-25 15:21:49 -04:00
Seva
b8c2ff8a11
dhtproxy: cleanup client handle proxy status
2019-06-25 14:35:04 -04:00
Seva
1fad1b9ce3
dhtrunner: use user logger with proxy client
2019-06-25 13:37:45 -04:00
Seva
117fedb641
dhtproxy: test with http client lib everything
2019-06-25 13:36:14 -04:00
Seva
422f5a6c45
dhtproxy: use one io_context, rm scheduler, fix get,proxyInfo
2019-06-25 13:35:26 -04:00
Seva
51a42aa2c8
dhtproxy: fix inconsistencies & add comments
2019-06-25 10:16:40 -04:00
Adrien Béraud
be0baefee8
net: recompute selectFd in case of rebind
2019-06-22 22:51:56 -04:00
Adrien Béraud
2ac5157ab8
net: attempt to use the same port for IPv4 and IPv6 if 0
2019-06-22 21:30:49 -04:00
Adrien Béraud
fbe8834e04
net: compute selectFd once
2019-06-22 18:49:50 -04:00
Adrien Béraud
89ff131750
tools: close stdin on sigint
2019-06-22 18:37:58 -04:00
Adrien Béraud
feb498305f
network engine: convert mapped IPv4
2019-06-22 18:37:58 -04:00
Seva
b00f56c94a
dhtproxy: fix server logging of non c str
2019-06-21 14:41:10 -04:00
Seva
2067cb052f
dhtproxy: default to curly brakets instead of nullptr
2019-06-21 13:10:33 -04:00
Seva
51aeaeaeab
dhtproxy: use logger everywhere & use same format
2019-06-21 12:49:47 -04:00
Seva
c0bb8f065c
dhtproxy: ensure client asio timers are initialized
2019-06-21 11:33:51 -04:00
Seva
126318956a
dhtproxy: fix unintialized refresh timer in listen
2019-06-21 11:13:54 -04:00
Seva
9014c0a7bb
dhtproxy: log subscribe to debug instead of warning
2019-06-21 11:12:49 -04:00
Seva
728782921c
dhtproxy: test resubscribe with random port
2019-06-21 11:07:20 -04:00
Adrien Béraud
d438d4ef1b
sockaddr: add getMappedIPv6
2019-06-21 11:00:48 -04:00
Seva
2959709462
dhtproxy: log in client only if logger is defined
2019-06-20 16:44:13 -04:00
Seva
4a26168248
dhtproxy: ensure client http processing keeps running
2019-06-20 16:13:01 -04:00
Seva
9c348b1df4
dhtproxy: use same client logger
2019-06-20 15:31:43 -04:00
Seva
7e7654d1ae
dhtproxy: use two io_contexts periodic & http
2019-06-20 14:43:16 -04:00
Seva
69ee1d212a
http: replace tabs by 4 spaces
2019-06-20 12:30:42 -04:00
Seva
21ec9129c3
tools: rename proxy benchmark to loadtester
2019-06-20 12:24:44 -04:00
Seva
b7185fa87c
dhtproxy: rewrite client restartListeners & save listener connId
2019-06-20 12:14:27 -04:00
Seva
54acd67a1f
dhtproxy: rewrite client cancelAllListeners with RESTinio
2019-06-20 11:56:16 -04:00
Seva
045de8602c
dhtproxy: rewrite client doCancelListen with RESTinio
2019-06-20 11:52:15 -04:00
Seva
390fa48700
dhtproxy: replace status thread by asio timer
2019-06-20 11:24:56 -04:00
Seva
0d08f0d356
dhtproxy: replace client threads by asio timers
2019-06-20 11:23:38 -04:00
Adrien Béraud
738424b1ae
dhtrunner: use default values for config
2019-06-19 19:27:54 -04:00
Seva
d123d8f768
http: remove typo
2019-06-19 12:23:00 -04:00
Seva
a20a48506d
http: fix resolve & externalize conn close
2019-06-19 12:07:46 -04:00
Seva
063a2b4860
http: make conn async & resolve hostnames
2019-06-19 11:34:50 -04:00
Seva
829d365475
http: detect & handle close connection
2019-06-19 10:24:51 -04:00
Seva
11e6671e60
Merge branch 'proxy_asio_client' into proxy_restinio
2019-06-18 23:27:51 -04:00
Seva
6fe473d3cc
http: fragment client into async operations
2019-06-18 23:17:49 -04:00
Seva
9f493b9572
http: make continious reads non blocking
2019-06-18 16:55:52 -04:00
Seva
2164c5ddc7
dhtproxy: add control for max_pipelined_requests
2019-06-18 14:57:17 -04:00
Seva
a57a4d55e8
dhtproxy: optimize for concurency
2019-06-18 14:13:42 -04:00
Seva
b98cc78b42
dhtproxy: add if logger before using it
2019-06-18 10:17:21 -04:00
Seva
789d41ff07
dhtproxy: fix join on terminated thread
2019-06-17 16:42:12 -04:00
Seva
632403875c
dhtproxy: switch entirely to one thread
2019-06-17 16:27:39 -04:00
Seva
bc2737cdc9
dhtproxy: move resp msgs to cpp file as constexpr
2019-06-17 15:29:25 -04:00
Seva
0c6bfde1c5
docker: cp restinio deps build files to system path
2019-06-17 15:13:32 -04:00
Seva
cfeeaf7950
tools: add listen & subscribe to proxy_benchmark
2019-06-17 13:57:46 -04:00
Seva
e31ebfea32
docker: finalize restinio conan setup
2019-06-17 13:06:04 -04:00
Seva
07efe8c76e
tools: add locust proxy_benchmark.py
2019-06-17 11:46:29 -04:00
Seva
5c78bf386d
docker: update restinio run commands
2019-06-16 22:04:05 -04:00
Adrien Béraud
86088b043b
thread pool: getShared returns shared_future instead of shared_ptr<future>
2019-06-14 13:06:06 -04:00
Seva
fad8bb1631
dhtrunner: change context logger from unique to shared ptr
2019-06-14 11:46:13 -04:00
Seva
9a56c099a1
docker: rename pip unknown cmd to pip3 & remove comments
2019-06-14 10:23:59 -04:00
Seva
8298c0c868
docker: add restinio & conan depsllvm
2019-06-13 18:44:23 -04:00
Seva
971f590941
Merge branch 'master' github.com:savoirfairelinux/opendht into proxy_restinio
2019-06-13 17:19:49 -04:00
Seva
1813d83273
docker: add restinio & conan dependency
2019-06-13 16:04:14 -04:00
Seva
e87d164f0b
dhtproxy: refactor client to use external io_context
2019-06-13 13:24:44 -04:00
Seva
b9604807ea
dhtproxy: replace threads by io_context
...
replace scheduler and its jobs by asio timers
2019-06-13 11:13:48 -04:00
Seva
9f12b44179
dhtproxy: move custom methods to http & default thread pool to 1
2019-06-11 16:30:42 -04:00
Seva
0772d5435c
dhtproxy: replace listener thread with a conn state observer
2019-06-11 15:37:47 -04:00
Seva
368ee9e22e
dhtproxy: ensure io_context thread pool & isolate settings
2019-06-11 11:31:43 -04:00
Seva
dd56bdd8e2
dhtproxy: add conn listener & make http services singletons
2019-06-10 17:08:37 -04:00
Seva
71b36e0643
dhtproxy: set logger in sendPushNotification
2019-06-10 14:16:18 -04:00
Seva
61b43759df
dhtproxy: set required timeout times
2019-06-10 10:12:08 -04:00
Adrien Béraud
96e12e88c3
dhtproxytester: add more checks, cleanup
2019-06-09 23:34:38 -04:00
Adrien Béraud
8da933c01a
dhtrunner: use threaded mode by default
2019-06-09 23:31:40 -04:00
Adrien Béraud
20c0069867
dhtrunner/peerdiscovery: only advertise bound address families
2019-06-09 23:15:31 -04:00
Adrien Béraud
8942e0d00e
dht: init parent class with logger
2019-06-09 19:07:04 -04:00
Adrien Béraud
bc760f9348
Update README.md
2019-06-09 19:06:44 -04:00
Adrien Béraud
59702190a7
update to version 1.10.0
2019-06-09 09:06:36 -04:00
Adrien Béraud
cb3e94d0be
dhtnode: improve manpage
2019-06-08 13:28:52 -04:00
Adrien Béraud
ab7b8f6027
dhtnode: improve manpage
2019-06-08 12:59:57 -04:00
Adrien Béraud
6e5231047b
dhtrunnner: properly lock mutex in run & join
2019-06-08 10:20:25 -04:00
Adrien Béraud
777505434c
tools: always handle signals, don't block in signal handling
2019-06-08 09:23:34 -04:00
Adrien Béraud
18c3161261
tools: allow to use existing certificate/private key
2019-06-08 01:43:07 -04:00
Seva
1060038bdf
dhtproxy: write into dht logger
2019-06-07 16:46:28 -04:00
Seva
9d427a6a80
http: add optional client conn controls
2019-06-07 15:46:21 -04:00
Seva
f1dbac2aff
dhtproxy: fix client context lost in the abyss
2019-06-07 14:57:16 -04:00
Adrien Béraud
a63c5d172b
build: install network utils
2019-06-07 14:41:10 -04:00
Adrien Béraud
9c6de8cc16
net: add logger support for UdpSocket
2019-06-07 14:14:15 -04:00
Adrien Béraud
fe9de44867
dhtrunner: stop socket after dht
2019-06-07 14:14:15 -04:00
Adrien Béraud
4bfd6bb545
dhtrunner: add pluggable transport
2019-06-07 14:14:15 -04:00
Adrien Béraud
120c017399
net: add DatagramSocket, UdpSocket transport
2019-06-07 14:14:15 -04:00
Seva
7fc7597564
dhtproxy: fix indent
2019-06-06 14:51:01 -04:00
Seva
f8d62dc6a7
dhtproxy: add support for legacy http methods
...
Legacy non-standard http methods: LISTEN, STATS, SIGN, ECNRYPT
NOTE: Supported with RESTinio > 0.5.0 and custom http_parser
- https://github.com/Stiffstream/restinio/issues/26
- https://github.com/binarytrails/http-parser
2019-06-06 13:30:37 -04:00
Seva
fc3686d817
dhtproxy: comment/remove restbed leftovers to build w/o
2019-06-06 11:08:39 -04:00
Seva
a692f7fbe2
dhtproxy: add logger to tester & disable client proxy
2019-06-05 16:50:50 -04:00
Seva
cb349d9cf6
dhtproxy: stop server eventloop on cmd
2019-06-05 16:39:18 -04:00
Seva
6266f88cd5
dhtproxy: port doPut,sendListen logic new http client
2019-06-04 17:21:44 -04:00
Seva
0a3320e2c8
dhtproxy: enhance http async api & finish client get
2019-06-04 16:14:37 -04:00
Mingrui Zhang
d6ad67d8e2
peerdiscovery: change comment
2019-06-04 15:30:45 -04:00
Mingrui Zhang
19d0aa55f7
Test: change ip multicast address to organization local
2019-06-04 15:30:45 -04:00
Adrien Béraud
941e53425f
update to version 1.9.5
2019-06-04 09:54:02 -04:00
Seva
10971f700f
dhtproxy: add http classes with fully async client
...
use server's pushNotifications of this client
2019-06-03 17:10:19 -04:00
Seva
2e7767d192
dhtproxy: fix restinio start w/o dhtlogger
2019-06-03 13:52:35 -04:00
Adrien Béraud
baf811bfe9
dhtrunner: don't override statusCallback if not provided
2019-05-31 19:29:59 -04:00
Adrien Béraud
76f0672e63
context: add statusCallback, certificateStore
2019-05-31 10:12:42 -04:00
Seva
330ad8ed12
dhtproxy: pipe restinio logs to opendht logger
2019-05-29 16:02:25 -04:00
Seva
3252e6daa3
dhtproxy: rewrite sendListen with restinio
2019-05-29 11:59:09 -04:00
Seva
07599239a6
dhtproxy: port restbed client listen to server
2019-05-28 11:39:04 -04:00
Seva
eac61678f4
dhtproxy: add client request conn_cb for listeners
2019-05-28 10:26:47 -04:00
Seva
078c1198b0
Merge branch savoirfairelinux 'master' changes
2019-05-27 15:23:26 -04:00
Seva
3d525030b9
dhtproxy: add async put & swap threading for io_context
2019-05-27 15:06:11 -04:00
Seva
3733fc2890
dhtproxy: switch threading to io_context
2019-05-27 15:06:11 -04:00
Seva
c40f35fa06
dhtproxy: fix context type casting in client get
2019-05-27 14:59:19 -04:00
Seva
13661929d1
dhtproxy: switch server to ipv6 (implicit ipv4 support)
2019-05-27 14:59:19 -04:00
Seva
4e934f8902
dhtproxy: add ipv6 to restinio client & get method
2019-05-27 14:59:19 -04:00
Seva
125a05a5fc
dhtproxy: fix sendPushNotification
2019-05-27 14:59:19 -04:00
Seva
868c114bcb
dhtproxy: fix restinio client rx by parts
2019-05-27 14:59:19 -04:00
Seva
f0acc3e735
dhtproxy: add sendPushNotification to server
2019-05-27 14:59:19 -04:00
Seva
171e2b130b
dhtproxy: implement restinio client
2019-05-27 14:59:19 -04:00
Seva
cb5a261b82
dhtproxy: cleanup server
2019-05-27 14:59:19 -04:00
Seva
feb8bd0d4f
dhtproxy: rewrite listen with restinio
2019-05-27 14:59:19 -04:00
Seva
3955368c01
dhtproxy: rewrite putEncrypted with restinio
2019-05-27 14:59:19 -04:00
Seva
b841ff1b83
dhtproxy: rewrite putSigned with restinio
2019-05-27 14:59:19 -04:00
Seva
7a04c0eb66
dhtproxy: rewrite getFiltered with restinio
2019-05-27 14:59:19 -04:00
Seva
fe1659bd2f
dhtproxy: rewrite un/subscribe with restinio
2019-05-27 14:59:19 -04:00
Seva
b90e14edd6
dhtproxy: rewrite stats with restinio
2019-05-27 14:59:19 -04:00
Seva
9e3e9e65e6
dhtproxy: switch server to restinio
...
rewrite options, getNodeInfo, get & put
opendht: bump to c++14
2019-05-27 14:59:19 -04:00
Seva
1c3132e0ef
dhtproxy: add async put & swap threading for io_context
2019-05-27 14:57:05 -04:00
Seva
f3e304e661
dhtproxy: switch threading to io_context
2019-05-27 11:17:51 -04:00
Seva
2545282624
dhtproxy: fix context type casting in client get
2019-05-26 09:50:44 -04:00
Seva
52c413f056
dhtproxy: switch server to ipv6 (implicit ipv4 support)
2019-05-24 13:18:06 -04:00
Seva
ab082543ea
dhtproxy: add ipv6 to restinio client & get method
2019-05-24 11:01:35 -04:00
Adrien Béraud
ff6be81929
peer discovery: add default port
2019-05-23 10:39:43 -04:00
Seva
bd994384f0
dhtproxy: fix sendPushNotification
2019-05-22 17:23:36 -04:00
Seva
598e38dbf4
dhtproxy: fix restinio client rx by parts
2019-05-22 16:21:07 -04:00
Seva
b1a35b82a2
dhtproxy: add sendPushNotification to server
2019-05-22 11:55:37 -04:00
Adrien Béraud
e4516772ee
dht: log cleanup
2019-05-22 11:20:27 -04:00
Seva
c7844fc320
dhtproxy: implement restinio client
2019-05-22 10:29:27 -04:00
Adrien Béraud
c7e2483160
dht: add logger to constructor
2019-05-22 00:47:25 -04:00
Adrien Béraud
37b12c114d
dht: cleanup
2019-05-22 00:17:18 -04:00
MingruiZhangW
77bd34ad9c
Merge pull request #405 from savoirfairelinux/context
...
dhtrunner: add context
2019-05-21 16:21:45 -04:00
Adrien Béraud
44490bd9ca
dhtrunner: add context
2019-05-21 13:43:55 -04:00
Adrien Béraud
ca01568824
dhtrunner: add API to access PeerDiscovery instance
2019-05-20 10:21:35 -04:00
Adrien Béraud
2b259639d2
peer discovery: fix occasional use-after-free in unit test
2019-05-20 10:21:26 -04:00
Adrien Béraud
84d322e428
peer discovery: check running before select
2019-05-20 10:21:26 -04:00
Seva
6d5e3d8cd2
dhtproxy: cleanup server
2019-05-17 14:27:18 -04:00
Seva
b56518f258
dhtproxy: rewrite listen with restinio
2019-05-17 14:03:07 -04:00
Sébastien Blin
d807af3951
Merge pull request #402 from MingruiZhangW/peerdiscovery_fix_bind
...
peerdiscovery: bind socket problem fix
2019-05-16 17:19:02 -04:00
Seva
5f393490a5
dhtproxy: rewrite putEncrypted with restinio
2019-05-16 17:15:31 -04:00
Seva
efe869fe42
dhtproxy: rewrite putSigned with restinio
2019-05-16 16:06:47 -04:00
Seva
a31cecdeac
dhtproxy: rewrite getFiltered with restinio
2019-05-16 15:19:26 -04:00
Seva
4a4becdbec
dhtproxy: rewrite un/subscribe with restinio
2019-05-16 14:09:13 -04:00
Seva
eef2838a12
dhtproxy: rewrite stats with restinio
2019-05-16 12:31:58 -04:00
Seva
a520657fac
dhtproxy: switch server to restinio
...
rewrite options, getNodeInfo, get & put
opendht: bump to c++14
2019-05-16 11:30:41 -04:00
Mingrui Zhang
29003700db
peerdiscovery: fix the issue where bind() can be interrupted after calling publish() first
2019-05-15 15:42:32 -04:00
Sébastien Blin
b143bc459d
default_types: add metadatas map into ImMessage
...
Give the ability to store more datas into an ImMessage
Issue: #345
2019-05-03 14:54:43 -04:00
Adrien Béraud
4d6e5ab877
peer discovery: fix warning
2019-05-03 10:13:05 -04:00
Adrien Béraud
248d2e3f73
update to version 1.9.4
2019-05-02 12:44:27 -04:00
Adrien Béraud
0692bd9bc9
proxy server: fix warning when building without push notifications
2019-04-30 17:47:40 -04:00
Adrien Béraud
7f48c4808b
network engine: minor cleanup
2019-04-30 17:47:40 -04:00
Adrien Béraud
32a443a1d8
thread pool: add unit test
2019-04-30 17:47:40 -04:00
Adrien Béraud
6d0fcba3b5
thread pool: add Executor
2019-04-30 17:47:40 -04:00
Adrien Béraud
76e2efb19b
peerdiscovery: undef write macro after use
2019-04-26 11:50:25 -04:00
Adrien Béraud
bbe1b9233f
dhtrunner: use recv instead of recvfrom for stoppipe
2019-04-26 02:29:49 -04:00
Adrien Béraud
7558ca0dca
peerdiscovery: unit test cleanup
2019-04-26 02:29:49 -04:00
Adrien Béraud
38141322f1
peerdiscovery: stop threads when stopping services
2019-04-26 02:29:49 -04:00
Adrien Béraud
6c5ea125ca
peerdiscovery: add automatic template serialization
2019-04-26 02:29:49 -04:00
Adrien Béraud
d0362e58e0
dhtnode: update dht instance name
...
Avoid confusion with the namespace
2019-04-25 23:33:22 -04:00
Adrien Béraud
1b3a40f345
dhtrunner: clear stop file descriptor if still running
2019-04-25 22:12:28 -04:00
Adrien Béraud
38d854e6f4
dhtrunner: read correct size from buffer
2019-04-25 22:11:20 -04:00
Adrien Béraud
e0241ccfbd
dhtrunner: drop older packets in batch
2019-04-25 22:10:46 -04:00
Adrien Béraud
d4311925b4
dhtrunner: shutdown: return if not running
2019-04-25 21:38:52 -04:00
Adrien Béraud
9aa56dd464
dhtnode/systemd: use simple service mode
2019-04-25 21:32:35 -04:00
Adrien Béraud
ec3b259ead
dhtnode/systemd: update default bootstrap
2019-04-25 21:18:11 -04:00
Adrien Béraud
332cab10ef
tools: don't chdir to / when deamonizing
2019-04-25 21:17:44 -04:00
Adrien Béraud
85f2b618c7
logs: use ofstream for file logging
2019-04-25 14:31:06 -04:00
Adrien Béraud
bcf18fda53
update to version 1.9.3
2019-04-25 11:10:42 -04:00
Adrien Béraud
6b78a4cad6
peerdiscovery: catch parsing errors
2019-04-25 10:25:36 -04:00
Adrien Béraud
66d3a8aeaa
dhtrunner: cleanup
2019-04-24 14:51:43 -04:00
Adrien Béraud
958cb250a3
dhtnode: show both IPv4, IPv6 bound ports
2019-04-23 12:13:53 -04:00
Adrien Béraud
6a5724a868
peerdiscovery: allow per-domain publish, cleanup
2019-04-23 12:09:08 -04:00
Adrien Béraud
11ac84de54
Merge pull request #392 from MingruiZhangW/peer_discovery_version_2
...
peerdiscovery: modify to add support for sending and receiving msgpack
2019-04-23 11:20:18 -04:00
MingruiZhangW
f65e8c1a1f
Merge branch 'master' into peer_discovery_version_2
2019-04-22 09:13:17 -04:00
Adrien Béraud
c2fdf6ae92
dhtnode: show grouped get results, improve duration display
2019-04-21 21:39:54 -04:00
Adrien Béraud
91a81f64ac
thread pool: make public
2019-04-21 21:39:54 -04:00
Adrien Béraud
17b772e6cc
proxy client: close all sockets before joining
2019-04-20 22:38:36 -04:00
Adrien Béraud
75738ac28b
proxy client: don't hold lock while calling callback
2019-04-20 22:07:48 -04:00
Adrien Béraud
84a2d771c1
dht: add some missing override
2019-04-20 22:07:48 -04:00
Adrien Béraud
f6273f9efc
tools/dhtnode: improve documentation
2019-04-20 17:30:39 -04:00
Adrien Béraud
5881c91510
utils: include config.h
2019-04-19 20:24:01 -04:00
Adrien Béraud
e09c55ca42
update to version 1.9.2
2019-04-19 16:15:56 -04:00
Andreas Traczyk
c737e4690e
update visual studio build
2019-04-19 15:53:42 -04:00
Adrien Béraud
35a9d1f612
proxy client: catch exception in Http::close()
2019-04-18 17:38:00 -04:00
Mingrui Zhang
0f3396cd66
peerdiscovery: make nested classes to hide ip versions
2019-04-18 12:20:17 -04:00
Mingrui Zhang
98cd6cc61e
peerdiscovery: fix memory leakage cased by sbuffer release
2019-04-18 10:20:00 -04:00
Mingrui Zhang
092cb9551e
peerdiscovery: add testpack into tester to verify the possibility of sending & receiving 2 packages simultaneously (including stop functions)
2019-04-18 09:33:15 -04:00
Mingrui Zhang
a2bbca792c
peerdiscovery: add dmtx_ to distinguish send & listen shared resources, add stopDiscovery, stoplisten to stop listen or discover certain type of service
2019-04-17 10:26:49 -04:00
Adrien Béraud
5ec72e213e
dht: add override
2019-04-17 10:00:15 -04:00
Mingrui Zhang
0f51115f44
peerdiscovery: modify maps to handle more services in one instance
2019-04-16 15:11:07 -04:00
Adrien Béraud
683a111726
autotools: build versioned shared library
2019-04-16 12:23:32 -04:00
Adrien Béraud
0fd4fed537
search: add fallback return
2019-04-16 12:23:32 -04:00
Mingrui Zhang
18aa6ddb7b
peerdiscovery: modify function signatures to make service consistent
2019-04-15 18:24:15 -04:00
Mingrui Zhang
0a436e17b0
peerdiscovery: modifications on tester fit for the updates
2019-04-15 17:26:59 -04:00
Mingrui Zhang
763ffddf51
peerdiscovery: modify to add support for sending and receiving msgpack
2019-04-15 16:50:48 -04:00
Adrien Béraud
ef82652a1e
network: header cleanup
2019-04-14 11:30:10 -04:00
Adrien Béraud
4f03a5c64e
network: tid, socket_id, value_id: default to 0
2019-04-14 09:15:16 -04:00
Adrien Béraud
5257ac314f
add API to retrieve version string
2019-04-14 00:19:01 -04:00
Adrien Béraud
0580a4e7dd
update to version 1.9.1
2019-04-13 23:29:43 -04:00
Yanfei Han
fd1f2cd0e4
add peer_discovery.o object into auto configure lib
2019-04-13 23:04:18 -04:00
Adrien Béraud
af940c63b1
proxy: mute unused variable warning if disabled
2019-04-13 23:02:57 -04:00
Adrien Béraud
15da502354
dhtrunner: make peer discovery port static constexpr
2019-04-13 22:56:31 -04:00
Adrien Béraud
b7a9a52f97
network engine: DhtProtocolException cleanup
2019-04-13 22:56:31 -04:00
Adrien Béraud
6e10756e28
peerdiscovery: cleanup
2019-04-13 22:56:31 -04:00
Adrien Béraud
aad4ad03cf
network utils: add missing includes
2019-04-13 22:56:31 -04:00
Adrien Béraud
3d1e055c7b
peerdiscovery: always use local node id
2019-04-13 20:50:00 -04:00
Adrien Béraud
b02e9cfff7
peerdiscovery: flush stop socket if not stopping
2019-04-13 20:50:00 -04:00
Adrien Béraud
453db29058
dht: add override to getNodeId
2019-04-13 20:43:57 -04:00
Adrien Béraud
a8ba536d44
update to version 1.9.0
2019-04-09 16:25:39 -04:00
Adrien Béraud
a238183031
peerdiscovery: don't assign IPv6 multicast interface
2019-04-09 16:11:21 -04:00
Adrien Béraud
73827cd34d
peerdiscovery: allow IPV6_MULTICAST_IF failure
2019-04-09 15:12:37 -04:00
Adrien Béraud
876190a392
peerdiscovery: SO_REUSEADDR, SO_REUSEPORT in different calls
2019-04-09 14:58:22 -04:00
Adrien Béraud
7fe321e4fc
peerdiscovery: cleanup data serialization
2019-04-09 14:57:48 -04:00
Adrien Béraud
7f7075ca9a
peerdiscovery: support IPV6_JOIN_GROUP
2019-04-09 12:31:23 -04:00
Adrien Béraud
9b9f12d87e
tests: accept null token if callback returns false
2019-04-08 15:58:46 -04:00
Adrien Béraud
26ad6de3a4
dhtrunner: avoid race condition when setting token
2019-04-08 15:57:25 -04:00
Adrien Béraud
ae91f8bd55
dhtrunner: default-initialize tokens
2019-04-08 15:36:24 -04:00
Adrien Béraud
28eeee24ba
runnertester: reduce number of test values
2019-04-08 15:35:55 -04:00
Adrien Béraud
671c55a01d
dhtrunner: print peer discovery error message to cerr
2019-04-08 14:36:15 -04:00
Adrien Béraud
a4f2e6efdd
tests: avoid use-after-free in proxytester
2019-04-08 13:06:32 -04:00
Adrien Béraud
60831ee898
peerdiscovery: avoid crashing if message can't be sent
2019-04-08 13:02:39 -04:00
Adrien Béraud
98dbe1cba7
gitignore: ignore files from vscode, eclipse
2019-04-08 12:07:35 -04:00
Adrien Béraud
6c705e525f
net: factorize logic to network_utils
2019-04-08 12:07:11 -04:00
Adrien Béraud
96347d83e1
tools: add argument for peer discovery
2019-04-08 11:34:52 -04:00
Adrien Béraud
01d8e513a1
peerdiscovery: cleanup
2019-04-08 11:34:52 -04:00
Mingrui Zhang
b5921b0d9d
peerdiscovery: error correction for tester, distinguish creation error(ip version support) and listen/receive error
2019-04-08 11:32:08 -04:00
Mingrui Zhang
8ee7883c53
peerdiscovery: Exception added for supporting construction error
2019-04-08 11:32:08 -04:00
Mingrui Zhang
4240820463
peerdiscovery: add multicast node discovery mechanism
2019-04-08 11:32:08 -04:00
Adrien Béraud
7ebbf17f37
InfoHash: use static size
2019-04-05 11:21:23 -04:00
Adrien Béraud
6821e5bd96
dhtrunner: default to null function instead of AllFilter
2019-04-05 10:49:40 -04:00
Adrien Béraud
c4ec1e78e0
tests: fix occasional testListen failure
2019-04-05 10:49:35 -04:00
Adrien Béraud
e86d717e81
dht: make getPut() const
2019-04-05 10:49:35 -04:00
Adrien Béraud
db2b48d2af
dhtrunner: select on maxfd+1
2019-04-03 16:18:35 -04:00
Adrien Béraud
2b938110fd
cmake: force indexation if python is enabled
2019-04-03 14:52:35 -04:00
Adrien Béraud
c647b19e91
infohash: make some methods constexpr, noexcept
2019-04-03 14:52:35 -04:00
Sébastien Blin
8cd14646a6
Merge pull request #387 from savoirfairelinux/cert_request
...
crypto: add certificate request support
2019-04-01 09:30:33 -04:00
Adrien Béraud
d80aab9399
pingpong: cleanup
2019-03-29 13:13:29 -04:00
Adrien Béraud
9b881d4e95
crypto: add initial certificate request support
2019-03-29 13:13:29 -04:00
Adrien Béraud
b4c3c2cba0
update to version 1.8.2
2019-03-18 13:47:41 -04:00
Sébastien Blin
4519a23996
Merge pull request #386 from savoirfairelinux/parse_perf
...
Network: improve parsing performance
2019-03-18 13:13:57 -04:00
Adrien Béraud
1ac4e08f45
build: add clang-tidy configuration
2019-03-17 19:23:26 -04:00
Adrien Béraud
5e92777702
fix clang-tidy warnings
2019-03-17 19:22:28 -04:00
Adrien Béraud
4401e47002
cleanup, fix clang-tidy warnings
2019-03-17 17:43:52 -04:00
Adrien Béraud
215b44ca3b
search: don't store filter in search
...
Filter is not supported anymore at the search listen stage.
Filters are now stored and called by the op cache.
2019-03-17 17:30:30 -04:00
Adrien Béraud
379fdae212
cmake: don't explicitly disable stack protector
2019-03-17 16:07:20 -04:00
Adrien Béraud
1e10e28fd7
network: improve message parsing performance
2019-03-17 16:07:20 -04:00
Adrien Béraud
dccdb84836
tests: add Value tester
2019-03-16 14:27:46 -04:00
Adrien Béraud
71599da8ea
value: add "not" method
2019-03-16 14:27:23 -04:00
Adrien Béraud
f418b3651f
update copyright date
2019-03-16 12:37:23 -04:00
Adrien Béraud
313f54c840
dht: disable some verbose logs
2019-03-10 17:27:37 -04:00
Adrien Béraud
cdb721ade4
dht: move store logic to storage
2019-03-10 17:04:26 -04:00
Adrien Béraud
57ea09808e
value: fix chain null check
2019-03-10 16:39:31 -04:00
Adrien Béraud
fec5a6ede7
make move operators noexcept
2019-03-10 16:39:16 -04:00
Adrien Béraud
5f8e9d9480
storage: make non-movable
2019-03-10 16:39:16 -04:00
Adrien Béraud
311a8981fc
thread pool: add computation, io pools
2019-03-10 16:39:16 -04:00
Adrien Béraud
04850e1701
dht: add configuration to persist state
2019-03-10 16:39:16 -04:00
Adrien Béraud
a30f1b8032
dht: make exportNodes const
2019-03-10 16:39:16 -04:00
Sébastien Blin
41f8b06743
Merge pull request #376 from savoirfairelinux/server_thread_pool
...
Server thread pool
2019-02-19 19:57:13 -05:00
Adrien Béraud
1c74c2207f
proxy server: cache json StreamBuilder
2019-02-19 18:43:14 -05:00
Adrien Béraud
9319bec7b8
proxy client: close previous request on resubscribe
2019-02-19 18:43:14 -05:00
Adrien Béraud
e5f2a6eef5
proxy: send expired to sync values
2019-02-19 18:43:14 -05:00
Adrien Béraud
55f6c847b8
build: use define flags for proxy
2019-02-19 18:43:14 -05:00
Adrien Béraud
00cc4ebe28
proxy server: send push notification on thread pool
2019-02-19 18:43:14 -05:00
Adrien Béraud
aa93db4fa6
proxy server: move json to sendPushNotification
2019-02-19 18:43:14 -05:00
Adrien Béraud
683570a3da
add ThreadPool
2019-02-19 18:43:14 -05:00
Sébastien Blin
43559577f6
Merge pull request #377 from savoirfairelinux/proxy_sync_expired
...
Proxy: sync expired state
2019-02-19 18:42:32 -05:00
Adrien Béraud
ba2e179abe
dht: optimize get
2019-02-19 01:59:59 -05:00
Adrien Béraud
a5d29c904c
op cache: optimize cache insertion
2019-02-19 01:59:59 -05:00
Adrien Béraud
989f32eb56
filter: cleanup and optimize
2019-02-19 01:59:59 -05:00
Adrien Béraud
b66fa73c56
test: include cppunit headers
2019-02-19 01:59:59 -05:00
Adrien Béraud
1ca181db1d
value: simplify expression
2019-02-19 01:59:59 -05:00
Adrien Béraud
1f3bf697c3
search: use syncStatus for get
2019-02-19 01:59:59 -05:00
Adrien Béraud
a1f8cc906c
proxy client: use SyncCallback
2019-02-19 01:59:59 -05:00
Adrien Béraud
35c6a57526
dht: add synced status
2019-02-19 01:59:59 -05:00
Adrien Béraud
39e69f813c
network engine: cleanup
2019-02-19 01:59:59 -05:00
Sébastien Blin
8045c2cbf2
dhtrunner: avoid startNetwork failure if only one binding is failing
2019-02-19 01:44:47 -05:00
Sébastien Blin
79a2f4280f
proxy: resolve url with protocol and port
2019-02-14 11:04:11 -05:00
Sébastien Blin
769ce45740
proxy_client: support prototype in serverHost
2019-01-22 07:56:27 -08:00
Sébastien Blin
75a14d3608
proxy: only get old values at first subscribe
2019-01-18 22:53:24 -08:00
Sébastien Blin
d523e9f259
tests: test retrieve values when resubscribe
2019-01-14 10:53:08 -08:00
Sébastien Blin
3a3933e6d5
dhtproxy: remove sendSubscribe
2019-01-14 10:53:08 -08:00
Sébastien Blin
70f09ded3f
dhtproxy: avoid notification after subscribe to retrieve values
2019-01-14 10:53:08 -08:00
Sébastien Blin
824a1bf5fa
proxy_server: return old values when resubscribe
2019-01-14 10:53:08 -08:00
Sébastien Blin
e5b56cc0a5
dht: link to tellListenerRefreshed
...
When a permanent put is refreshed, the node has to tell to its
remote listeners that the value is refreshed.
2019-01-09 13:34:51 -08:00
Sébastien Blin
36cf70f2a7
proxy: remove useless token for push listeners
...
Since we authentificate listeners with the clientId and the hash and
we use only one listener by hash/clientId, we doesn't need to store
a token always equals to 0.
Note: also avoid to get multiple hashes for one push notification.
2018-12-30 13:35:18 -05:00
Adrien Béraud
459c1344aa
update to version 1.8.1
2018-12-28 11:38:15 -05:00
Adrien Béraud
c0e376e15a
dht: reduce log verbosity
2018-12-28 01:41:10 -05:00
Adrien Béraud
71b9672b96
value: don't print certificate id in toString by default
2018-12-28 01:38:45 -05:00
Adrien Béraud
086f37a71a
op cache: remove listener if callback returned false
2018-12-28 01:38:02 -05:00
Adrien Béraud
87e76a5e4e
tests: reverse nodes
2018-12-26 13:03:36 -05:00
Adrien Béraud
7f0a5dfda3
dht: increase max number of searches and hashes
2018-12-26 10:28:55 -05:00
Adrien Béraud
6d7f8004bf
connectivity change: reset routing table instead of searches
2018-12-26 10:28:30 -05:00
Adrien Béraud
8168c39b63
dht: cleanup
2018-12-26 01:22:37 -05:00
Adrien Béraud
d0fdbe5340
dhtrunner: print proper message on bind error
2018-12-26 00:58:43 -05:00
Adrien Béraud
c7604fbb8d
tests: wait for put before performing get
2018-12-26 00:56:49 -05:00
Adrien Béraud
56773baa98
unit tests: add listen test
2018-12-24 19:09:32 -05:00
Adrien Béraud
e6cf67c575
dht: clear local listener if callback returns false
2018-12-24 18:37:06 -05:00
Adrien Béraud
00ebc5e2bf
op cache: check callback return value
2018-12-24 18:36:29 -05:00
Adrien Béraud
ccef94c11b
Revert "storage: make non-movable"
...
This reverts commit 7ebad7d3c5 .
2018-12-24 17:16:15 -05:00
Adrien Béraud
0066be49b9
python: add more bindings for SockAddr
2018-12-24 16:55:25 -05:00
Adrien Béraud
592ed4ee90
op cache: don't call callback if no value
2018-12-24 15:50:41 -05:00
Adrien Béraud
353a6f9db6
op cache: add onCancel callback
2018-12-24 15:41:17 -05:00
Adrien Béraud
7ebad7d3c5
storage: make non-movable
2018-12-24 15:28:03 -05:00
Adrien Béraud
14f6e6e5f3
proxy client: catch exceptions in restbed::Http::async
2018-12-22 23:45:37 -05:00
Adrien Béraud
9ce5b30931
securedht: use query to check for existing value
2018-12-22 11:42:45 -05:00
Adrien Béraud
92979fa96a
dhtchat: add logging support
2018-12-21 19:55:27 -05:00
Adrien Béraud
0c1e7d2763
dht: run node confirmation if bucket was empty
2018-12-19 14:07:55 -05:00
Adrien Béraud
14a744f6cd
dht: log cleanup
2018-12-19 14:07:55 -05:00
Adrien Béraud
3b26684a87
network engine: add default values for sendFindNodes
2018-12-19 14:07:55 -05:00
Sébastien Blin
0a764ee440
Merge pull request #361 from savoirfairelinux/schedule_restart
...
proxy client: schedule listener restart
2018-12-18 16:07:39 -05:00
Adrien Béraud
7dda5a3d5a
proxy client: schedule listener restart
2018-12-18 10:10:14 -05:00
Adrien Béraud
306d573223
proxy client: fix race condition
2018-12-17 16:41:00 -05:00
Sébastien Blin
20f4355b73
Merge pull request #356 from savoirfairelinux/build
...
securedht: add override
2018-12-11 14:52:07 -05:00
Adrien Béraud
a2d7cd56a8
Merge pull request #358 from atraczyk/master
...
replace _write with send when building for windows
2018-12-11 14:48:26 -05:00
Andreas Traczyk
5cd53f3624
replace _write with send when building for windows
2018-12-11 14:37:14 -05:00
Adrien Béraud
32eea55f10
autotools: don't build doc if doxygen not found
2018-12-11 14:04:35 -05:00
Adrien Béraud
f2f913f93f
securedht: add override for relevant methods
2018-12-11 14:04:35 -05:00
Adrien Béraud
cb9fe9d1fe
Merge pull request #354 from atraczyk/master
...
msvc: replace write with _write when building on windows
2018-12-06 12:23:36 -05:00
Andreas Traczyk
dcab32ef4f
replace write with _write when building with msvc
2018-12-06 12:16:59 -05:00
Adrien Béraud
4948bd7ad3
node cache: remove expired weak pointers from cache
...
Remove expired Node weak pointers regularly,
in a way that ensures that:
* every expired pointer gets eventually cleaned up
* expired pointer ratio remains reasonably low
* no cleanup pass blocks the node for too long,
* impact on performance is negligible
Impact on performance:
Every N insertions, at most N nodes are tested by iterating the map
-> performance impact in O(1) (constant).
2018-11-29 19:27:32 -05:00
Adrien Béraud
4416b91461
update to version 1.8.0
2018-11-28 18:44:03 -05:00
Adrien Béraud
378ae396f0
Merge pull request #351 from hanyf/master
...
A obvious bug on network engine
2018-11-28 12:48:02 -05:00
Yanfei Han
dc4a790a38
A obviouse bug on network engine
2018-11-29 00:47:00 +08:00
Sébastien Blin
07dd8f5648
Merge pull request #350 from savoirfairelinux/feature/cache
...
Feature/cache
2018-11-28 09:22:06 -05:00
Adrien Béraud
f7433a2289
travis: update to xenial
2018-11-26 16:48:00 -05:00
Adrien Béraud
ce4a65ff00
dhtrunner: add APIs for listen<T> with expiration information
2018-11-26 16:34:19 -05:00
Adrien Béraud
092f5cfef0
network_engine: fix warning
2018-11-26 16:34:19 -05:00
Adrien Béraud
12a45e7558
cmake: remove unnecessary flags for lto
2018-11-26 16:30:18 -05:00
Adrien Béraud
18d359a7d2
dht: refresh value if already exists
2018-11-26 01:57:57 -05:00
Adrien Béraud
c6bb67d1ac
dht: add storageRefresh
2018-11-26 01:57:57 -05:00
Adrien Béraud
f4cd7636ce
securedht: use signature cache in storePolicy, editPolicy
2018-11-26 01:57:57 -05:00
Adrien Béraud
2dd4e640c4
dhtrunner: add APIs for listen<T> with expiration information
2018-11-25 23:01:03 -05:00
Adrien Béraud
9a301e3590
Revert "cmake: use CMAKE_INTERPROCEDURAL_OPTIMIZATION for LTO"
...
This reverts commit b7b5152348 .
2018-11-24 15:32:29 -05:00
Sébastien Blin
aa16b9a235
Merge pull request #348 from savoirfairelinux/feature/probepermanent
...
dht: don't send probe query for non permanent puts
2018-11-23 10:10:35 -05:00
Adrien Béraud
b2542a57df
securedht: cache value signature check/decryption results
2018-11-22 15:43:55 -05:00
Adrien Béraud
00c1be9cdc
logger: use DBG for DEBUG to avoid name conflicts
2018-11-22 15:43:55 -05:00
Adrien Béraud
e414ca89c7
dht: don't send probe query for non permanent puts
2018-11-22 15:43:55 -05:00
Adrien Béraud
4d26537b93
Merge pull request #346 from AmarOk1412/fix/finished
...
dht_proxy_client: fix finished behavior
2018-11-11 22:19:50 -05:00
Sébastien Blin
00a9333de7
dht_proxy_client: fix finished behavior
...
callback_.emplace_back() returns immediately, so, in some case,
finished can be set to true even before we execute one callback.
Finished should not be used into callback. This patch adds a
finished variable only used by the callbacks to avoid this
case.
This improve the reactivity of the proxy client.
2018-11-11 15:27:57 -05:00
Adrien Béraud
971f96bf95
dhtrunner: improve getId()/getNodeId() documentation.
2018-10-29 16:23:21 -04:00
Adrien Béraud
f9a12a9dca
crypto: use proper size for getRandom()
...
Provided size should be the number of elements, not the number of bytes.
Also, if secure_vector where used with sizeof(T) > 1 (currently not the case),
there would be memory write to invalid address.
2018-10-29 16:21:51 -04:00
Adrien Béraud
c05a93ae54
proxy server: cleanup
2018-10-29 12:45:52 -04:00
Adrien Béraud
ff83a6daab
proxy: support value expiration
2018-10-29 12:45:52 -04:00
Adrien Béraud
b7b5152348
cmake: use CMAKE_INTERPROCEDURAL_OPTIMIZATION for LTO
2018-10-27 16:38:37 -04:00
Adrien Béraud
a3768d1e50
cmake: use LINK_FLAGS for LTO
2018-10-27 14:57:51 -04:00
Adrien Béraud
94926cea22
proxy server: avoid early session close
2018-10-27 13:21:26 -04:00
Adrien Béraud
82ca2d1993
cmake: use single target_link_libraries for static library
2018-10-27 12:30:40 -04:00
Adrien Béraud
3e148599c5
proxy server: stop get if session is closed
2018-10-27 12:20:00 -04:00
Adrien Béraud
02d5592fdb
cmake: improve restbed, jsoncpp search & usage
2018-10-27 11:51:42 -04:00
Adrien Béraud
328b306fd0
crypto: add documentation
2018-10-27 11:50:26 -04:00
Adrien Béraud
522a89b6f8
dht: use search cache for get ops
2018-10-27 11:49:55 -04:00
Adrien Béraud
897b451f44
crypto: fix build on Win32
2018-10-26 13:16:02 -04:00
Adrien Béraud
ba3a42697c
Merge pull request #331 from Dale-M/master
...
Some additions to automake infrastructure to get clean default build.
2018-09-20 14:24:34 -04:00
Adrien Béraud
5112a322de
dht: reschedule permanent put refresh after request
2018-09-19 01:54:54 -04:00
Adrien Béraud
85961c6a62
storage: properly refresh expiration
2018-09-19 01:54:54 -04:00
Adrien Béraud
1eb1f3d5ac
storageStore: add permanent mode
2018-09-19 01:54:54 -04:00
Adrien Béraud
726c138d90
dht: move storageStore to put
2018-09-19 01:54:54 -04:00
Adrien Béraud
1b6b1ca072
comments: fix typos
2018-09-19 01:54:54 -04:00
Dale Mellor
77da72c603
Some additions to automake infrastructure to get clean default build.
...
Be sure to pull in paths to headers for json and MsgPack dependencies.
Be sure to always build the base64 encoder and decoder, as they are
needed.
2018-09-17 09:40:07 +01:00
Adrien Béraud
7fb2da7c54
dhtrunner: avoid polling, use pipe to stop select
2018-09-15 17:22:12 -04:00
Sébastien Blin
6721a272ea
Merge pull request #327 from savoirfairelinux/value_cache
...
value_cache: expire value if expiration is now
2018-08-12 10:42:22 -04:00
Adrien Béraud
246af2f065
value_cache: expire value if expiration is now
2018-08-11 21:27:18 -04:00
Adrien Béraud
57aba453b0
Merge pull request #325 from AmarOk1412/siteProxy
...
proxyserver: add stats endpoint for monitoring
2018-08-10 15:05:07 -04:00
Sébastien Blin
f54fcd768f
proxyserver: add stats endpoint for monitoring
2018-08-10 15:03:09 -04:00
Sébastien Blin
5b81476baf
Merge pull request #326 from savoirfairelinux/tests
...
tests: add unit tests for certificate revocation
2018-08-09 17:11:20 -04:00
Adrien Béraud
5b510cadfb
tests: add unit tests for certificate revocation
2018-08-09 14:51:02 -04:00
Adrien Béraud
c794781644
update to version 1.7.4
2018-07-31 13:45:56 -04:00
Adrien Béraud
2ef4999b0f
Merge pull request #322 from AmarOk1412/incorrectOk
...
dhtproxyclient: fix ok when a permanent PUT operations fails
2018-07-31 10:16:05 -04:00
Sébastien Blin
6069fba18f
dhtproxyclient: fix ok when a permanent PUT operations fails
2018-07-31 09:42:23 -04:00
Adrien Béraud
37ddd8c7f9
update to version 1.7.3
2018-07-25 16:40:47 -04:00
Adrien Béraud
23057a3082
unit tests: fix race condition
2018-07-25 11:54:28 -04:00
Adrien Béraud
dbdd3f8f63
Merge pull request #319 from AmarOk1412/fixLD
...
dhtrunner: don't use listeners structure without proxy client enabled
2018-07-25 11:32:55 -04:00
Sébastien Blin
751e79a250
dhtrunner: don't use listeners structure without proxy client enabled
...
The token used to cancel a listener was wrong. Indeed, tokenBGlobal
was used to get the linked listener, not to identify the listener
inside dhtrunner.
2018-07-25 11:28:46 -04:00
Adrien Béraud
7a961ffc51
Merge pull request #318 from atraczyk/master
...
build: replace WIN32_NATIVE macro with _MSC_VER
2018-07-23 14:01:17 -04:00
Andreas Traczyk
bfada958b9
build: replace WIN32_NATIVE macro with _MSC_VER
2018-07-23 13:45:52 -04:00
Sébastien Blin
78d91a8e0d
Merge pull request #316 from savoirfairelinux/proxy_server
...
dhtrunner: decrease max packet handling delay to 500ms
2018-07-13 14:37:09 -04:00
Adrien Béraud
cd5dc38a57
dhtrunner: decrease max packet handling delay to 500ms
...
Allows for faster recovery in case of CPU contention
2018-07-13 14:29:59 -04:00
Sébastien Blin
1ff2eeb220
Merge pull request #313 from savoirfairelinux/proxy_server
...
Proxy server
2018-06-28 09:16:13 -04:00
Adrien Béraud
ffbb9e23ef
dht: show usage at the end, print max store size
2018-06-27 11:54:15 -04:00
Adrien Béraud
af0a30c9c5
dhtrunner: drop oldest packet if queue is full
2018-06-26 20:41:04 -04:00
Sébastien Blin
97d5e3875d
Merge pull request #312 from savoirfairelinux/dht_performance
...
Dht performance
2018-06-21 11:49:09 -04:00
Adrien Béraud
2509e8bc5c
Revert "search: use pointer to SearchNode"
...
This reverts commit 3a41f2ce56 .
2018-06-20 14:50:40 -04:00
Adrien Béraud
e349912c07
search: improve canGet performance
2018-06-20 14:50:40 -04:00
Adrien Béraud
a1fc266eac
dhtrunner: add max rx queue size
2018-06-19 14:10:57 -04:00
Adrien Béraud
3e3679bebf
dhtrunner: drop packet if processing took too long
2018-06-18 15:52:20 -04:00
Adrien Béraud
e9cf16f361
cmake: allow to enable push notifications without proxy server
2018-06-15 21:09:37 -04:00
Adrien Béraud
3dca4db408
dhtrunner: don't setProxyServer in headers
...
Don't define setProxyServer in headers since it depends on a configuration option
2018-06-15 12:18:56 -04:00
Sébastien Blin
fb6d290692
Merge pull request #309 from savoirfairelinux/searchnode
...
SearchNode: refresh token
2018-06-13 10:35:51 -04:00
Adrien Béraud
96c60d39ed
proxy server: reschedule after using function
2018-06-12 18:19:12 -04:00
Adrien Béraud
3a41f2ce56
search: use pointer to SearchNode
2018-06-12 16:54:12 -04:00
Adrien Béraud
5bd88533fe
SearchNode: refresh token in Query, Listen answers
2018-06-12 16:50:15 -04:00
Adrien Béraud
c48e24403b
Merge pull request #296 from AmarOk1412/resub
...
proxy: refresh puts and subscriptions when connectivity changes
2018-06-06 12:18:58 -04:00
Sébastien Blin
3cf2c092f2
proxy: remove useless convertion from InfoHash to InfoHash
2018-06-06 12:16:10 -04:00
Sébastien Blin
aef8aa545b
proxy: reschedule printStatsJob
2018-06-06 12:08:31 -04:00
Sébastien Blin
0c61a605ad
proxy: refresh puts and subscriptions when connectivity changes
2018-06-06 11:29:40 -04:00
Sébastien Blin
e6b247bead
Merge pull request #307 from savoirfairelinux/crypto_tests
...
test: add crypto unit test
2018-06-06 10:05:10 -04:00
Sébastien Blin
6f1f18f128
Merge pull request #302 from savoirfairelinux/getnodeinfo
...
dhtrunner: add getNodeInfo()
2018-06-06 10:04:57 -04:00
Adrien Béraud
f24458860d
test: add crypto unit test
2018-06-06 01:12:18 -04:00
Adrien Béraud
07bed77714
proxy server: schedule task from outside thread
2018-06-05 19:43:56 -04:00
Adrien Béraud
aa202b2cd8
dhtrunner: add getNodeInfo()
...
Allow to retrieve all dht stats in a single API call using
the new method getNodeInfo() and the JSON-serializable
new structure NodeInfo.
2018-06-05 19:43:56 -04:00
Adrien Béraud
4c89ce9d3f
Merge pull request #303 from AmarOk1412/getNodeStats
...
dht_proxy_server: avoid mutex when getting /
2018-05-30 17:01:56 -04:00
Sébastien Blin
709a2c7b7c
dht_proxy_server: avoid mutex when getting /
...
The dht_proxy_server should be always up, so getNodesStats will
be pretty always up-to-date. We can add it into a job and avoid
to wait for this method to finish (and this method use an
internal lock) to have a quick answer about the status of the proxy.
Note: the update is forced during the initialization of the proxy
2018-05-30 14:25:46 -04:00
Adrien Béraud
b7e483078a
proxy: fix typo
2018-05-25 10:26:58 -04:00
Adrien Béraud
b2171d707a
network engine: properly apply flag MSG_NOSIGNAL
2018-05-25 10:26:58 -04:00
Adrien Béraud
60db9fd9cd
logs: reduce node expiration to debug level
2018-05-25 10:26:58 -04:00
Adrien Béraud
e8989f1f79
network engine: handle EPERM
2018-05-24 16:07:16 -04:00
Adrien Béraud
b7218bd1c9
Merge pull request #299 from savoirfairelinux/tests
...
travis: run CI with ASAN
2018-05-24 15:46:56 -04:00
Adrien Béraud
43aab40968
travis: run CI with ASAN
2018-05-24 15:31:52 -04:00
Sébastien Blin
ed57b3bfa9
Merge pull request #300 from savoirfairelinux/leak
...
network engine: fix node leak during destruction
2018-05-24 15:14:22 -04:00
Adrien Béraud
9249f34c47
network engine: fix node leak during destruction
2018-05-24 15:01:23 -04:00
Sébastien Blin
57401e8d53
Merge pull request #297 from savoirfairelinux/logs
...
log: fix LogMethod copy
2018-05-24 14:55:06 -04:00
Adrien Béraud
f5f71a0365
log: fix LogMethod copy
2018-05-24 11:57:12 -04:00
Adrien Béraud
1fe9f2fdb1
dhtnode: default-initialize dht config
2018-05-23 11:21:25 -04:00
Sébastien Blin
59d129b8ff
Merge pull request #293 from savoirfairelinux/proxy_fixes
...
Proxy fixes
2018-05-17 14:47:16 -04:00
Adrien Béraud
5b5349d7ad
proxy client: lock proxy info thread, catch detach exceptions
2018-05-17 11:34:25 -04:00
Adrien Béraud
b2ba1ca002
proxy server: close socket if no token
2018-05-17 11:33:32 -04:00
Adrien Béraud
8606e87684
proxy client: allow concurrent proxy info requests ( #292 )
2018-05-11 15:47:24 -04:00
Adrien Béraud
e4f640f11b
update to version 1.7.2
2018-05-08 15:58:24 -04:00
Adrien Béraud
e31d301d90
dhtrunner: run connectivityChanged() even when disconnected
2018-05-08 15:58:24 -04:00
Adrien Béraud
2a15435be3
Merge pull request #291 from AmarOk1412/fixPushIdle
...
proxy: set status to CONNECTED when receiving a push notifications
2018-05-08 13:46:59 -04:00
Adrien Béraud
44a411ba96
Merge pull request #279 from savoirfairelinux/testsproxy
...
tests: begin tests for dht_proxy_server
2018-05-08 13:46:42 -04:00
Sébastien Blin
bf2f2369b1
proxy: set status to CONNECTED when receiving a push notifications
...
If a device receives a push notification, we can assume that the
proxy is up and running (because it sends a push notification).
Indeed, if the proxy is declared as disconnected, no operatons will
be executed when a push notification is received. This state is logic
when not using push notifications (because the local node is down),
but here, the status depends more on the proxy than the local node.
2018-05-08 13:35:13 -04:00
Adrien Béraud
b8b1f61268
search: announce immediately if synced and not pending/completed
2018-05-07 17:43:31 -04:00
Adrien Béraud
63db2eafd9
dht: print detailed request state in search log
2018-05-07 17:43:31 -04:00
Adrien Béraud
68f52a815d
proxy client: refactor ( #289 )
...
Factor various ways of sending listen requests.
2018-05-07 14:54:32 -04:00
Adrien Béraud
9f35acf559
dhtnode: continue cmd loop on connectivity change
2018-05-05 18:23:52 -04:00
Adrien Béraud
d8e82ca7c4
dhtrunner: check dht before getting public addresses
2018-05-04 21:41:39 -04:00
Adrien Béraud
981bcfc0ba
dht: handle error when sending listen
2018-05-02 14:26:24 -04:00
Adrien Béraud
4a49a53222
Revert "network engine: expire node on next run on network failure"
...
This reverts commit 8489433060 .
2018-05-02 11:55:01 -04:00
Sébastien Blin
9f987e24fe
Merge pull request #277 from savoirfairelinux/proxy_refresh
...
proxy client: independently resubscribe push listeners
2018-04-30 10:56:18 -04:00
Sébastien Blin
95f1d59a7f
proxy: add comment for refresh job
2018-04-30 10:42:39 -04:00
Adrien Béraud
a4fe27223f
immessage: fix warning
2018-04-30 10:40:47 -04:00
Adrien Béraud
5408dc6f09
Merge pull request #287 from AmarOk1412/immsgwithdt
...
immessage: add support for custom datatypes
2018-04-27 13:34:23 -04:00
Adrien Béraud
35d4c1d332
Merge pull request #288 from AmarOk1412/restartListenerWithoutPush
...
proxy: restart listeners if the proxy server close the connection
2018-04-27 13:33:59 -04:00
Sébastien Blin
c583b7284c
tests: add testListen for DhtProxyTester
2018-04-26 17:05:23 -04:00
Sébastien Blin
2ce0c5c4c9
proxy: restart listeners if the proxy server close the connection
...
Detect if the proxy server close the connection linked to a listener and
relaunch listeners
2018-04-26 16:45:14 -04:00
Sébastien Blin
484194c114
immessage: add support for custom datatypes
2018-04-23 17:39:37 -04:00
Adrien Béraud
b26b78c049
dhtrunner: fix warnings
2018-04-21 17:57:59 -04:00
Adrien Béraud
522a15c410
proxy client: refresh persistent put with margin
2018-04-21 17:57:59 -04:00
Adrien Béraud
6a981772fd
proxy server: cleanup
2018-04-21 17:57:59 -04:00
Adrien Béraud
cc37fb50e2
proxy client: take persistent put by reference
2018-04-21 17:44:45 -04:00
Adrien Béraud
1c9acfe001
proxy client: call opFailed on failure
2018-04-21 15:08:48 -04:00
Adrien Béraud
c6cef856f0
proxy server: cleanup
2018-04-21 12:23:33 -04:00
Adrien Béraud
9f503dbb65
proxy client: loopSignal on put refresh notification
2018-04-21 12:22:58 -04:00
Adrien Béraud
7e4478123f
proxy client: use time_point::max() on persistent put
2018-04-21 12:22:00 -04:00
Adrien Béraud
e54d26aaf7
dhtrunner: handle push notification on main dht loop
2018-04-21 12:21:00 -04:00
Adrien Béraud
ee749d1ea7
update to version 1.7.1
2018-04-20 22:21:15 -04:00
Adrien Béraud
a0d77e7b19
Merge pull request #283 from savoirfairelinux/fixPush
...
proxy server, fix push listeners and avoid flooding nodes
2018-04-20 18:46:04 -04:00
Sébastien Blin
9421984a89
proxy: cancelPushListeners using clientId instead of token
...
All listeners uses a token equals to 0, we need to identify listeners
with client_id instead of a token.
2018-04-20 16:37:12 -04:00
Sébastien Blin
37ef1c2cff
proxy: set clientId to listener
...
clientId was not properly set. so every time someone launch a node
and do a listen on a hash, a new listener is generated and it results
by flooding the node of push notifications.
2018-04-20 16:19:03 -04:00
Sébastien Blin
0a04a7f28d
proxy: unsubscribe is now valid with token equals 0
...
Because we now have one listener for each client by hash, the token
is unnecessary here. Moreover, this check is invalid cause we use
a token equal to 0.
2018-04-20 15:25:57 -04:00
Sébastien Blin
b47a85fe09
Merge pull request #282 from savoirfairelinux/op_time_cache
...
op cache: keep listeners alive for some time after cancel
2018-04-20 13:43:32 -04:00
Adrien Béraud
4b7b3cd518
dhtrunner: use proper token with cancelListen(future<token>)
2018-04-20 13:35:13 -04:00
Adrien Béraud
1a2d783c2a
op cache: keep listeners alive for some time after cancel
2018-04-20 11:35:45 -04:00
Sébastien Blin
7f943e07a5
tests: begin tests for dht_proxy_server
...
Like dhtrunnertester add testGetPut for the dht_proxy_server.
2018-04-19 13:08:26 -04:00
Adrien Béraud
f98658f10f
proxy client: independently resubscribe push listeners
2018-04-19 11:32:22 -04:00
Adrien Béraud
8b6dcb1cd5
dhtnode: allow to trigger connectivity change
2018-04-19 11:31:08 -04:00
Adrien Béraud
e140116fed
proxy client: close old socket when restarting listeners
2018-04-19 11:31:08 -04:00
Sébastien Blin
c16a65a055
Merge pull request #276 from savoirfairelinux/proxy_refresh
...
Proxy/subscribe: improve refresh/cancel behavior
2018-04-16 15:41:19 -04:00
Adrien Béraud
da1b7d4615
proxy server: send refresh notification with margin
2018-04-16 15:05:28 -04:00
Adrien Béraud
7b3ce69b62
proxy client: send remote token on cancel
2018-04-16 15:04:57 -04:00
Adrien Béraud
8a52a7f72a
build: add missing files, cleanup
2018-04-16 14:17:52 -04:00
Adrien Béraud
abb9f9291b
proxy server: avoid unneeded copy
2018-04-14 18:15:02 -04:00
Adrien Béraud
e533f5686e
proxy server: use std::lock to avoid deadlock
2018-04-14 18:14:42 -04:00
Adrien Béraud
4234908b69
proxy server: check refresh job
2018-04-13 15:59:46 -04:00
Adrien Béraud
c10c4251b0
proxy server: print stats to stdout once in a while
2018-04-13 15:52:56 -04:00
Adrien Béraud
8b90c47379
proxy server: add logs
2018-04-13 15:06:49 -04:00
Sébastien Blin
fae6b13897
Merge pull request #275 from savoirfairelinux/proxy
...
proxy server: catch exceptions in requests, always close connection
2018-04-13 14:17:04 -04:00
Adrien Béraud
a48a965c1a
proxy server: catch exceptions in requests, always close connection
2018-04-13 14:01:09 -04:00
Adrien Béraud
ab0f4f6f17
proxy client: refresh now in case of refresh notification
2018-04-13 11:14:40 -04:00
Adrien Béraud
e3114cd5b9
proxy client: catch name resolving exception
2018-04-13 11:09:34 -04:00
Adrien Béraud
8489433060
network engine: expire node on next run on network failure
2018-04-11 11:27:46 -04:00
Sébastien Blin
6594d90042
Merge pull request #273 from savoirfairelinux/proxy_single_push
...
proxy server: keep only one push listener per token/key
2018-04-11 10:24:14 -04:00
Adrien Béraud
7c5145bca5
dhtnode: don't maintain storage
2018-04-10 16:01:14 -04:00
Adrien Béraud
e088cd10be
proxy server: keep only one push listener per token.key.clientId
2018-04-10 16:01:14 -04:00
Adrien Béraud
6a2f61a0db
dht: fix compilation warnings
2018-04-10 12:48:19 -04:00
Adrien Béraud
7b88a2122a
proxy: always use string tokens
2018-04-10 12:48:19 -04:00
Sébastien Blin
f9cf95d537
Merge pull request #272 from savoirfairelinux/proxy_client
...
Proxy client: multiple improvements and bug fixes
2018-04-09 12:21:29 -04:00
Adrien Béraud
4884306135
proxy client: restart listeners on reconnect
...
* track IPv4, IPv6 connectivity seperately
* properly restart listeners when connected
* get proxy info in parallel for multiple AF
2018-04-08 19:54:43 -04:00
Adrien Béraud
fd11a4b3e4
proxy client: prevent callback during cancelAllListeners
2018-04-08 19:54:00 -04:00
Adrien Béraud
b3c637536f
proxy client: prevent use-after-free after destruction
2018-04-08 19:54:00 -04:00
Adrien Béraud
1436af0321
value cache: prevent callback copy on move
2018-04-08 19:54:00 -04:00
Adrien Béraud
1debe012c1
proxy client: restart listeners on connectivity change
2018-04-08 19:54:00 -04:00
Adrien Béraud
368a842d2e
proxy client: don't block resolving address
2018-04-08 19:53:59 -04:00
Adrien Béraud
d250e9b630
proxy client: avoid sending listen with push notifications
2018-04-08 19:53:59 -04:00
Adrien Béraud
3ff6863287
proxy client: add logs
2018-04-08 19:53:59 -04:00
Sébastien Blin
96621ea332
Merge pull request #271 from savoirfairelinux/proxy_client_use_after_free
...
proxy client: retrieve search from callback
2018-04-06 13:13:07 -04:00
Adrien Béraud
567fa1c703
proxy client: retrieve search from callback
2018-04-06 11:43:51 -04:00
Adrien Béraud
20ab71aba6
securedht: check public key
2018-04-05 14:23:15 -04:00
Adrien Béraud
1acace1b91
proxy client: add missing mutex, cleanup
2018-04-05 02:35:01 -04:00
Adrien Béraud
2f423fec48
crypto: check public key for null before pack or print
2018-04-05 02:33:58 -04:00
Adrien Béraud
7be550bf94
value cache: use single callback
2018-04-05 02:08:58 -04:00
Adrien Béraud
a8c0340bf1
Merge pull request #269 from AmarOk1412/removeCallbackId
...
proxy: remove useless callback_id
2018-04-03 12:26:52 -04:00
Sébastien Blin
5b71af3cec
proxy: remove useless callback_id
...
callback_id was used for token problems which are not present anymore.
Now token is sufficient and we can remove callback_id.
2018-04-03 10:43:56 -04:00
Adrien Béraud
fcf7111872
scheduler: avoid possible overflow with buggy stdlib
2018-03-29 11:58:26 -04:00
Adrien Béraud
38ca7b851b
Merge pull request #267 from AmarOk1412/cpuusage
...
scheduler: avoid overflow causing 100% cpu usage
2018-03-29 11:42:13 -04:00
Sébastien Blin
62bbce76f2
scheduler: avoid overflow causing 100% cpu usage
2018-03-29 11:40:04 -04:00
Adrien Béraud
d9f6731de2
Merge pull request #265 from AmarOk1412/fixSplit
...
proxy_client: fix address split
2018-03-29 11:10:32 -04:00
Sébastien Blin
393a403ff2
proxy_client: fix address split
2018-03-29 11:00:33 -04:00
Adrien Béraud
62e4655d4f
Merge pull request #264 from AmarOk1412/fixPublicAddr
...
dht_proxy_client: fix getPublicAdresss parsing
2018-03-28 16:44:34 -04:00
Sébastien Blin
60d43319e2
dht_proxy_client: fix getPublicAdresss
...
Retrieve all public ips (Ipv6 + v4). Has to resolve all proxy
address (so two get requests to get all ips)
2018-03-28 15:59:04 -04:00
Sébastien Blin
7d3c613347
Merge pull request #263 from savoirfairelinux/value_cache
...
Cache: improve value expiration handling
2018-03-28 10:11:12 -04:00
Adrien Béraud
d2df93c75e
network engine: send nodes in listen confirmation
2018-03-28 09:54:04 -04:00
Adrien Béraud
0edee443f5
cache: improve value expiration handling
2018-03-28 09:54:04 -04:00
Sébastien Blin
8c85f84b8a
Merge pull request #261 from savoirfairelinux/dhtrunner_unit_test
...
tests: add initial unit test for DhtRunner
2018-03-21 11:38:05 -04:00
Adrien Béraud
cea0d4f62e
tests: add initial unit test for DhtRunner
2018-03-21 11:22:21 -04:00
Adrien Béraud
203150851f
OpCache: keep cache alive during callback processing
2018-03-19 20:11:12 -04:00
Adrien Béraud
9a5ef25179
update to version 1.7.0rc1
2018-03-17 23:12:38 -04:00
Adrien Béraud
a5137e8ac4
tests: fix build with autotools
2018-03-17 14:47:23 -04:00
Adrien Béraud
c129a24492
travis: use 5 build configurations
...
Merge all push configurations to reduce build time
as Travis provides 5 free simultaneous builds.
The 'all' configuration is renamed 'push' to reflect the change
2018-03-17 14:40:50 -04:00
Adrien Béraud
8237f32bd5
travis: update Dockerfiles, change base OS to Ubuntu 16.04
2018-03-17 14:32:09 -04:00
Sébastien Blin
546e63edaf
Merge pull request #258 from savoirfairelinux/value_cache
...
Add a value cache for each nodes. This cache avoids network packets by grouping LISTEN operations on the same hash.
2018-03-16 13:55:24 -04:00
Adrien Béraud
647de16f1c
proxy client: implement getLocal(), getLocalById()
2018-03-16 13:34:41 -04:00
Adrien Béraud
2f4acd26d6
dhtinterface: add listen() callback to signal expired values
2018-03-16 13:34:41 -04:00
Adrien Béraud
48bb804792
proxy client: add cache for values and operations
2018-03-16 13:34:40 -04:00
Adrien Béraud
4261bd2c85
dhtinterface: remove resubscribe
2018-03-16 13:34:32 -04:00
Adrien Béraud
12db1f88dc
dht: introduce cache for values and operations
...
Multiplex multiple listen operations on a single key through
a unique listen operation on the network.
2018-03-16 13:34:32 -04:00
Adrien Béraud
1617c79e5d
network: add signaling for expired, refreshed values
2018-03-14 23:39:35 -04:00
Adrien Béraud
80b944d943
dhtnode: prevent crash in cancelListen
2018-03-14 23:39:35 -04:00
Adrien Béraud
74bfced9b9
Merge pull request #255 from AmarOk1412/tests
...
tests: add unit tests structure to opendht
2018-03-14 23:00:30 -04:00
Sébastien Blin
1c10872ea2
tests: add unit tests structure to opendht
...
+ Unit testing requires cppunit.
+ add options for CMake and Autotools to build opendht_unit_tests.
+ add sample tests for InfoHash
+ modify Dockerfiles and Travis build to run `make test`
+ Change lowbit signature to return an int instead of an unsigned.
2018-03-14 15:26:47 -04:00
Adrien Béraud
2b2e8c2a72
Merge pull request #260 from AmarOk1412/fixConnectivityStatus
...
proxy_client: avoid to call getConnectivityStatus() when destroying
2018-03-14 15:22:20 -04:00
Sébastien Blin
2315dc089a
proxy_client: avoid to call getConnectivityStatus() when destroying
...
Because getConnectivityStatus is called each time an operation fails,
when destroying the proxy_client, we stop all operations so it fails.
2018-03-14 11:33:01 -04:00
Adrien Béraud
d7c0e9af38
update to version 1.6.1
2018-03-06 17:30:07 -05:00
Adrien Béraud
460cf858d3
argon2: bump submodule to latest release
2018-03-06 17:24:09 -05:00
Adrien Béraud
c81da2dd7d
indexation: enable by default
2018-03-06 10:29:01 -05:00
Adrien Béraud
b02f8e98c4
filter: add Value vector filter
2018-03-06 10:29:01 -05:00
Adrien Béraud
ca9a367803
value: add TypeStore
2018-03-06 10:29:01 -05:00
Adrien Béraud
09f080220f
Merge pull request #252 from AmarOk1412/fixDuplication
...
dht_proxy_client: fix getCallback for push notifications
2018-03-06 10:24:29 -05:00
Sébastien Blin
547fa2eff5
dht_proxy_client: fix getCallback for push notifications
...
Note: Also fix Value deserialization
2018-03-05 19:15:04 -05:00
Adrien Béraud
2a8f21d4aa
Merge pull request #251 from AmarOk1412/fixcancelListen
...
proxyclient: avoid useless opFailed when correctly cancel a listen
2018-03-01 16:28:18 -05:00
Sébastien Blin
6f4283b7d5
proxyclient: avoid useless opFailed when correctly cancel a listen
2018-03-01 16:11:49 -05:00
Adrien Béraud
babceb902a
readme: fix typo
2018-02-28 21:53:52 -05:00
Adrien Béraud
26bd4e7141
readme: update
2018-02-28 21:37:29 -05:00
Sébastien Blin
1531e13ca4
build: make indexation optional
2018-02-28 08:17:09 -06:00
Adrien Béraud
c9cbced0c8
build: make indexation optional
2018-02-27 21:48:49 -05:00
Adrien Béraud
2cf2112aec
dhtnode: simplify macros
2018-02-27 21:33:48 -05:00
Adrien Béraud
012f6ed2f6
Merge pull request #247 from AmarOk1412/fixCancelListen
...
proxyserver: fix cancelListen and reduce push notifications number
2018-02-26 17:19:32 -05:00
Sébastien Blin
fcac10c4c8
proxyserver: fix cancelListen and reduce push notifications number
2018-02-26 17:01:23 -05:00
Adrien Béraud
f2b692c716
Merge pull request #245 from AmarOk1412/fixCancelListen
...
dhtproxy: fix cancelListen with pushNotifications
2018-02-26 15:37:00 -05:00
Sébastien Blin
22ef53acef
dhtproxy: fix cancelListen with pushNotifications
...
Fill the body of the UNSUBSCRIBE method and fix dhtnode application
2018-02-26 15:25:48 -05:00
Adrien Béraud
2af70e6d50
Merge pull request #243 from AmarOk1412/fixPushBuild
...
pushnotifications: fix build without push notifications, improve travis script
2018-02-26 14:21:34 -05:00
Sébastien Blin
63c9c607bd
pushnotifications: fix build without push notifications, improve travis script
2018-02-26 13:27:06 -05:00
Adrien Béraud
cab0813b17
dht: reduce log verbosity
2018-02-24 15:15:49 -05:00
Adrien Béraud
06cc490ee4
listener: remove unused field
2018-02-24 15:05:14 -05:00
Adrien Béraud
6821988ddf
node: use thread local random device
2018-02-24 14:30:40 -05:00
Adrien Béraud
8cce9fcb85
search: remove getNextStepTime
2018-02-23 13:50:25 -05:00
Adrien Béraud
56caae019c
proxy server: add push notification ttl
2018-02-19 02:10:56 +01:00
Adrien Béraud
f5afcbf62b
proxy server: use high priority notifications
...
Normal priority notifications may be delayed.
2018-02-16 01:54:44 +01:00
Adrien Béraud
0957d30e86
y2038 bug: don't allow time wrap for certificate validity
2018-02-10 23:21:31 +01:00
Adrien Béraud
3a632b1544
proxy server: add logs
2018-02-10 14:31:23 +01:00
Adrien Béraud
2c0f4a897c
dhtnode: fix cancelListen
2018-02-10 14:31:00 +01:00
Adrien Béraud
be6a5671ed
y2038 bug: change certificate duration to 10 years
...
A certificate duration of 20 years was making certificate expire
after 2038 which is not supported on many 32 bits platforms.
Reduce to 10 years, which gives another decade to deprecate 32-bits platforms.
2018-02-09 01:40:03 +01:00
Adrien Béraud
61ac297b1b
crypto: add method to read Certificate activation date
2018-02-09 00:42:25 +01:00
Adrien Béraud
da867dd07c
Merge pull request #239 from kiddouk/fix/dhtnode-identity
...
Generates RSA pairs for dhtnode instead of EC cert
2018-02-08 13:05:46 +01:00
Sébastien Requiem
962249ec75
Generates RSA pairs for dhtnode instead of EC cert
...
* dhtnode was generating twice an EC cert which rendered encryption
impossible since opendht lib is expecting an RSA public key to encrypt
the data for the destination.
* fix savoirfairelinux/opendht#235
2018-02-08 10:56:17 +01:00
Adrien Béraud
c03ba57895
dhtnode: use explicit unique_ptr constructor
2018-02-07 17:40:59 +01:00
Adrien Béraud
e2224fac5a
Merge pull request #209 from dctremblay/readme-update-gcc-version
...
README : update GCC required version from 4.8 to 5.2
2018-02-01 00:52:39 +01:00
Adrien Béraud
48aaaf1e5d
Merge branch 'master' into readme-update-gcc-version
2018-02-01 00:51:41 +01:00
Adrien Béraud
80ee256712
update to version 1.6.0rc1
...
* added REST proxy client implementing the DHT API
* added optional support for push notifications through the proxy server,
using the gorush REST API: https://github.com/appleboy/gorush#web-api
* DhtRunner: now able to use DhtProxyClient as a DHT node
* DhtRunner: can switch between local or proxy node during runtime
* SockAddr: added methods to handle IPv6-mapped IPv4 addresses
* iOS: handle SIGPIPE on UDP sockets by recreating sockets
* fixed occasional crash during packet processing
2018-01-31 18:57:54 +01:00
Adrien Béraud
e274ffd83b
headers: unify API across build options
2018-01-31 18:07:43 +01:00
Adrien Béraud
bd9496e2ba
crypto: fix build on GnuTLS 3.3
2018-01-26 15:10:07 -05:00
Adrien Béraud
4d4ba2be96
Merge pull request #234 from atraczyk/master
...
fix bad paths
2018-01-24 17:31:36 -05:00
atraczyk
680e30be9b
fix bad paths
2018-01-24 17:30:21 -05:00
Adrien Béraud
233301c3f3
dhtrunner: use proxy by default if configured
2018-01-23 12:19:38 -05:00
Adrien Béraud
0db21772c1
Merge pull request #232 from atraczyk/sigpipe
...
dhtrunner: pass SockAddrs by value to startNetwork
2018-01-23 11:34:14 -05:00
Adrien Béraud
e6a2d96622
net: restart socket in case of sigpipe
2018-01-23 11:34:14 -05:00
atraczyk
e5d83d47be
dhtrunner: don't pass SockAddrs by reference to startNetwork
2018-01-23 11:34:14 -05:00
Adrien Béraud
3d77c76a4d
dhtrunner: restart listeners only if one exists
2018-01-23 11:31:12 -05:00
Adrien Béraud
043d5a7c7c
dhtrunner: check dht instance in setLocalCertificateStore
2018-01-19 14:05:21 -05:00
Adrien Béraud
636eb1972d
proxy client: improve robustness, switch behavior
2018-01-18 16:36:13 -05:00
Adrien Béraud
27a250d2c0
proxyclient: fall to disconnected in case of connectivity failure
2018-01-17 12:09:39 -05:00
Adrien Béraud
02f4c81f2a
dhtrunner: improve proxy listen handling
2018-01-17 11:40:18 -05:00
Adrien Béraud
0420ebcce3
dhtinterface: pass listen filters by value
2018-01-17 11:40:18 -05:00
Adrien Béraud
15e3696b88
proxy client: fix build when push notifications are disabled
2018-01-13 16:16:19 -05:00
Adrien Béraud
ca693a6ac1
pushNotificationReceived: take a map<string, string>
...
JSON is used for the DHT proxy protocol and to communicate with gorush.
Push notifications services might use any format, not necessarily JSON.
Push values are received as a map<string, string>, so receive them in
that format.
2018-01-12 13:20:07 -05:00
Adrien Béraud
1d6a307b6b
proxy server: send data push message instead of notification
2018-01-11 17:01:10 -05:00
Adrien Béraud
227cca883c
dhtrunner: start proxy ASAP, use local dht for node stats/import/export
2018-01-11 14:24:59 -05:00
Adrien Béraud
ef82a7ecba
proxy client: make proxy status check asynchronous
2018-01-11 14:24:59 -05:00
Adrien Béraud
6e9f2cda79
SockAddr: add isMappedIPv4, getMappedIPv4
2018-01-11 13:29:18 -05:00
Adrien Béraud
10b58c5ce7
SockAddr: add constructor from simple sockaddr*
2018-01-11 13:29:18 -05:00
Adrien Béraud
ab731cd7d0
Merge pull request #228 from AmarOk1412/push_notifications_client
...
Add support for push notifications
2018-01-11 13:14:43 -05:00
Adrien Béraud
a0d8f4734a
dhtproxy: allow token refresh, set clientID ( #6 )
...
* add method to set the push token independently from other configuration,
since the push token can be updated during runtime.
* allow to provide a "clientID" to be sent in push notifications,
used to demultiplex push notifications to multiple OpenDHT nodes running
on the same host. For instance Ring uses the accountID as the clientID
to know which account received the push notification.
* use {"platform":"android"/"ios"} to communicate the platform instead of {"isAndroid":true/false}.
2018-01-10 16:32:57 -05:00
Adrien Béraud
237859d8c3
Merge branch 'master' into push_notifications_client
2017-12-20 17:51:01 +01:00
Adrien Béraud
24dec0682f
Merge pull request #231 from AmarOk1412/fixLog
...
dht_interface: fix logger issues
2017-12-19 02:11:25 +01:00
AmarOk
4b46f6a821
dht_interface: fix logger issues
...
Make DHT_LOG static to use it in the whole library
2017-12-15 12:45:10 -06:00
Sébastien Blin
37a9a3d9da
dhtproxy: inject push notifications in opendht
...
+ add the ability to inject push notifications in opendht to call
correct callbacks
+ if a timeout occurs and no cancelListen was called, relaunch the
listen operation
+ Pass devicekey to enable push notifications for DhtProxyClient
+ Update sockaddr to fix the build on all platforms
Note: update dhtnode
2017-12-12 15:03:02 -06:00
Sébastien Blin
75cca66d7e
dhtproxy: support push notifications for mobile clients
...
+ Add SUBSCRIBE and UNSUBSCRIBE for DhtProxyServer
+ Add the ability to stop Listen via a timeout (and send a push
Notification for the client)
+ Add the ability to use gorush to send push notifications
Note: Update dhtnode
2017-12-12 10:24:54 -06:00
Adrien Béraud
762a1c7ad2
Merge pull request #220 from AmarOk1412/dhtproxyclient_merge
...
proxy: implement DhtProxyClient
2017-12-12 13:38:23 +01:00
AmarOk
d19ba2cb41
proxyserver: add lock_guard to avoid to manually unlock
2017-12-06 14:43:28 -06:00
AmarOk
557323deff
refactor: use new jsoncpp API
...
Use the latest jsoncpp API to remove depreciation warning.
2017-12-06 08:49:24 -06:00
AmarOk
29ffbf6aa7
dhtrunner: remove DhtRunner::getAddrInfo
...
Was replaced by SockAddr::resolve
2017-12-05 10:02:38 -06:00
Adrien Béraud
aaa577d9e3
proxy_client: use atomic bool for shared state flags ( #3 )
2017-12-05 09:50:38 -06:00
Sébastien Blin
333c44dbd3
proxy_client: don't block for callback
2017-12-05 09:05:35 -06:00
Adrien Béraud
8243bc4c3f
proxy_client: don't block for callback
...
Use shared flags to avoid blocking for the callback
while respecting the callback return value.
2017-12-05 15:51:39 +01:00
AmarOk
b1a9742889
dhtproxyclient: add lock_guards for mutex and clean code
2017-12-04 09:42:37 -06:00
Adrien Béraud
d2f91af946
node: use shared_ptr to manage Sockets
2017-12-02 16:03:27 +01:00
Sébastien Blin
5adc5b4c94
README: update Restbed dependency informations
2017-12-01 14:28:32 -05:00
Adrien Béraud
f9d48cd15a
Merge pull request #227 from atraczyk/master
...
Build: add new files to VS project and adjust filters
2017-11-30 00:17:29 +01:00
Sébastien Blin
e7d8bc4275
proxyclient: erase finished operation threads
2017-11-29 14:44:02 -05:00
atraczyk
507326cebc
Build: add new files to VS project and adjust filters
2017-11-29 13:46:07 -05:00
Adrien Béraud
b24832e0e1
Merge pull request #226 from atraczyk/master
...
InfoHash: fix stream operator<< declaration
2017-11-29 17:14:03 +01:00
atraczyk
6cdcd183b4
InfoHash: fix stream operator<< declaration
2017-11-29 11:08:39 -05:00
Sébastien Blin
eb750f5b7f
proxy_client: execute callbacks in main thread
2017-11-27 17:51:33 -05:00
Sébastien Blin
5967c89c23
proxy: don't reinit dhtproxy multiple times and forward encrypted messages
...
+ Having a null dht_proxy_client can lead to using nullptr.
+ securedht should forward messages if we are using a proxy.
+ Protect callback segfault
2017-11-22 16:09:45 -05:00
Sébastien Blin
4a83b36dcf
tools: add the ability to use a proxy for dhtchat
2017-11-21 13:37:18 -05:00
Sébastien Blin
eb1f9d64e1
dhtproxyclient: add listen ability.
...
+ Fix LISTEN endpoint for DhtProxyServer
= DhtProxyServer use multiple worker threads
+ Add listen/cancelListen for DhtProxyClient
+ Add connectivityChanged.
2017-11-20 16:01:44 -05:00
Sébastien Blin
cb72c104fd
proxy: implement basic DhtProxyClient with the ability to get and put.
...
+ Add an abstract class to describe the Dht
+ Now, we can modify the Dht linked to a SecureDht. So we can choose
between the classic Dht and the Dht using a proxy.
+ Implement a basic client which can Get and Put values on the Dht using
the proxy.
Note: Update dhtnode to have the ability to use the DhtProxyClient.
Todo: Implement Listen, ping, connectivityChanged for the client.
2017-11-20 15:45:29 -05:00
Adrien Béraud
5fde50be4a
dhtrunner: use const char* for setopt value
...
fix build on Win32
2017-11-17 19:34:31 +01:00
Adrien Béraud
1c16e6f38d
update to version 1.5.0
...
* added REST server implementing OpenDHT proxy API
* tools: added simple Web client using the proxy server
* tools: allow dhtnode to run a proxy server
* tools: allow dhtnode to use any string as key
* InfoHash: added operator bool()
* minor performance improvement
* SockAddr: fix endianness issue
* net: fix incorrect reported address parsing
* minor memory leak fixes
2017-11-17 18:51:45 +01:00
Adrien Béraud
6790d1ec5c
SockAddr: set service to null if string is empty
2017-11-17 18:31:28 +01:00
Adrien Béraud
4dc1847978
autotools: fix build without proxy server
2017-11-17 16:42:04 +01:00
Adrien Béraud
3a61692618
net: set MSG_NOSIGNAL if possible
2017-11-17 02:20:31 +01:00
Adrien Béraud
6f9afac0a5
dhtrunner: cleanup
2017-11-17 02:12:03 +01:00
Adrien Béraud
b17c7c2965
dht: reserve address vector size
2017-11-17 02:06:32 +01:00
Adrien Béraud
6d238836ad
dht: return empty search on error
2017-11-17 01:01:47 +01:00
Adrien Béraud
5115fab9e6
dht: increase max searches limit
2017-11-16 16:49:59 +01:00
Adrien Béraud
93498ecf0b
tools: JS node: cleanup
2017-11-14 21:55:03 +01:00
Adrien Béraud
72d790953a
tools: JS node: allow to set the proxy address
2017-11-14 20:58:18 +01:00
Adrien Béraud
72b556a09b
tools: JS node: cleanup
2017-11-14 19:38:55 +01:00
Adrien Béraud
747f86f8f4
dhtrunner: use SockAddr::resolve
2017-11-10 17:59:05 -05:00
Adrien Béraud
161769f4ec
SockAddr: use host endianess for bitwise-shift operations
2017-11-10 17:48:36 -05:00
Adrien Béraud
9948079c97
SockAddr: add resolve()
2017-11-10 17:48:36 -05:00
Adrien Béraud
607e5eeccf
tools: use https url
2017-11-10 17:29:24 -05:00
Adrien Béraud
111ac57b6f
tools: JS node: add listen support
2017-11-09 12:23:30 -05:00
Adrien Béraud
153641dde5
tools: add JavaScript proxy node
2017-11-08 15:20:06 -05:00
Adrien Béraud
113bebabd4
DhtRunner: remove log
2017-11-08 15:14:01 -05:00
Adrien Béraud
b549055034
DhtRunner: use SockAddr
2017-11-08 15:12:43 -05:00
Adrien Béraud
7d7410b472
dhtnode: allow to use arbitrary string as key
...
Key will be h(key).
2017-11-08 15:12:43 -05:00
Adrien Béraud
d7aaa4ae56
proxy server: add Access-Control-Allow-Origin
2017-11-08 15:12:43 -05:00
Adrien Béraud
5a049f89f3
cmake: find Jsoncpp using pkgconfig
2017-11-08 15:12:43 -05:00
Sébastien Blin
65e88f2fa6
build: toInfoHash->to
2017-11-08 15:07:04 -05:00
Adrien Béraud
4430b1e616
Merge pull request #217 from AmarOk1412/dhtproxy
...
Communicate with OpenDHT through a REST API
2017-11-08 14:35:31 -05:00
Sébastien Blin
e2c534df5a
add std::bind, fix put, avoid overflow on base64
2017-11-08 14:33:07 -05:00
Sébastien Blin
2ca2835c9b
add options method handler
2017-11-08 12:14:44 -05:00
Sébastien Blin
bbe922dd7d
remove headers, fix HTTP status, fix get /
2017-11-07 16:08:55 -05:00
Sébastien Blin
38ad5b9ef2
add --proxyserver option for dhtnode
2017-11-06 16:49:46 -05:00
Sébastien Blin
67ba435ba6
base64: take the old implementation from ring-daemon
2017-11-06 16:24:00 -05:00
Sébastien Blin
6413571301
clean code
2017-11-06 12:53:35 -05:00
Adrien Beraud
0dccae68e6
InfoHash: make false in case of parsing error
2017-11-03 16:03:11 -04:00
Adrien Beraud
92320cef59
InfoHash: throw in case of invalid input string
2017-11-03 14:03:34 -04:00
Adrien Beraud
bf4e838e20
InfoHash: return stream in operator>>
2017-11-03 14:00:49 -04:00
Adrien Beraud
88b4233bda
python: update InfoHash bool operator
2017-11-03 14:00:49 -04:00
Adrien Beraud
e9eb97ea9a
InfoHash: improve hex parsing performance
2017-11-02 17:42:45 -04:00
Adrien Beraud
0e865976f9
InfoHash: unify with Hash<N>
2017-11-02 14:28:09 -04:00
Adrien Beraud
87dc080bbf
crypto: add raw hash function
2017-11-02 14:25:46 -04:00
Sébastien Blin
9abc88f378
add --enable-proxy-server option for autotools
2017-11-01 17:11:14 -04:00
Adrien Beraud
834d62e6e9
InfoHash: use bool operator where relevent
2017-11-01 16:28:17 -04:00
Sébastien Blin
61a148e83f
update README.md
2017-11-01 14:52:29 -04:00
Sébastien Blin
8e43775394
update dhtnode + clean code
2017-11-01 14:52:29 -04:00
Sébastien Blin
8344138bc8
add optional + clean start/stop
2017-11-01 14:52:29 -04:00
Sébastien Blin
dc66b3847a
make code for DHT Proxy Server optionnal
2017-11-01 14:52:29 -04:00
Sébastien Blin
d608da4307
cmake: add optionnal dependencies for proxy
2017-11-01 14:52:29 -04:00
Sébastien Blin
7ddd6629e3
add getFiltered
2017-11-01 14:52:29 -04:00
Sébastien Blin
20abc3e495
add LISTEN endpoint
2017-11-01 14:52:29 -04:00
Sébastien Blin
c4ba8670e4
add Putxxx value endpoints
2017-11-01 14:52:29 -04:00
Sébastien Blin
a3348c85d6
value to JSON and begin to clean endpoints
2017-11-01 14:52:29 -04:00
Sébastien Blin
ca465d7159
set timeout to a high value + add jsoncpp
2017-11-01 14:52:29 -04:00
Sébastien Blin
1413d32ee6
add listen endpoint
2017-11-01 14:52:29 -04:00
Sébastien Blin
58fdfa9452
add get hash endpoint
2017-11-01 14:51:36 -04:00
Sébastien Blin
6f641073ae
proxy put and putEncrypted
2017-11-01 14:51:36 -04:00
Sébastien Blin
32153b11ab
proxy putSigned
2017-11-01 14:51:36 -04:00
Sébastien Blin
e33ac02351
test restbed
2017-11-01 14:51:36 -04:00
Adrien Beraud
dc99919338
InfoHash: add explicit operator bool()
2017-11-01 11:59:11 -04:00
Adrien Béraud
fcaaa01b2d
network engine: add "value update" message type
2017-10-30 13:12:16 -04:00
Adrien Béraud
8cd3ff9fc4
network engine: remove unused constant
2017-10-30 13:12:16 -04:00
Adrien Béraud
0a130c7045
dht: update permanent state on announce
2017-10-30 13:12:16 -04:00
Adrien Béraud
eb9f314356
dhtnode: allow to perform and cancel persistent put
2017-10-30 13:12:16 -04:00
Adrien Béraud
a401aea132
dht: simplify searchSendAnnounceValue
2017-10-30 13:12:16 -04:00
Adrien Béraud
41ebbe21d4
node cache: expire nodes on destructions
...
Expiring nodes on cache destruction allow to cancel
any remaining request before the dht instance is destructed,
since Node instances might remain alive after the dht instance
is destroyed.
2017-10-30 13:12:16 -04:00
Adrien Béraud
6378840d33
dhtnode: allow to cancel a listen operation
2017-10-30 13:12:16 -04:00
Adrien Béraud
64f0aa1532
parsed message: don't override the reported address family
2017-10-30 13:12:16 -04:00
Adrien Béraud
63366722a9
dht: reduce verbosity of storage log
2017-10-21 18:01:32 +02:00
Adrien Béraud
cd17858ae1
dht: periodic cleanup of unused quota entries
2017-10-21 18:00:46 +02:00
Adrien Béraud
f4ebbc6651
update to version 1.4.1
...
* updated MSVC project
* bug fixes
2017-10-21 01:30:12 +02:00
Adrien Béraud
464339822b
Merge pull request #215 from AmarOk1412/typoPeriod
...
rate_limiter: typo fix, 'Perdiod'->'Period'
2017-10-20 23:56:02 +02:00
Sébastien Blin
fe09146609
rate_limiter: typo fix, 'Perdiod'->'Period'
2017-10-20 14:51:35 -04:00
Adrien Béraud
a789ffe7ae
dht: prevent use-after-free of socket callback
2017-10-20 17:46:27 +02:00
Adrien Béraud
476fbb1160
network: use full 32-bits of transaction IDs
...
We used to use the first 16 bits for the message type.
2017-10-20 17:42:28 +02:00
Adrien Béraud
4501217c21
Merge pull request #214 from atraczyk/master
...
remove vs2015 based constexpr error, update vs project files
2017-10-19 01:19:43 +02:00
atraczyk
207675a181
remove vs2015 based constexpr error, update vs project files
2017-10-18 17:50:19 -04:00
Adrien Béraud
cf6447dc80
NetworkEngine: use proper type for constant
2017-10-17 19:22:15 +02:00
Adrien Béraud
775eb2e599
update to version 1.4.0
...
* improved Doxygen documentation
* cmake: add support to build documentation
* cmake: improve build on macOS
* API change: storage policies, getPublicAddress now use SockAddr
* NodeExport: added msgpack serialization
* fixed issue that could cause occasional request failures
* minor bug fixes
* minor performance improvements
2017-10-17 18:37:08 +02:00
Adrien Béraud
376486e64f
node: use full range of socket IDs
2017-10-17 15:25:09 +02:00
Adrien Béraud
63013bf374
SearchNode: prevent copy, check request access
2017-10-17 03:17:52 +02:00
Adrien Béraud
488aa771a9
Node: don't expire existing requests
2017-10-16 17:12:33 +02:00
Adrien Béraud
6bc2f19a36
dht: log total number of nodes in onGetValuesDone
2017-10-16 17:12:33 +02:00
Adrien Beraud
2dd94fbfe8
cmake: use CMAKE_THREAD_LIBS_INIT as library
2017-10-16 01:26:40 +02:00
Adrien Béraud
be2b9fd7dc
NodeCache: handle end() lower_bound for non-empty map
2017-10-15 15:57:14 +02:00
Adrien Béraud
9d4e6e0984
rate limiter: use deterministic maintenance
...
Using deterministic maintenance sets an upper bound
to the size of the address map.
2017-10-15 01:18:32 +02:00
Adrien Beraud
4856a6b424
PublicKey: getId compatible with HASH_LEN = 32
2017-10-13 15:43:56 +02:00
Adrien Béraud
7df375fc75
NodeCache: fix invalid pointer access
2017-10-13 15:40:09 +02:00
Adrien Béraud
63e0c1266a
dht: use OpStatus in put
...
Factorize shared pointers.
2017-10-13 02:07:14 +02:00
Adrien Béraud
1a54aff7bc
storage policies: use SockAddr
...
API-breaking change to use const SockAddr& instead of sockaddr*.
2017-10-13 01:10:09 +02:00
Adrien Béraud
f2b9f8eeda
dht: move bucket time update to routing table
2017-10-13 01:10:09 +02:00
Adrien Béraud
e9f007025f
node: make most fields private
2017-10-13 01:10:09 +02:00
Adrien Béraud
6ce1531e1f
node: make id const
2017-10-12 15:44:34 +02:00
Adrien Béraud
84a45c4f91
dht: factorize shared pointer dereference
2017-10-12 15:44:14 +02:00
Adrien Béraud
e20ae56cab
dht: support client mode
...
In client mode, a node won't store data
and won't participate in routing.
2017-10-12 15:44:14 +02:00
Adrien Béraud
4ce0168916
network engine: move ParsedMessage to separate file
2017-10-11 23:51:44 +02:00
Adrien Béraud
024dd42e5a
dht: remove processMessage
2017-10-11 17:36:20 +02:00
Adrien Béraud
98ec789526
nertwork engine: move tid management to Node
2017-10-11 17:36:20 +02:00
Adrien Béraud
3bb5e7ee12
network engine: move transaction ownership to Node
2017-10-11 17:36:20 +02:00
Adrien Béraud
8c529b7d7f
request: add getTid(), getSocket()
2017-10-11 13:47:53 +02:00
Adrien Béraud
be7494961c
network engine: move socket management to Node
2017-10-11 02:23:56 +02:00
Adrien Béraud
bdb0bef0ee
network engine: move RequestAnswer out of class
2017-10-11 02:22:03 +02:00
Adrien Béraud
73f26e120d
doc: improve documentation
2017-10-10 18:16:33 +02:00
Adrien Béraud
9f4b16e4f5
cmake: add doxygen documentation support
...
Automatically build documentation if doxygen is found.
2017-10-10 17:45:34 +02:00
Adrien Béraud
323ad774e5
value: restore stream state after change
2017-10-09 15:14:20 +02:00
Adrien Béraud
d0bcd39341
IpServiceAnnouncement: use SockAddr
2017-10-09 15:06:34 +02:00
Adrien Béraud
42125367d7
SockAddr: add documentation
2017-10-09 14:46:35 +02:00
Adrien Béraud
d87a4ef28c
InfoHash: add operator==
2017-10-07 11:35:56 +02:00
Adrien Béraud
a3f4388556
InfoHash: increase toFloat precision
2017-10-07 11:35:56 +02:00
Adrien Béraud
97ee4b6fea
dht: move onNewNode to RoutingTable
2017-10-07 11:35:56 +02:00
Adrien Béraud
0abd288958
SockAddr: factorize setters
2017-10-05 14:09:56 +02:00
Adrien Béraud
131073e211
SockAddr: cleanup
2017-09-27 11:36:42 +02:00
Adrien Béraud
078c4f064a
cmake: use Threads package
2017-09-26 16:42:33 +02:00
Adrien Béraud
f17a4e66f5
cmake: add flag to enable address sanitizer and stack protector
2017-09-26 16:35:38 +02:00
Adrien Béraud
dd13ebb6d1
cmake: use private linking for private dependencies
...
Users of the OpenDHT shared library don't need to link
against GnuTLS or Nettle.
2017-09-26 16:34:18 +02:00
Adrien Béraud
1c45f34262
SockAddr: use pointer to sockaddr
...
Save memory and reduce copies by using a pointer
to a sockaddr structure of the right size instead of
using a full sockaddr_storage structure for every address.
2017-09-26 16:30:29 +02:00
Adrien Beraud
a82f575232
NodeExport: add ostream operator
2017-08-30 10:48:49 +02:00
Adrien Beraud
1d84b34cf6
value: avoid checking failbit directly
...
failbit is implementation defined, use the bool operator instead.
2017-08-30 10:46:30 +02:00
Adrien Beraud
bedb51bf52
crypto: add EC curve identity generation
2017-08-28 12:03:15 -04:00
Adrien Béraud
1b9e9452c4
NodeExport: add msgpack serialization
2017-08-28 12:02:09 -04:00
Adrien Beraud
3bdaf2e20b
update to version 1.3.6
...
Bugfix release.
2017-08-11 14:54:31 -04:00
Adrien Beraud
a1d67b881b
python: fix invalid pointer access
2017-08-11 12:44:40 -04:00
Adrien Beraud
c40750f6e4
dht: use proper value type to compute expiration
2017-08-10 15:00:34 -04:00
David Côté-Tremblay
f69d6426bd
README : GCC required version from 4.8 to 5.4
2017-08-10 11:52:46 -04:00
Adrien Béraud
63b40d3e3a
cmake: check library paths
2017-07-22 11:25:40 -04:00
Adrien Béraud
21f5918af8
cmake: use version 3.1, cleanup
2017-07-22 10:59:36 -04:00
Adrien Beraud
6989236985
update to version 1.3.5
...
Bugfix release.
2017-07-20 00:49:29 -04:00
Adrien Beraud
1efa120010
dhtcluster: allow to resize cluster
2017-07-20 00:47:47 -04:00
Adrien Béraud
a99ca1cf05
Merge pull request #205 from atraczyk/master
...
add listener.h, search.h, and storage.h to VS project
2017-07-19 19:03:14 -04:00
atraczyk
8fc8209731
add listener.h, search.h, and storage.h to VS project
2017-07-19 18:39:49 -04:00
Adrien Beraud
6f3eafc5ee
dht: set refill time even when no nodes where found
2017-07-16 23:30:58 -04:00
Adrien Beraud
83d1cb97c8
dht: cleanup sendCachedPing
2017-07-16 23:30:58 -04:00
Adrien Beraud
477799a2b9
dht: remove unused method
2017-07-16 23:30:58 -04:00
Adrien Beraud
7e8c9ce944
dht: use SockAddr& in makeToken
2017-07-16 23:30:58 -04:00
Adrien Beraud
6decb6609a
dht: use uint64_t to store secret
2017-07-16 23:30:58 -04:00
Adrien Beraud
f1e7cd897d
dht: use crypto::hash
2017-07-16 18:11:06 -04:00
Adrien Beraud
9bfaa224bc
dht: move set_nonblocking to NetworkEngine
2017-07-16 18:10:49 -04:00
Adrien Beraud
5657661249
dht: move Search out of the Dht class
2017-07-16 17:46:54 -04:00
Adrien Beraud
e69d61d8c7
dht: move request to src
2017-07-16 17:45:24 -04:00
Adrien Beraud
729c055f5b
scanner: fix reset and IPv6 print issue
2017-07-16 16:23:18 -04:00
Adrien Beraud
61f91d626b
dht: move Storage, Listener out of the Dht class
2017-07-16 15:04:18 -04:00
Adrien Beraud
732d10713d
dht: minor coverity fixes
2017-07-16 13:39:14 -04:00
Adrien Beraud
15e5fa433b
network engine: handle EAFNOSUPPORT
2017-07-15 23:46:33 -04:00
Adrien Beraud
43ff0e9e52
network engine: handle EAGAIN, ENETUNREACH
...
Handle a few common error codes from send():
* EAGAIN: reschedule without increasing retry count.
This prevent nodes from failing on slow/very slow connections.
* ENETUNREACH, EHOSTUNREACH: expire the node immediately instead
of waiting for an answer, to expire IPv6 nodes quickly if no
IPv6 network is available.
2017-07-15 23:36:33 -04:00
Adrien Beraud
cf32e78f1b
scanner: enable logging, use rbegin() instead of prev(end())
2017-07-15 23:25:17 -04:00
Adrien Beraud
f170726b4b
scanner: make steps asynchronously from UI
2017-07-15 23:24:19 -04:00
Adrien Beraud
ebb20bdf0c
python: NodeSet: return insertion status
2017-07-15 14:17:51 -04:00
Adrien Beraud
2ca7302352
ice candidates: reduce lifetime to 1 minute
2017-07-13 09:58:03 -04:00
Adrien Beraud
8a123f9f68
network: prevent sending packets larger than 1280 bytes
2017-07-12 11:24:58 -04:00
Adrien Béraud
7e92eb6192
Merge pull request #202 from atraczyk/master
...
clean up vs2015 project files and add a build script
2017-07-11 11:41:10 -04:00
atraczyk
56edf1720c
clean up vs2015 project files and add a build script
2017-07-11 10:51:50 -04:00
Adrien Beraud
7c32dc49b1
update to version 1.3.4
...
Bugfix release that also adds SystemD modules
2017-06-30 01:32:23 +02:00
Adrien Beraud
5cb5ab019f
routing table: fix invalid iterator access
...
When calling findClosestNodes with an key referencing the first bucket,
the itp iterator could point to before-begin() and dereference it.
2017-06-29 13:07:31 +02:00
Adrien Beraud
42fa09a6fa
dhtnode: graceful signal handling in service and daemon modes
2017-06-29 10:20:31 +02:00
Adrien Beraud
673884a409
dhtnode: add service mode
...
Service mode is similar to the daemon mode but:
* doesn't fork
* logs to stdout/stderr by default
instead of syslog
2017-06-29 09:57:55 +02:00
Simon Désaulniers
ec6296e44b
http_server: enable WHERE filtering for GET method
2017-06-27 09:59:01 +02:00
Simon Désaulniers
b96d0de8a2
python: make use of Filter, Where in DhtRunner.get
2017-06-27 09:59:01 +02:00
Simon Désaulniers
98c4e39ed1
python: expose queries to API
2017-06-26 17:56:44 -04:00
Simon Désaulniers
9c483880cb
value: prevent queries redundant information
2017-06-22 18:39:25 -04:00
Simon Désaulniers
ae7e298946
http_server: put values, specific user_type,vid
2017-06-22 18:39:18 -04:00
Simon Désaulniers
7197c1fbb6
python: expose user_type member of Value
2017-06-22 17:42:57 -04:00
Adrien Béraud
c10e04d526
Merge pull request #195 from GrossoMoreira/patch-1
...
Avoid dereferencing an iterator to 'end()'
2017-06-20 14:21:29 +02:00
Pedro Moreira
ee883492ee
Avoid dereferencing an iterator to 'end()'
...
*h.end() only works on VS 2015 with
_SECURE_SCL=0
_ITERATOR_DEBUG_LEVEL=0
Also, if these flags are used when compiling opendht, it seems that any client program that wants to link against opendht also needs the same flags enabled, which is a terrible requirement to force on a client.
The proposed change makes the code a bit cleaner and doesn't require any preprocessor tricks.
2017-06-20 13:19:29 +02:00
Adrien Beraud
2ed99db9b1
pkg-config: add argon2 dependency when not using included version
2017-06-18 22:14:27 +02:00
Adrien Beraud
c11dcf5d76
dhtcluster: add systemd module
2017-06-01 18:35:43 +02:00
Adrien Beraud
4132e990ec
dhtcluster: log cleanup
2017-06-01 18:28:33 +02:00
Adrien Beraud
76eba8c235
dhtcluster: add service mode
...
The service mode is like the daemon mode
but doesn't fork.
2017-06-01 18:27:12 +02:00
Adrien Beraud
e1ac26773b
dhtcluster: install with tools
2017-06-01 17:20:29 +02:00
Adrien Beraud
339ea70230
python/cluster: rename to dhtcluster
2017-06-01 17:19:50 +02:00
Adrien Beraud
943a39178c
python/cluster: add syslog support
...
Use syslog in daemonized mode
2017-06-01 15:57:34 +02:00
Adrien Beraud
ae0cb58a5c
python/cluster: remove unused methods
2017-06-01 15:56:18 +02:00
Adrien Beraud
dd116d8ad8
python/cluster: add clean stop on signal
2017-06-01 15:53:41 +02:00
Adrien Beraud
74c3c5bc87
systemd service: use pkg-config to find proper install location
2017-05-30 13:47:30 +02:00
Adrien Beraud
b6bfa14872
systemd service: bind on port 4222 by default
2017-05-30 13:22:58 +02:00
Adrien Beraud
50a769c8fb
dhtnode: add systemd service
...
Install a systemd service when configured
with -DOPENDHT_SYSTEMD (CMake only).
2017-05-30 12:41:47 +02:00
Adrien Beraud
39a254ce9f
log: add syslog support
...
Add support to log using standard syslog,
add related option in dhtnode.
dhtnode will use syslog by default
when starting in daemon mode and
no logfile is defined.
2017-05-30 12:20:09 +02:00
Adrien Beraud
3aa720fe1f
python/cluster: bind on ::0 by default on IPv6
2017-05-23 17:59:05 +02:00
Adrien Beraud
7908a1d2ea
update to version 1.3.3
...
Minor bugfix release
2017-05-13 17:51:28 -04:00
Adrien Beraud
37d8481e28
crypto: handle null certificate in getCopy(), getChain()
2017-05-13 17:18:00 -04:00
Adrien Beraud
44822f944b
update to version 1.3.2
...
* crypto API improvements
* python bindings improvements
* implement first python unit tests
* minor bug fixes
2017-05-11 14:05:38 -04:00
Adrien Béraud
406a1c1152
Merge pull request #192 from atraczyk/master
...
MSVC: decouple argon2 dependency
2017-05-03 11:30:01 -04:00
atraczyk
f9939ce336
decouple argon2 dependency
2017-05-03 11:26:45 -04:00
Adrien Beraud
d9bced965b
crypto: add TrustList move operator, prevent copy
2017-05-01 16:26:12 -04:00
Adrien Beraud
4d78aea05b
unit tests: add crypto unit tests
2017-04-27 04:46:08 +02:00
Adrien Beraud
9b42afa9ca
implement first simple unit tests
2017-04-27 04:45:59 +02:00
Adrien Beraud
aa5b8b84a8
python: add TrustList wrapper
2017-04-27 04:45:59 +02:00
Adrien Beraud
d0a8a92a56
crypto: add GnuTLS trust list wrapper
2017-04-27 04:45:59 +02:00
Adrien Beraud
cf82f74e15
python: add PrivateKey::generateEC support
2017-04-27 04:45:59 +02:00
Adrien Beraud
a952ddec53
python: add crypto encrypt/decrypt
2017-04-27 03:34:04 +02:00
Adrien Beraud
fa7efd086f
python: add Identity PrivateKey getter
...
Refactor Identity and PrivateKey to use
shared_ptr<PrivateKey> and retrieve the
key from Identity.
2017-04-27 03:34:04 +02:00
Adrien Beraud
8e28e86caf
python: improve wrapper for crypto::Certificate
...
Add Certificate issuer, getName and revoke
2017-04-27 03:34:04 +02:00
Adrien Beraud
65de9622fb
crypto: add Certificate::getChainWithRevocations
2017-04-26 16:43:06 +02:00
Adrien Beraud
210c4b2077
crypto: fix memory leak in RevocationList::getPacked()
2017-04-26 16:42:33 +02:00
Adrien Beraud
e8cb635b3a
crypto: add getChain()
2017-04-22 19:48:32 +02:00
Adrien Beraud
f41c8fef99
crypto: unify API across GnuTLS versions
...
Throw an exception if GnuTLS is too old
instead of not providing the API.
Also consistently throw in case of hash error,
and return 0 for an empty hash, for both
PublicKey and Certificate.
2017-04-20 17:07:21 +02:00
Adrien Beraud
02147b0b16
update to version 1.3.1
2017-04-14 17:12:54 +02:00
Adrien Beraud
79e266aac6
crypto: don't build getLongID() with old gnutls
2017-04-14 16:57:58 +02:00
Adrien Beraud
9d75ed14b4
infohash: add to_c_str(), improve toString() performance
2017-04-10 15:48:04 +02:00
Adrien Beraud
fcca618c48
infohash: improve getRandom performance
...
Generate random hash in 32 bits chunks
instead of 8 bits chunks.
2017-04-10 15:48:04 +02:00
Adrien Beraud
73bcebf355
license cleanup
2017-04-10 01:43:20 +02:00
Adrien Beraud
057443e4a0
python/tools: update pingpong
2017-04-10 01:12:31 +02:00
Adrien Beraud
99f8c2950b
python: rename bootstrap(sockaddr) to ping
2017-04-10 01:12:00 +02:00
Adrien Beraud
4132c63faf
def: fix typo
2017-04-09 17:22:18 +02:00
Adrien Béraud
7f2b5a44ff
Merge pull request #186 from sim590/search-step-after-announce
...
dht: fix searchstep not scheduled after announcing
2017-04-05 20:12:23 +02:00
Adrien Beraud
7db0c15483
tools: catch exceptions
2017-04-05 18:35:19 +02:00
Adrien Beraud
2fc7cc57a9
default types: fix uninitialized fields
2017-04-05 18:15:34 +02:00
Adrien Beraud
4970a2aee5
infohash: throw exception with error message
2017-04-05 18:15:02 +02:00
Adrien Beraud
25b6df5355
removeExpiredNode: cleanup
2017-04-05 17:52:34 +02:00
Adrien Beraud
732479736b
select: cleanup
2017-04-05 17:52:34 +02:00
Adrien Beraud
696ac1bbd5
network engine: print error if send fails
...
for now just print an error
2017-04-05 17:52:34 +02:00
Adrien Béraud
3b2e5a13bf
Merge pull request #185 from savoirfairelinux/feature/pht
...
pht: prevent unneeded use of shared_ptr
2017-04-04 16:31:44 +02:00
Simon Désaulniers
26a7aec7cc
dht: fix searchstep not scheduled after announcing
2017-04-03 17:39:15 -04:00
Adrien Beraud
b73a50bace
pht: prevent unneeded use of shared_ptr
...
Prefer a const reference instead of shared_ptr if the shared_ptr
is not used and argument type is not changed in the method.
This allows to prevent useless shared_ptr allocations.
In getRealPrefix, use OpState to track state instead of using many
different shared_ptr.
2017-04-03 19:10:49 +02:00
Adrien Beraud
70ccbe4e40
value: remove FieldSelectorDescription
...
FieldSelectorDescription is just Value::Field and
adds nothing on top of it.
Remove it in favor of Value::Field.
2017-04-03 19:10:01 +02:00
Adrien Beraud
6bb00ab732
Merge pull request #175 from sim590/argon2-submodule
...
argon2: use as submodule (reverted from commit c424eb9160 ) (reverted from commit 3c45e1996d )
2017-03-30 21:24:49 +02:00
Adrien Béraud
2e279852cd
Merge pull request #178 from sim590/benchmark-ifname-error
...
benchmark: fix invalid ifname error
2017-03-30 17:06:03 +02:00
Adrien Béraud
09b4e71dc5
Merge pull request #182 from atraczyk/master
...
fixes the contrib paths for the Visual Studio build
2017-03-30 00:48:02 +02:00
atraczyk
b40713596c
ignore MSVC\contrib\build and add argon2 path to project
2017-03-29 18:25:10 -04:00
atraczyk
c5485a795a
Merge branch 'master' of github.com:atraczyk/opendht
2017-03-29 17:57:19 -04:00
atraczyk
b7c5d4a550
clean up solution
2017-03-29 17:55:18 -04:00
Adrien Beraud
0aa1c9e42d
argon2: try to fix build on MSVC
2017-03-29 18:27:19 +02:00
Adrien Beraud
5823e98c76
rng: add missing header
2017-03-29 03:07:09 +02:00
Adrien Beraud
3c45e1996d
Merge pull request #175 from sim590/argon2-submodule
...
argon2: use as submodule (reverted from commit c424eb9160 )
2017-03-29 02:51:06 +02:00
Adrien Beraud
e2ce496779
crypto: add Certificate::getCopy()
2017-03-29 00:22:19 +02:00
Adrien Beraud
4540be7460
python: add more crypto bindings
2017-03-28 17:33:04 +02:00
Adrien Beraud
7c85b74de6
sockaddr: convert port to network/host byte order
2017-03-28 16:38:28 +02:00
Adrien Beraud
fccd569059
python: allow to get bound address for any family
2017-03-28 16:32:55 +02:00
Adrien Beraud
768bfa5d44
python: add SockAddr support
2017-03-28 16:25:17 +02:00
Adrien Beraud
ff6e38571d
dhtrunner: add method to bootstrap with a single SockAddr
2017-03-28 15:44:09 +02:00
Simon Désaulniers
0a5a609322
benchmark: fix invalid ifname error
...
Two instructions were mutually misordered.
2017-03-27 23:35:55 -04:00
Adrien Béraud
c424eb9160
Merge pull request #175 from sim590/argon2-submodule
...
argon2: use as submodule
2017-03-27 15:46:55 +02:00
Adrien Beraud
501ba77ec7
docker: add missing dep
2017-03-24 13:42:18 +01:00
Adrien Beraud
dc23ee0c7a
docker: update dependencies
2017-03-24 03:51:43 +01:00
Adrien Beraud
e98f06e84a
python: fix scanner
2017-03-24 03:51:15 +01:00
Simon Désaulniers
19c36284dc
argon2: use as submodule
2017-03-22 17:18:23 -04:00
Adrien Béraud
358d8bd7b3
Merge pull request #176 from sim590/tools-help
...
tools: add help -h flag for dhtscanner, dhtchat
2017-03-16 03:20:22 +01:00
Simon Désaulniers
c17508862c
tools: add help -h flag for dhtscanner, dhtchat
2017-03-15 22:11:25 -04:00
Adrien Beraud
2277a4959c
crypto: pack/unpack certificate after generation
...
make sure the certificate can be fully used after generation
2017-03-15 19:08:06 +01:00
Adrien Beraud
d5427df9eb
build: allow to use argon2 system library
...
allow to use system argon2 library, use system library by default:
* add --with(out)-argon2 configure options
* add -DOPENDHT_ARGON2=(On/Off) cmake option
also bump argon2 to latest git
2017-03-13 14:58:25 +01:00
Adrien Beraud
36206a80fc
rng: add missing include
2017-03-08 17:50:26 +01:00
Adrien Beraud
ab7d175322
network engine: make buffer length depend on HASH_LEN
2017-03-07 23:14:25 +01:00
Adrien Beraud
802528266a
crypto: add secure_vector and SecureBlob
2017-03-07 23:00:10 +01:00
Adrien Beraud
95d98f4659
rng: add getSeededRandomEngine
...
Add a routine to seed a pseudo-engine to
use the full range of possible internal states
by using seed_seq.
2017-03-07 17:08:46 +01:00
Adrien Beraud
4176302a03
crypto: add PublicKey::toString()
2017-03-07 17:08:46 +01:00
Adrien Béraud
b3119cce13
Update README.md
2017-03-07 16:14:58 +01:00
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
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
Adrien Béraud
197aaa47f0
crypto: prevent duplicate CRLs, reimport after signing
2016-12-06 16:59:54 -05:00
Adrien Béraud
ad234004aa
crypto: store CRLs in a set
2016-12-05 15:43:00 -05:00
Adrien Béraud
a88e6a4c5f
crypto: make CRL default expiration same as certificate
2016-12-02 12:59:03 -05:00
Adrien Béraud
c776dad96f
crypto: add Certificate::getExpiration()
2016-12-02 12:58:10 -05:00
Adrien Béraud
31fedd529b
crypto: add CRL msgpack serialization
2016-12-01 18:42:26 -05:00
Adrien Béraud
e9adff9dc5
crypto: add CRL move operator, export as DER
2016-11-30 17:30:09 -05:00
Adrien Béraud
bfd58a204b
crypto: add CRL import/export methods
2016-11-30 16:31:29 -05:00
Adrien Béraud
867bcf1514
crypto: add EC key generation
2016-11-29 18:04:25 -05:00
Adrien Béraud
fb882ee440
crypto: add revocation list
2016-11-29 18:03:49 -05:00
Adrien Béraud
215d3d2847
http server: add cmd arguments
2016-11-29 13:31:40 -05:00
Adrien Béraud
43a345ba0c
python: add HTTP server to access the DHT
2016-11-29 12:08:33 -05:00
Adrien Béraud
f73f5e2798
log: cosmetics
2016-11-29 01:27:42 -05:00
Istvan
3724670fcc
Log.cpp added to src/MakeFile.am
2016-11-29 00:50:47 -05:00
Istvan
e7db64bd74
Log functions are moved to log.cpp
...
Log functions are moved to the log.cpp
in order to avoid multiple definitions
of the logger functions.
2016-11-29 00:50:47 -05:00
Adrien Béraud
9c29b8a29e
Merge pull request #160 from sim590/fix-include-dep
...
buildtools: add def.h to include files
2016-11-28 01:49:30 -05:00
Adrien Béraud
c22f0e4d43
Update Makefile.am
2016-11-28 01:48:26 -05:00
Adrien Béraud
4e2b11c24c
Update CMakeLists.txt
2016-11-28 01:47:33 -05:00
Simon Désaulniers
8c34e927ea
buildtools: add def.h to include files
2016-11-27 23:28:23 -05:00
Adrien Béraud
8a5de47aa0
hide symbols by default ( #140 )
2016-11-23 18:27:24 -05:00
Adrien Béraud
7f84c1e397
utils: remove useless definitions
2016-11-23 15:12:37 -05:00
Adrien Béraud
65c915fd9d
value: print hex value data contiguously
2016-11-23 11:01:14 -05:00
Adrien Béraud
0fd4f73ab1
network monitor: access proper dictionary key
2016-11-23 11:00:11 -05:00
Adrien Béraud
01117567b1
cmake: adapt pkg-config paths to GNUInstallDirs
2016-11-22 10:43:01 -05:00
Adrien Béraud
d68cc5cf40
Merge pull request #156 from sim590/cython-robust-check
...
autoconf: robustly check for cython3
2016-11-21 15:10:40 -05:00
Simon Désaulniers
6db16be2fa
autoconf: robustly check for cython3
2016-11-14 21:07:36 -05:00
Adrien Béraud
5166b1add9
tools: add network monitor
...
The network monitor allows to regularly
check the status of an OpenDHT network,
by performing listen and put operations at
random places on the DHT.
This first version exit with status code 1
if the test fails.
2016-11-10 01:03:29 -05:00
Adrien Béraud
9fadcc907c
python: add default port for bootstrap
2016-11-10 00:58:35 -05:00
Adrien Béraud
42171efc3f
dht: send values to all sockets for a node
...
We used to send values once to a given node,
however the receiving node may have canceled
or dropped the request since then,
so we now send the values for every socket and
the optimization will happen on the sending side.
2016-11-09 21:53:43 -05:00
Adrien Béraud
206f12648f
Merge pull request #155 from aviau/patch-1
...
Multi-Arch support
2016-11-09 13:10:08 -05:00
Alexandre Viau
ecd0573c4d
Multi-Arch support
2016-11-09 11:30:17 -05:00
Simon Désaulniers
2d9f6241a9
net: don't close socket on listen renew
2016-11-08 16:07:15 -05:00
Adrien Béraud
77ee50f5a6
Merge pull request #154 from savoirfairelinux/c_str
...
infohash: add helper to C string format conversion
2016-11-08 15:48:05 -05:00
Guillaume Roguez
297c37e609
infohash: add helper to C string format conversion
...
This const void* convertion method helps a lot with programs
that need to print the hash with a printf() like function.
2016-11-08 15:26:13 -05:00
Simon Désaulniers
9bb1ab43eb
net.h: moved to include/opendht/
2016-11-08 14:52:09 -05:00
Adrien Béraud
cd36b13c30
dht: prevent infinite loop in expireStorage()
2016-11-07 16:56:08 -05:00
Adrien Béraud
5d63084627
Merge pull request #152 from sim590/listen-consistency
...
Listen consistency
2016-11-07 10:33:05 -05:00
Simon Désaulniers
ab7d1d6582
dht,net: introduce socket, support multiple listen
...
Since the initial implementation of listen operation, multiple listen requests
from a single node on a same hash was not possible without singular
inconsistencies. The flaw was coming from the fact that nodes receiving listen
request could not differentiate between listen refresh request and a new
independent listen request.
This patch introduces the new net::Socket structure which in time will enable
remote nodes to send update for a storage while differentiating between
concurrent listen requests. A socket has a unique identifier which consists of a
transaction id as defined in the OpenDHT protocol.
2016-11-07 06:44:15 -05:00
Simon Désaulniers
77ea6d8c2f
net: create net namespace, moving relevant structs
2016-11-05 19:29:00 -04:00
Simon Désaulniers
b5cd629160
dht: callback if no storage maintenance
2016-11-04 09:15:10 -04:00
Adrien Béraud
39467c8b71
tools: add python cluster runner commands
2016-11-02 02:32:06 -04:00
Adrien Béraud
87740e3b38
tools: add python node cluster runner
2016-11-01 03:14:26 -04:00
Adrien Béraud
19848a9b72
python: encode log file name
2016-11-01 03:13:56 -04:00
Adrien Béraud
36e9998fe2
scanner: use urllib3
2016-11-01 03:13:56 -04:00
Adrien Béraud
b2529c241e
log: flush on new line
2016-11-01 03:13:56 -04:00
Adrien Béraud
83c47037d2
dht: remove unimplemented declaration
2016-11-01 03:13:56 -04:00
Adrien Béraud
125b6f9236
dht: make storage maintenance optional, default disabled
2016-10-31 14:43:56 -04:00
Adrien Béraud
e260ba6b78
infohash: remove misused restrict
2016-10-31 12:35:50 -04:00
Simon Désaulniers
eafb934e85
bump version to 1.2.1
2016-10-28 18:49:09 -04:00
Adrien Béraud
c3d3da20f6
Merge pull request #146 from sim590/permanent-put-enhancement
...
dht: make reannounce margin bigger, safer
2016-10-28 16:24:07 -04:00
Adrien Béraud
6036ccdbaa
dht: try inserting new nodes smarter ( #150 )
...
Attempt closest search and nearby searches
until we are too far instead of trying every
search.
2016-10-28 15:46:27 -04:00
Simon Désaulniers
9404a4d069
dht: make reannounce margin bigger, safer
...
Reannouncing margin going from 5 seconds to 10 seconds.
2016-10-28 15:24:09 -04:00
Adrien Béraud
274621dcec
dht: add searches(sa_family)
2016-10-27 18:12:05 -04:00
Adrien Béraud
2ab756906d
dht: getSearchLog for a specific search
2016-10-27 16:51:21 -04:00
Adrien Béraud
2b3f63443f
dht: maintain each storage independently
...
Schedule every storage maintenance independently,
to improve performance when there are a lot of storages.
2016-10-27 14:21:52 -04:00
Adrien Béraud
c71f960948
python: add ping-pong simple test
2016-10-26 18:07:06 -04:00
Adrien Béraud
9d3514e087
dhtrunner: don't run ops if disconnected and bootstraping
2016-10-26 17:50:30 -04:00
Adrien Béraud
6703e039b1
network_engine: deserialize proper number of fields
2016-10-26 17:50:30 -04:00
Adrien Béraud
29b81750ad
Merge pull request #148 from atraczyk/master
...
bump visual studio support
2016-10-26 12:48:51 -04:00
atraczyk
d6fff53f6b
bump visual studio support
2016-10-26 10:28:05 -04:00
Simon Désaulniers
7ee6281426
log: display time before each line in log
2016-10-25 16:40:48 -04:00
Adrien Béraud
28a5740c37
argon2: bump source
2016-10-25 16:40:48 -04:00
Adrien Béraud
09a3332cf0
Merge pull request #147 from savoirfairelinux/feature/log_filter
...
log: add filters
2016-10-24 16:55:23 -04:00
Adrien Béraud
f584c4849b
dht: unify creation date normalisation
2016-10-24 02:09:38 -04:00
Adrien Béraud
e3663c995a
log: add storage filter
2016-10-24 02:09:38 -04:00
Adrien Béraud
1d62b3ca64
log: add InfoHash filter
...
* filter log entries with new method setLogFilter
* filter by node id, search or infohash
* add optional parameter to 'log' in dhtnode
2016-10-24 02:09:38 -04:00
Adrien Béraud
3af04a4259
securedht: use default max expiration for putSigned
2016-10-23 17:23:39 -04:00
Adrien Béraud
78d98822a5
securedht: use default max expiration for putEncrypted
2016-10-23 16:47:37 -04:00
Adrien Béraud
8c04ddc66b
dht use proper value type to compute expiration
2016-10-23 14:58:15 -04:00
Adrien Béraud
5277b8d23e
dht: storage refresh returns bool
2016-10-23 03:23:17 -04:00
Simon Désaulniers
86fea49178
doc: add pdf compiled of tex file
2016-10-21 19:00:08 -04:00
Simon Désaulniers
5b1242f786
bump version
...
* several clang related bug fixes;
* connectivity changes related enhancements;
* new "refresh" protocol primitive (not exposed to API);
* "permanent put" operation fixes/enhancements;
* fixed general efficiency issues;
2016-10-21 18:56:45 -04:00
Simon Désaulniers
a8cfdbe762
doc: add connectivity loss search analysis tex file
2016-10-21 18:07:11 -04:00
Adrien Béraud
70b1ebae0b
dht: fix scheduler job edition on clang
2016-10-21 17:44:39 -04:00
Adrien Béraud
9dc6004329
network engine: cancel request when clearing listen status
2016-10-19 13:58:18 -04:00
Adrien Béraud
d4bd17a2dc
dhtrunner: use a second condition variable for bootstrap
2016-10-19 13:34:33 -04:00
Simon Désaulniers
6c73e5fa5c
dht: less cases clear values, storage maintenance
2016-10-19 11:53:47 -04:00
Simon Désaulniers
24edfb8eaf
dht: uniformly sync SearchNodes reannouncing
...
Historically, the next announce timing was based on the last acknowledgement
received from a SearchNode. This behavior was invalid since the 'refresh'
operation. In fact, for a given value that was "refreshed", its creation time
would differ from the announcer's info. Therefor, all search node's
reannouncing timings would differ, hence causing inconsistency on the network.
2016-10-19 11:53:47 -04:00
Adrien Béraud
4ef5a2216e
dht: revert to previous onNewNode behavior
2016-10-19 01:27:19 -04:00
Adrien Béraud
0d646eb244
network engine: log cleanup
2016-10-19 01:01:51 -04:00
Adrien Béraud
757fea37f3
Merge pull request #142 from sim590/fix-permanent-put-time-info
...
dht: appropriate time info in permanent put ops
2016-10-18 14:26:21 -04:00
Simon Désaulniers
09e41cc9f2
dht: appropriate time info in permanent put ops
2016-10-18 14:20:43 -04:00
Adrien Béraud
71ad92e286
dht: log cleanup
2016-10-17 17:55:22 -04:00
Adrien Béraud
d4f3d3aa98
dht: add missing iterator
2016-10-17 17:14:30 -04:00
Simon Désaulniers
c0612a1b2c
dht: use "refresh" operation for permanent put
2016-10-17 11:56:54 -04:00
Simon Désaulniers
6743cbbf50
dht: introduce "refresh" operation
...
This operation requests a node to refresh a value's time_point information of
its lifetime begining. This is intended to fix the *permanent put* operation
which has been having syncing issues since the introduction of an enhanced and
lighter put operation.
2016-10-17 11:56:54 -04:00
Adrien Béraud
da1bdf9d4c
dht: retry nodes more aggressively in case of failure
2016-10-16 22:36:52 -04:00
Adrien Béraud
96da4cd85d
build: make logs optional at build time
2016-10-16 22:36:42 -04:00
Adrien Béraud
f233340cb2
node: clear reply_time on reset
2016-10-16 22:36:36 -04:00
Adrien Béraud
cfb817d37f
dht: add buckets() utility
2016-10-16 22:36:30 -04:00
Adrien Béraud
9440c03048
dht: log cleanup
2016-10-16 22:36:24 -04:00
Adrien Béraud
aa611bde50
network engine: cleanup
2016-10-15 20:07:37 -04:00
Adrien Béraud
7af856508e
dht: make connectivityChanged family dependent
2016-10-15 19:13:15 -04:00
Adrien Béraud
aaed64039a
dht: fix compilation on clang
2016-10-12 15:02:02 -04:00
Adrien Béraud
7c5e8c3234
sockaddr: add missing include for Win32
2016-10-12 14:38:39 -04:00
Adrien Béraud
a56bf3f115
dhtrunner: handle null callback in pingNode
2016-10-12 13:25:00 -04:00
Adrien Béraud
2d2fa9cfa9
OpenDHT 1.1.0
...
* automatic connection loss recovery
* dhtrunner: asynchronous DNS lookup for bootstrap
* handle values up to 64k
* better support for large values on macOS
* dht: add callback to pingNode
* fix compilation with recent clang versions
2016-10-11 17:36:12 -04:00
Adrien Béraud
9f11930f3d
fix compilation on latest clang
2016-10-11 16:34:40 -04:00
Adrien Béraud
013b1dfe2e
Merge pull request #138 from sim590/connectivity-changes-detect
...
search: detect connectivity changes
2016-10-11 16:01:59 -04:00
Simon Désaulniers
733f699ff2
search: detect connectivity changes
...
The number of bad nodes is limited in order to help determine presence of
connectivity changes. See https://github.com/savoirfairelinux/opendht/issues/137
for details.
According to the tables, 25 is a good average value for big networks. If the
network is small, normal search expiration process will handle the situation.
2016-10-11 15:54:37 -04:00
Adrien Béraud
a366d502a2
fix compilation on latest clang
2016-10-11 15:50:49 -04:00
Adrien Béraud
eed8ffc792
Merge pull request #139 from savoirfairelinux/recover-from-network-changes
...
dhtrunner: recover from network changes
2016-10-11 11:57:31 -04:00
Adrien Béraud
998547e1a1
Merge pull request #136 from savoirfairelinux/feature/value_fragment
...
network: transmit large values in multiple packets
2016-10-11 11:57:18 -04:00
Simon Désaulniers
8567b7ad84
network_engine: expire requests when clearing NE
...
This is to prevent any thread relying on network_engine's callback to block
forever just like the Dht::sendPing's callback.
2016-10-10 01:51:26 -04:00
Adrien Béraud
64118404fe
dhtrunner: recover from network changes
...
Using a list of bootstrap nodes, we recover from network loss by pinging those
nodes continuously until connected.
Written with Simon Désaulniers.
2016-10-10 01:51:26 -04:00
Simon Désaulniers
bb74dc846c
dht/dhtrunner: enable callback for pingNode
2016-10-10 00:23:53 -04:00
Adrien Béraud
659d893dee
network: transmit large values in multiple packets
2016-10-09 16:22:33 -04:00
Simon Désaulniers
e3f371c2d8
bump version
2016-10-06 08:27:00 -04:00
Adrien Béraud
f53c7a6785
dht: keep track of storage usage in maintainStorage
2016-10-04 03:09:00 -04:00
Adrien Béraud
261c193b50
Merge pull request #133 from sim590/sync-enhancements
...
dht: bug fixes, timing computation enhancements
2016-09-24 19:07:05 -04:00
Simon Désaulniers
dc0b650aa3
dht: make sure we are synced before sending put
2016-09-23 19:27:59 -04:00
Simon Désaulniers
87cf6faedd
dht/node: don't allow more than 3 auth errors
2016-09-23 19:27:59 -04:00
Simon Désaulniers
ca6aa6706d
dht/value: make 'find_node' queries satisfied by any queries
...
'find_node' requests don't ask for values. Then, the idea of a Query makes less
sense, but since we still need those to map status to network engine requests,
we introduce dummy queries which with the field Query::none. Those queries will
then only serve as key to network engine's requests.
2016-09-23 19:27:58 -04:00
Simon Désaulniers
16e55416a6
network_engine: fix bug token not sent for listen
2016-09-23 19:27:58 -04:00
Simon Désaulniers
3e24058175
dht: fix SearchNode's getListenTime computation
...
When no listen request have been sent yet, getListenTime should tell it's okay
to send pending listen request.
2016-09-23 19:27:55 -04:00
Simon Désaulniers
d1c2b20b28
dht: canGet must allow sending when no token
2016-09-23 13:48:04 -04:00
Adrien Béraud
ccd0cbd8f2
add per IP rate limiting ( #131 )
2016-09-21 15:44:20 -04:00
Adrien Béraud
e5213674e3
value: fix compilation on older clang
2016-09-20 17:02:29 -04:00
Adrien Béraud
b9cc848810
cmake: remove OPENDHT_DEBUG flag
...
Replace with -DCMAKE_BUILD_TYPE=Debug
2016-09-20 00:04:39 -04:00
Adrien Béraud
65bdfaf22b
autotools: fix 'make dist'
2016-09-18 13:55:14 -04:00
Adrien Béraud
de31d836b4
Merge pull request #132 from savoirfairelinux/feature/map_storage
...
dht: use a map for storage
2016-09-18 13:02:03 -04:00
Adrien Béraud
25b339956e
tools: gnutls cleanup
2016-09-16 01:43:58 -04:00
Adrien Béraud
23bb6e7a45
dht: use a map for storage
2016-09-16 01:29:33 -04:00
Adrien Béraud
b44f7ec653
Merge pull request #130 from savoirfairelinux/feature/sockaddr
...
introduce SockAddr to store IP addresses
2016-09-15 23:46:57 -04:00
Adrien Béraud
6d38c18572
introduce SockAddr to store IP addresses
2016-09-15 01:38:26 -04:00
Simon Désaulniers
8eaf78bfe2
bump version
2016-09-14 19:06:51 -04:00
Simon Désaulniers
dc836b38a6
build: use -pedantic-errors flag in autotools
2016-09-14 19:06:20 -04:00
Adrien Béraud
b01f8d079b
Merge pull request #128 from sim590/concurrent-queries
...
[dht] concurrent queries
2016-09-14 18:12:47 -04:00
Simon Désaulniers
6f7ac21a85
dht: refactor code, terminating a Search (isDone)
...
More code encapsulated in objects method is better for keeping consistent
behavior.
2016-09-14 18:06:25 -04:00
Simon Désaulniers
7c5db84f33
dht: take multiple queries into account
...
The code preceding this would just not take multiple concurrent queries for a
same search into account. This is a bug fix for a bad behavior since the
queries.
2016-09-14 18:06:23 -04:00
Simon Désaulniers
4fecb2066b
dht: SearchNode::canGet criteria using 'update'
...
The criteria has been rewritten (again) exploiting the idea behind the parameter
'update' to take into account the case where we have new distinct requests to
send, then bypass some checks.
2016-09-14 18:06:12 -04:00
Adrien Béraud
eabdddcfb3
dht: fix warnings
2016-09-08 18:02:17 -04:00
Adrien Béraud
ceab27d723
value: optimize chainAll for empty filters
2016-09-08 17:22:34 -04:00
Adrien Béraud
a9cc669a95
dht: clarify code
2016-09-08 15:52:18 -04:00
Simon Désaulniers
927c835b8f
dht: call all announce callback appropriately
2016-09-08 12:24:35 -04:00
Simon Désaulniers
5415eaaf60
dht: consider probe query in announce time
2016-09-08 12:24:35 -04:00
Simon Désaulniers
ec587f9b58
dht: make sure search can be flagged "done"
2016-09-08 12:24:35 -04:00
Simon Désaulniers
babfed73f3
dht: use SearchNode::acked for next announce time
2016-09-08 12:24:35 -04:00
Simon Désaulniers
2c0ce576e3
dht: enable data persistence
2016-09-08 12:24:35 -04:00
Simon Désaulniers
8f2cc937c5
dht: introduce light put
...
The 'put' operation will now first check if nodes already store the value we
have to announce. If so, we don't announce it to that node.
2016-09-08 12:24:35 -04:00
Adrien Béraud
c9f6567128
Merge pull request #127 from sim590/insert-node-export-fix
...
dht: Dht::insertNode has to really insert
2016-09-07 16:43:28 -04:00
Simon Désaulniers
d60672e8ba
dht: remove unnecessary return value
2016-09-07 16:15:06 -04:00
Simon Désaulniers
fd4cce4883
NetworkEngine: insertNode tells routing table
2016-09-07 15:54:16 -04:00
Adrien Béraud
df15d3d48e
Merge pull request #126 from savoirfairelinux/wip/crypto
...
crypto: drop support for GnuTLS < 3.3
2016-09-07 00:10:36 -04:00
Adrien Béraud
76fd216386
crypto: drop support for GnuTLS < 3.3
2016-09-06 17:18:16 -04:00
Adrien Béraud
48735aad94
build/cmake: use proper indentation
2016-09-06 17:16:33 -04:00
Adrien Béraud
91a1471de5
build/autotools: fix build flags
2016-09-06 17:16:33 -04:00
Adrien Béraud
047ba76ff1
Merge pull request #125 from savoirfairelinux/wip/crypto
...
crypto: add length parameters
2016-09-06 13:50:38 -04:00
Adrien Béraud
e57eb63c87
securedht: don't complain about certificate announcement
2016-09-06 12:06:30 -04:00
Adrien Béraud
8461f4018d
crypto: avoid using std::to_string
2016-09-06 12:06:30 -04:00
Adrien Béraud
c33c2e7e95
crypto: add key, hash length parameters
2016-09-06 12:06:30 -04:00
Adrien Béraud
e5a9a2af4c
Merge pull request #124 from aberaud/master
...
dht: fail pending operations before clearing them
2016-09-06 10:49:33 -04:00
Adrien Béraud
7919ca8de1
dht: fail pending operations before clearing them
2016-09-02 14:30:08 -04:00
Adrien Béraud
00ef660952
dht: hide more internal structures
2016-09-02 14:30:08 -04:00
Adrien Béraud
862a03713b
opendht: version 1.0
...
* add Prefix Hash Tree (PHT) for data indexation (Nicolas Reynaud, Simon Désaulniers)
* add Queries (Simon Désaulniers)
* add long-term data persistance (Simon Désaulniers)
* add data pagination (Simon Désaulniers)
* reduced bandwith usage
2016-09-01 18:02:23 -04:00
Adrien Béraud
89d0d2f109
pht: fix compilation with pedantic
2016-09-01 18:02:23 -04:00
Adrien Béraud
3283e34dcf
pht: rebase over queries
2016-09-01 18:02:23 -04:00
kaldoran
34c6b264df
Add filter of duplicate value
2016-09-01 18:02:23 -04:00
kaldoran
2d8fe502f2
Fix print of the lookup output
2016-09-01 18:02:23 -04:00
kaldoran
73df308250
Adding ZCurve algorithm
2016-09-01 18:02:23 -04:00
kaldoran
cdca40cb59
Rework prefix [add flags] and prepare prefix
2016-09-01 18:02:23 -04:00
kaldoran
2a3c301314
dht: Fix get and put at the same time on a same node
...
When the put is performed just after a get, then the get will not include the value which was in the put.
2016-09-01 18:02:23 -04:00
kaldoran
6f4923da2e
dht: fix some typo
2016-09-01 18:02:23 -04:00
kaldoran
ae26a2b39a
Update of algorithm, by using new feature of api
2016-09-01 18:02:23 -04:00
kaldoran
48c40c8a27
pht: correction on the algorithm of complet node splitting
2016-09-01 18:02:23 -04:00
kaldoran
a4a4eee495
pht: introduction of complet node splitting
2016-09-01 18:02:23 -04:00
kaldoran
d185428d1d
[Python] Draw benchmark graph in a better way #104
2016-09-01 18:02:23 -04:00
kaldoran
6855aaa6f4
Correction of error on SwapBit
2016-09-01 18:02:23 -04:00
kaldoran
2aee4f418f
Correction of the size of the prefix, now size does not include the size of the padding
2016-09-01 18:02:23 -04:00
kaldoran
95aef01a59
Pht : Fix out of range in isActiveBit function
2016-09-01 18:02:23 -04:00
kaldoran
d2ccde4859
pht: bit padding when the key is too short
2016-09-01 18:02:23 -04:00
Simon Désaulniers
7ab64ea0e6
pht: validKey must check for key field value len
2016-09-01 18:02:23 -04:00
Simon Désaulniers
fe1b8b88e1
pht: provide simpler lookup callback
...
From a user point of view, the structure Prefix doesn't make sense really. It's
better to provide a simpler callback function signature for the user then.
2016-09-01 18:02:23 -04:00
Simon Désaulniers
b6832869b1
pht: moved some defs in cpp file
2016-09-01 18:02:23 -04:00
Simon Désaulniers
6da8d39a0e
python: update cython wrapper and python benchmark
...
API changed when the keys pec was added. This commit updates python code
according to the new API.
2016-09-01 18:02:23 -04:00
Simon Désaulniers
f8cf1316ad
pht: add key spec, handling maximum prefix length
...
This commit adds the new KeySpec in the Pht constructor signature so that all
keys used inside a same PHT structure have the same maximal length.
2016-09-01 18:02:23 -04:00
Simon Désaulniers
736606a845
pht: a Key is rather map str:Blob not str:Prefix
2016-09-01 18:02:23 -04:00
Simon Désaulniers
cba240e15e
pht: fix invalid comparison, inexact match lookup
2016-09-01 18:02:23 -04:00
Adrien Béraud
eb90fffb5e
update for API changes
2016-09-01 18:02:23 -04:00
kaldoran
041e280bde
benchmark: timing pht insert operations
2016-09-01 18:02:23 -04:00
kaldoran
33fae1cb66
pht: add prefix cache
2016-09-01 18:02:23 -04:00
Simon Désaulniers
4e8408e225
python: lock before launching pht insert in test
2016-09-01 18:02:23 -04:00
Simon Désaulniers
e85a423f6a
Revert "[Bug] Correction of function commonBits"
2016-09-01 18:02:23 -04:00
kaldoran
532cb40665
Correction of error on commonBits
2016-09-01 18:02:23 -04:00
kaldoran
dd58b0497e
Correction of prefix, sometime some bit remain at they default value
2016-09-01 18:02:23 -04:00
Kaldoran
cc070c80ba
Fix the autotool Makefile, missing pht include
...
Fix indentation for pull request #37
Fix include error, and use only needed file in pht
Fix implementation of function in pht
2016-09-01 18:02:23 -04:00
Simon Désaulniers
e332dae576
python: insert test show entries for each prefix
2016-09-01 18:02:23 -04:00
Simon Désaulniers
727fd4e98b
fix typo in tests
2016-09-01 18:02:23 -04:00
Simon Désaulniers
5a5f7012d8
add pht insert test
2016-09-01 18:02:23 -04:00
Simon Désaulniers
5a239cddf7
pht: fix insert always to root bug
...
This makes the pht node recover all indexed data on a DHT node (maximum
MAX_NODE_ENTRY_COUNT per node) so that the pht node can be aware if it has to
split its data in the leaf.
2016-09-01 18:02:23 -04:00
Simon Désaulniers
c4928553ba
python: fix successive deref on cython object
2016-09-01 18:02:23 -04:00
Simon Désaulniers
48b0cff08e
pht: fix multiple DoneCallBack calls
2016-09-01 18:02:23 -04:00
Simon Désaulniers
c8fcffbe6b
fix possible out of range error in Prefix ctor
2016-09-01 18:02:23 -04:00
Simon Désaulniers
63c4eeb9c9
cover empty leaf case in inexact match lookup
...
In case this is inexact match lookup and we end up on an empty leaf (diffrent
than the root), the search goes on in the leaf's sibling subtree.
2016-09-01 18:02:23 -04:00
Simon Désaulniers
d45f777099
pht tools
2016-09-01 18:02:23 -04:00
Simon Désaulniers
9c4035dd8f
add inexact match lookup
...
This is meant to enable random lookup queries.
2016-09-01 18:02:23 -04:00
Simon Désaulniers
acc2b71c86
base pht indexation
2016-09-01 18:02:23 -04:00
Nicolas
09d849c93d
Update README.md
2016-09-01 17:46:04 -04:00
Nicolas
1be1ad88c6
Update README.md
2016-09-01 17:43:10 -04:00
Nicolas
8ecaf25339
Move logo in the right position
2016-09-01 17:41:33 -04:00
Adrien Béraud
7a6dce4727
securedht: don't complain about certificate announcement (reverted from commit 85a9dbafc6)
2016-09-01 17:12:28 -04:00
Adrien Béraud
b357ffb0e6
add logo
2016-09-01 17:10:59 -04:00
Adrien Béraud
517bd5f22b
opendht: add logo
2016-09-01 12:49:26 -04:00
Adrien Béraud
d1d0a67d35
dht: fix public address sorting
2016-09-01 12:46:39 -04:00
Adrien Béraud
85a9dbafc6
securedht: don't complain about certificate announcement
2016-09-01 12:46:39 -04:00
Nicolas
79390f72fa
Merge pull request #121 from sim590/benchmark-msgpack-ipc
...
[benchmark] new msgpack ipc
2016-08-31 16:25:21 -04:00
Simon Désaulniers
b7a37dd771
benchmark: msgpack with callback based IPC
2016-08-31 15:47:05 -04:00
Simon Désaulniers
b24d1ccc8b
benchmark: removing anormal behavior from normal test
2016-08-31 15:37:30 -04:00
Simon Désaulniers
4f53e10e7e
benchmark: enable traffic_plot for "delete" test
2016-08-31 15:37:30 -04:00
Simon Désaulniers
a608ad3cf6
benchmark: send new distinct values during test
...
During totallyNormalTest, an initial set of values would be put on the dht.
Then, random values from this same set would be put over time, but since values
would already be there, no put were really made.
2016-08-31 15:37:29 -04:00
Simon Désaulniers
a135f81073
benchmark: create function for displaying plot
2016-08-31 15:37:15 -04:00
Nicolas
2da48557ff
Merge pull request #120 from sim590/fix-timing-loops
...
dht: send find_node before sending 'listen'.
2016-08-30 16:14:22 -04:00
Simon Désaulniers
73686debaf
dht: before sending 'listen', send find_node
...
Since pagination, a bug was making the listen feature unusable running in
infinite loop. This also makes more sense than sending 'get' since the listen
request is paired with a Query defining the values that have to be fetched.
2016-08-30 15:51:50 -04:00
Adrien Béraud
97950621cd
crypto: check max data size for sign
2016-08-25 00:42:50 -04:00
Adrien Béraud
b3401828e4
dht: set "connecting" state when waiting for a ping
2016-08-25 00:42:50 -04:00
Nicolas
0a7d4a68b3
Merge pull request #119 from sim590/find-node-timings
...
dht: cover bad cases in SearchNode::canGet
2016-08-22 19:16:19 -04:00
Simon Désaulniers
8d7deffa6a
dht: properly find pending satisfying query
...
In SearchNode::canGet, we don't send a 'get' request to a search node if a
satisfying query for the query we want to send is already pending. This patch
honors this behavior.
2016-08-22 18:45:29 -04:00
Simon Désaulniers
669c08210e
dht: erase find node request status when done
...
This was memory leak and produced inconsistency in SearchNode::canGet timings.
2016-08-22 18:26:53 -04:00
Adrien Béraud
27a3231a55
argon2: bump source
2016-08-18 10:10:03 -04:00
Seva Ivanov
86ce695939
cython: change shared_ptr invocation to libcpp.memory
2016-08-16 10:27:34 -04:00
Adrien Béraud
2759a136df
infohash: add istream operator overload
2016-08-16 10:27:31 -04:00
Adrien Béraud
690682408b
build with -pedantic-errors, fix pedantic build errors
2016-08-16 10:26:44 -04:00
Nicolas
bfdb8a24e9
Merge pull request #113 from sim590/value-pagination-fix
...
dht: value pagination fix
2016-08-15 19:35:33 -04:00
Simon Désaulniers
e9bf042ac5
dht: document SearchNode::canGet
2016-08-15 13:44:52 -04:00
Simon Désaulniers
5aab3078c8
dht: properly handle pagination timings
2016-08-15 12:13:16 -04:00
Simon Désaulniers
1ac5840bb1
dht: let nodes expire properly
...
The line with `srn->getStatus[query]->setExpired()` in searchNodeGetExpired was
messign with the node expiration process.
2016-08-14 22:08:52 -04:00
Simon Désaulniers
426b3d6834
dht: pagination queries should be in SearchNode
...
Pagination queries must to be kept in seperate list per node. Otherwise, two
searches could be blocking each others or generating unwanted behavior.
2016-08-11 12:27:04 -04:00
Nicolas
97b573c182
Merge pull request #110 from sim590/value-pagination
...
dht: Value pagination using queries
2016-08-09 17:27:00 -04:00
Simon Désaulniers
5c41cbb964
dht: value pagination
...
Instead of literally asking to a node all values for givent `h`, we first ask
for all ids the node has. Then, we concurently and individually ask for each
values that match each id we recovered in our first request.
2016-08-09 15:43:55 -04:00
Simon Désaulniers
e192e3beaf
better indentation and comments
2016-08-09 15:42:05 -04:00
Adrien Béraud
5dacb50d63
Merge pull request #108 from sim590/search-refill-from-cache
...
dht: unify bootstrapSearch and refill method using node cache
2016-08-09 14:41:23 -04:00
Adrien Béraud
86d837b5a9
Merge pull request #106 from sim590/get-timings
...
[dht] rework get timings after queries in master
2016-08-09 14:23:13 -04:00
Adrien Béraud
6454a6dc3f
Merge pull request #109 from kaldoran/fix_put-get
...
dht: Fix, get does not include the put value if its performed just after it.
2016-08-08 18:10:05 -04:00
kaldoran
bbd1200ad7
dht: Fix get and put at the same time on a same node
...
When the put is performed just after a get, then the get will not include the value which was in the put.
2016-08-08 17:50:56 -04:00
Adrien Béraud
aa59242843
readme: add IRC link
2016-08-07 00:13:18 -04:00
Simon Désaulniers
c04ede4909
dht: unify bootstrapSearch and refill method
...
Since bootstrapSearch was rewritten to use the node cache, it made it clear that
refill should be rewritten as such. However, then bootstrapSearch becomes
irrelevant.
An enhancement to refill is that it will let insertNode review its whole list
of nodes and then let it insert nodes up to SEARCH_NODES nodes. The previous
method would not garantee this behavior since, most of the times, it would pass
less than SEARCH_NODES nodes to insertNode.
2016-08-06 21:14:17 -04:00
Adrien Béraud
a1eaf2e83c
Merge pull request #107 from sim590/minor-search-refactor
...
dht: more accurate name for requested nodes count
2016-08-05 23:03:25 -04:00
Simon Désaulniers
a21d4d4adc
queries: fix deserialization bug
...
Only the first two entries of the array would be accessed in a consistent way.
Therefor, only the two first field value index would be returned.
2016-08-05 21:20:58 -04:00
Simon Désaulniers
f0a92d999c
dht: more accurate name for requested nodes count
...
The number of currently requested nodes, formerly named currentGetRequests, was
renamed since it was not accurately describing the behavior. The number we are
counting is not the number of 'get' requests, but rather the number of nodes
being requested simultaneously.
2016-08-05 21:19:46 -04:00
Simon Désaulniers
28a3498a69
dht: fixing timing in SearchNode::canGet
...
When a 'get' request associated with a certain 'query' has been sent, we don't
want to send it again, i.e. we don't care if it's pending or not as soon as it
has been sent.
2016-08-05 21:17:58 -04:00
Simon Désaulniers
7eb5d892f1
search: isDone computes using Request interface
...
There's no need to compute with time since the network engine gives us the
information we need.
2016-08-05 21:17:11 -04:00
Simon Désaulniers
f6cd79952c
node_cache: fix bad condition in getCachedNodes
2016-08-05 13:07:14 -04:00
Adrien Béraud
9c1a0ae27f
freenode: fix typo
2016-08-05 10:23:08 -04:00
Simon Désaulniers
29c1a955d0
readme: add freenode irc opendht channel
2016-08-04 18:33:56 -04:00
Nicolas
b366432a8a
Merge pull request #103 from sim590/sendlisten-loop
...
dht: fix sendListen loop bug
2016-08-04 10:25:22 -04:00
Simon Désaulniers
af8bfdc1c1
dht: fix sendListen loop bug
...
Each time a 'listen' request is sent to the network engine, we track this
request in the upper layer with a map<shared_ptr<Query>, shared_ptr<Request>>.
At some point, this map has to be maintained or totally cleared. However, it was
done wrong, hence the sendListen loop. Clearing a pair <Query, Request> has to
be done when the API user cancels a 'listen' operation.
2016-08-03 18:49:37 -04:00
Simon Désaulniers
88040ad467
dht: display debug info according to query impact
2016-08-03 18:49:10 -04:00
Simon Désaulniers
a35e67bcdf
Merge pull request #101 from kaldoran/optimize_search
...
dht: bootstrap from node cache instead of routing table
2016-08-03 15:31:07 -04:00
kaldoran
df3317a5b2
dht: bootstrap from cache instead of routing table
2016-08-03 10:04:02 -04:00
kaldoran
33f95c00a9
NodeCache: getNode takes bool not int
...
Since this was old code which use int as bool I edit that for a bool [and change related code]
2016-08-02 18:57:20 -04:00
Adrien Béraud
7383505dcc
value: increase max value size to 16KiB
2016-08-01 10:47:21 -04:00
Adrien Béraud
2c9a29af0e
docker: add python, lto, msgpack 2.0
2016-08-01 01:18:37 -04:00
Adrien Béraud
5847273b79
travis: add llvm docker build
2016-07-29 21:37:43 -04:00
Adrien Béraud
98204991ec
travis with docker
2016-07-29 21:37:43 -04:00
Adrien Béraud
b8e10bfe15
const shared_ptr
2016-07-29 21:37:07 -04:00
Adrien Béraud
132fe66699
dhtnode: cleanup
2016-07-29 15:49:43 -04:00
Adrien Béraud
a28fc4dfb1
tools: remove optional arguments
2016-07-29 15:39:50 -04:00
Nicolas
7721aa5643
api: Add value creation timepoint ( #97 )
2016-07-28 17:03:11 -04:00
Nicolas
68707aff17
dht: prevent outdated store of value
2016-07-28 16:58:04 -04:00
Adrien Béraud
3ecbc9adff
Merge pull request #95 from sim590/consistent-so-versionning
...
autotools: versionning consistent with CMake
2016-07-25 17:09:56 -04:00
Simon Désaulniers
b5a7a0ca31
autotools: versionning consistent with CMake
2016-07-25 17:03:57 -04:00
Nicolas
2362db8528
Merge pull request #94 from sim590/storage-unique-ptr
...
dht: make main store a vector<unique_ptr<Storage>>
2016-07-22 17:02:21 -04:00
Simon Désaulniers
62835bdc54
dht: make main store a vector<unique_ptr<Storage>>
...
Since the elements inside are going to be moved constantly during the life of
the node, this design is better. Also, it works around a crash when the store is
resized (elements inside moved) at some point (always happenned the 3rd time)
for some reason. This bug was known when compiled with LLVM >7.3.0 (>clang-703.0.31).
2016-07-22 16:57:46 -04:00
Nicolas
fe1cf209f1
Merge pull request #93 from sim590/select-consistency
...
dht: return consistent query from local storage
2016-07-19 16:47:44 -04:00
Simon Désaulniers
2f72563b1f
dht: return consistent query from local storage
...
When querying from local storage with SELECT f, a FieldValueIndex with empty
fields was returned without considering the SELECT statement requiring only a
field "f".
2016-07-19 15:52:21 -04:00
Simon Désaulniers
0d754d6ca8
doc: clarify dhtnode usage
2016-07-19 14:00:34 -04:00
Simon Désaulniers
f474f6499b
value: missing return, errors on non-gcc
...
Gcc understands the syntax without return value, but this confuses other
compilers.
2016-07-18 14:18:37 -04:00
Adrien Béraud
97baacf609
Merge pull request #79 from sim590/queries
...
[DHT] Queries: remote values filtering
2016-07-11 20:23:15 +02:00
Simon Désaulniers
0fa8cfdb71
tools: enable queries in dhtnode
2016-07-10 19:26:13 +02:00
Simon Désaulniers
78c7cae7e9
dhtrunner: add query in dhtrunner API
2016-07-10 19:26:13 +02:00
Simon Désaulniers
a4834efd37
dht: use queries in dht
2016-07-10 19:26:13 +02:00
Simon Désaulniers
07e4435a07
value: add Query relevant structures
2016-07-10 19:26:04 +02:00
zorun
9f93771771
doc: Fix install path of man page ( #90 )
...
Man pages go in /usr/share/man
http://www.pathname.com/fhs/pub/fhs-2.3.html#USRSHAREMANMANUALPAGES
2016-07-02 14:32:43 +02:00
Simon Désaulniers
a533807fcf
doc: add missing CMakeLists.txt
2016-07-02 01:20:46 +02:00
Simon Désaulniers
49129ec1b2
tools: specify optional arg syntax -o[ARG]
2016-06-30 01:33:14 +02:00
Simon Désaulniers
803354552f
build-tools: distribute dhtnode.1 manpage
2016-06-30 00:58:04 +02:00
Simon Désaulniers
fa6c365679
doc: fix typos in dhtnode manpage
2016-06-29 20:57:30 +02:00
Adrien Béraud
6ac1ae3527
Merge pull request #84 from sim590/dhtnode-user-experience
...
[dhtnode] user experience
2016-06-28 14:55:27 -04:00
Simon Désaulniers
29834b714e
dhtnode: manpage and add all options in help text
2016-06-28 18:51:40 +02:00
Simon Désaulniers
bba27adf4d
dhtnode: fix getopt optional arg parsing
2016-06-27 21:14:54 +02:00
Simon Désaulniers
e3a280d7a9
Merge pull request #82 from aviau/typos
...
fixed typos
2016-06-27 19:46:17 +02:00
aviau
63f1a736f4
fixed typos
2016-06-27 19:33:52 +02:00
Simon Désaulniers
0f8720c433
Merge pull request #80 from aviau/powerful
...
readme: fix typo s/powerfull/powerful/
2016-06-27 15:39:55 +02:00
aviau
7a6263b940
typo: powerfull ->powerful
2016-06-27 15:29:35 +02:00
Adrien Béraud
b09e3df2e2
add network id to distinguish different networks
2016-06-21 03:06:47 -04:00
Adrien Béraud
041a9e0e7f
Clarify GPLv3 "or any later version" licence
2016-06-20 11:47:21 -04:00
Simon Désaulniers
fa9730dd07
add readme help text for benchmark
2016-06-15 15:57:56 -04:00
Adrien Béraud
33f29e95f4
value: add common crypto ops
2016-06-15 13:35:44 -04:00
Adrien Béraud
fdfa10bd2e
dht: clear search before expiring it
2016-06-13 15:55:34 -04:00
Adrien Béraud
f200f9dfc2
pkgconfig: add private dependencies
2016-06-11 21:50:34 -04:00
Adrien Béraud
9615774114
cmake: build versioned shared library
2016-06-11 21:22:27 -04:00
Adrien Béraud
c6b0e531c2
dht: add code documentation
2016-06-11 18:54:18 -04:00
Adrien Béraud
8e5f12dbf1
autotools: handle case where DESTDIR is empty
2016-06-11 16:10:52 -04:00
Adrien Béraud
5bcf1da505
autotools: cleanup
2016-06-11 16:10:27 -04:00
Adrien Béraud
97d88fcfed
autotools: disable doxygen by default
2016-06-11 16:04:35 -04:00
Adrien Béraud
963dd6779e
benchmark: don't block while putting values
2016-06-03 17:20:58 -04:00
Simon Désaulniers
54a4327039
dht: handle search expired before permanent put
2016-06-03 17:20:58 -04:00
Simon Désaulniers
10e5439048
securedht: permanent put of a certificate.
2016-06-03 17:20:58 -04:00
Simon Désaulniers
dcca94aab7
dht,api: enable optional permanent put on dht
...
A permanent put is going to be executed once and every time the data expires on
each SearchNode.
2016-06-03 17:20:58 -04:00
Simon Désaulniers
173a9ee642
revert attempt to avoid securedht cert put fail
2016-06-03 17:20:58 -04:00
Simon Désaulniers
ed1ca6db8f
Revert "dht: wait for connection before running searches"
...
This reverts commit bd08506146 .
2016-06-03 17:20:58 -04:00
Adrien Béraud
7367158284
dht: new insertNode algorithm
2016-06-03 17:20:58 -04:00
Adrien Béraud
cf8d9ccd0d
infohash: merge Windows includes
2016-06-02 17:52:07 -04:00
Adrien Béraud
fdbdc91d55
Merge pull request #74 from sim590/python-destdir
...
[packaging] support python installation with make DESTDIR=$DIR
2016-06-02 15:41:55 -04:00
Simon Désaulniers
cf9c63abb7
enable python make DESTDIR=$DIR install support
2016-06-02 14:48:05 -04:00
Simon Désaulniers
475b26048f
cmake: pass $DESTDIR environnement var to setup.py
2016-06-02 12:36:21 -04:00
Andreas Traczyk
df1615e8d1
Update README.md
2016-06-02 12:22:34 -04:00
Andreas Traczyk
9e461e0960
microsoft compiler support
2016-06-02 12:17:09 -04:00
Adrien Béraud
9411fe4e51
version 0.6.1
2016-05-28 17:01:01 -04:00
Adrien Béraud
3a42846f98
utils: include ws2tcpip.h on Windows
2016-05-28 16:40:56 -04:00
Adrien Béraud
5ca04b1da4
utils: include socket.h
2016-05-27 16:03:30 -04:00
Adrien Béraud
c831ec8f16
rng: add include guard
2016-05-27 15:46:45 -04:00
Adrien Béraud
bd08506146
dht: wait for connection before running searches
2016-05-27 15:39:48 -04:00
Adrien Béraud
d44c59016e
network_engine: remove onNewNode return value
2016-05-27 14:54:56 -04:00
Adrien Béraud
4d75f64576
log: rename ERROR to ERR to build on Windows
2016-05-27 12:30:32 -04:00
Adrien Béraud
c70d5d7b97
dht: don't send nodes in storageChanged
2016-05-27 02:13:08 -04:00
Adrien Béraud
d0cebaa002
dht: clear listen status in cancelListen
2016-05-27 01:56:13 -04:00
Adrien Béraud
564e97fce7
dht: use 4 listen nodes
2016-05-24 03:44:18 -04:00
Adrien Béraud
172b1089fb
dht: search log improvements
2016-05-24 03:44:18 -04:00
Adrien Béraud
6cdc242b6e
node: add pendingMesageCount
2016-05-24 03:44:18 -04:00
Adrien Béraud
ac23464044
network engine: retransmit 'done' param
2016-05-24 03:44:18 -04:00
Adrien Béraud
ce162a39c6
network engine: add logs
2016-05-22 17:00:16 -04:00
Adrien Béraud
db376aa0a2
scheduler: simplify design
2016-05-22 16:56:47 -04:00
Adrien Béraud
8da15ad450
dht: adapt search routine to network engine
2016-05-22 16:56:47 -04:00
Adrien Béraud
5f1b79e6de
dht: minor refactoring/optimisations
2016-05-22 16:56:47 -04:00
Adrien Béraud
0e7dda680a
header cleanup
2016-05-22 16:56:47 -04:00
Adrien Béraud
22958342f1
headers: move inclusion of networking APIs to Infohash
2016-05-20 12:12:44 -04:00
Adrien Béraud
e9094f8f22
README: fix python example
2016-05-19 18:10:17 -04:00
Adrien Béraud
ff2193dcc6
network_engine: add log on node expire
2016-05-19 17:37:39 -04:00
Adrien Béraud
855b69710d
dht: run searchStep imediatly on announce
2016-05-19 17:37:39 -04:00
Adrien Béraud
d93657d6f9
dht: wait for both AF to call callback
2016-05-19 17:37:39 -04:00
Adrien Béraud
2b57c8109a
dht: clear announces on expire
2016-05-19 17:29:19 -04:00
Adrien Béraud
84578f7820
value: reduce size limit to 14KB
2016-05-19 17:28:31 -04:00
Adrien Béraud
14cf0b3142
python: add size proprety
2016-05-19 17:28:31 -04:00
Adrien Béraud
18ec3086ee
python: add blocking put
2016-05-19 17:28:31 -04:00
Adrien Béraud
f7e01da20d
expire node on blacklist
2016-05-19 17:28:31 -04:00
Adrien Béraud
a032f50a27
dht: catch all network engine errors
2016-05-19 17:28:31 -04:00
Adrien Béraud
8ee0d83ad7
dht: log cleanup
2016-05-19 17:28:31 -04:00
Adrien Béraud
f46043069d
revert: dht: limit search nodes to SEARCH_NODES nodes
2016-05-19 01:55:18 -04:00
Adrien Béraud
16290961fb
network engine: add sent data size
2016-05-19 01:55:06 -04:00
Adrien Béraud
bad53219c6
move back to C++11
2016-05-18 04:02:34 -04:00
Adrien Béraud
fc6e884b54
python: adapt to new owner api
2016-05-18 03:29:01 -04:00
Adrien Béraud
9d7f6d287a
dht: clear candidate on expire
2016-05-18 02:19:06 -04:00
Adrien Béraud
17d57ba04a
dht: remove anoying log
2016-05-18 01:23:47 -04:00
Adrien Béraud
9ad21d5c5d
dht: remove newSearch()
2016-05-18 01:23:18 -04:00
Adrien Béraud
891969f5eb
node: reduce max response time to 1s
2016-05-17 20:39:16 -04:00
Adrien Béraud
e68a2fd967
securedht: add public key cache
2016-05-17 20:39:16 -04:00
Adrien Béraud
cc18afd818
value: make 'owner' a shared_ptr
2016-05-17 20:39:16 -04:00
Adrien Béraud
467fdef892
Update README.md
2016-05-16 16:03:58 -04:00
Adrien Béraud
50678f6d44
Accept bitcoin donations
2016-05-16 15:41:20 -04:00
Adrien Béraud
4622a82847
benchmark/get: improve ploting
2016-05-15 01:38:33 -04:00
Adrien Béraud
bd72c6468f
network engine: handle unexpected node id
2016-05-15 01:36:25 -04:00
Adrien Béraud
db6c301084
dht: don't count bad nodes in get request count
2016-05-15 01:28:09 -04:00
Adrien Béraud
faf5c3786f
bump version to 0.6.0
2016-05-14 23:21:04 -04:00
Adrien Béraud
9b14fc8bb8
dht: use method to count requests
2016-05-14 23:16:23 -04:00
Adrien Béraud
79dde3378a
dht: increase max searches
2016-05-14 23:16:23 -04:00
Adrien Béraud
f6b9340313
dht: avoid to discard storage with local listener
2016-05-14 23:16:23 -04:00
Adrien Béraud
8c8e781788
cmake: add LTO support with -DOPENDHT_LTO=On
2016-05-14 23:16:23 -04:00
Adrien Béraud
e03573e520
scanner: don't generate key pair
2016-05-14 23:16:23 -04:00
Adrien Béraud
79d90e480d
dht: limit search nodes to SEARCH_NODES nodes
2016-05-14 15:48:34 -04:00
Adrien Béraud
a926e273af
dht: forward-declare more internal structures
2016-05-14 15:48:34 -04:00
Adrien Béraud
f1b3e41e63
securedht: override all versions of Dht::get
2016-05-14 15:48:34 -04:00
Adrien Béraud
e37307654f
make sure securedht methods override dht's
2016-05-13 16:38:23 -04:00
Adrien Béraud
d3b9c4b7b6
network engine: improve node packing
2016-05-13 16:38:23 -04:00
Adrien Béraud
d26a34f409
node_cache: use std::map
2016-05-13 16:38:23 -04:00
Adrien Béraud
6652f27aae
travis: bump to GCC6
2016-05-13 16:38:23 -04:00
Guillaume Roguez
c5da946e76
crypto: mark all operator bool as explicit
...
If operator bool is not marked as explicit and you try to do such:
a == b
where a and b are instances of class with overloaded bool operator,
the behavior is not the waited one: a and b are casted to bool
BEFORE the comparaison! This could lead into non waited situation.
This patch fixes all operator bool() where overloaded.
This also implements PublicKey operators == and != as needed in value.h.
This last showed a typical case explained upper.
Signed-off-by: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com >
2016-05-10 15:26:15 -04:00
Adrien Béraud
8d23dc75c5
move to C++14
2016-05-10 13:54:05 -04:00
Adrien Béraud
ed8cdfd81a
don't remove flying nodes from searches
2016-05-10 12:50:39 -04:00
Adrien Béraud
91bf5bb41b
allow to cancel request without network engine
2016-05-10 12:50:20 -04:00
Adrien Béraud
040e3770ad
node: use requests to determinate state
2016-05-09 16:17:59 -04:00
Adrien Béraud
3282ebad2e
autotools: add missing files
2016-05-09 16:17:59 -04:00
Adrien Béraud
ef1bf5ccec
move node cache to message engine
2016-05-08 00:37:52 -04:00
Adrien Béraud
8cc53b1751
add node cache, split dhtrunner.h from dht.h
2016-05-08 00:37:52 -04:00
Simon Désaulniers
98a3960bf8
fix wrong std::move in Value::Filter::chain
...
Also, instance calls to Value::Filter::chain methods were moving the calling
instance while you may not want this in many cases.
2016-05-05 16:29:59 -04:00
Adrien Béraud
92613f5fbf
net: improve request state consistency
2016-05-03 18:33:38 -04:00
Adrien Béraud
82970608d4
autotools: add missing files
2016-05-03 14:46:04 -04:00
Adrien Béraud
c215bf1d39
net: a pending request is a non-completed request
2016-05-03 13:56:05 -04:00
Adrien Béraud
add1179bc2
dht: remove constexpr to preserve backward compatibility
2016-05-03 13:55:18 -04:00
Adrien Béraud
733cf335d3
dht: limit concurrent search requests instead of steps intervals
2016-05-03 12:05:14 -04:00
Adrien Béraud
15f4ea4d88
node: add toString()
2016-05-03 11:09:28 -04:00
Adrien Béraud
92df1f5a2b
dht: recompute step time for existing searches
2016-05-02 18:42:14 -04:00
Simon Désaulniers
8cce5cd6e8
removed commented duplicate utility function
2016-05-02 15:25:15 -04:00
Adrien Béraud
820598c179
network engine: change sendError message argument to std::string
2016-05-02 15:25:15 -04:00
Adrien Béraud
a0a108512c
expire request when node is expired
2016-05-02 15:25:15 -04:00
Adrien Béraud
d062f7bd24
make sendPing use Node by default
...
previous code was duplicating nodes, causing
sending many "dubious node" pings to the same node.
2016-05-02 15:25:15 -04:00
Adrien Béraud
0890ed9c4f
move routing table to a different file
2016-05-02 15:25:15 -04:00
Adrien Béraud
f9e6662f7d
use Node in tellListener
2016-05-02 15:25:15 -04:00
Adrien Béraud
20662a9b4c
cancel request when receiving token error
2016-05-02 15:25:15 -04:00
Adrien Béraud
995196ce08
clear getStatus after token error
2016-05-02 15:25:15 -04:00
Adrien Béraud
3367043e92
NE fixes
2016-05-02 15:25:15 -04:00
Simon Désaulniers
badf9a3027
replaced tabs with spaces in multiple files.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
f7a334a979
dht: make sure searchStep is called when needed.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
08dc666839
dht: network engine does the node ping count
2016-05-02 15:25:15 -04:00
Simon Désaulniers
4a9ae1d42a
handling the reply_time in network engine
2016-05-02 15:25:15 -04:00
Simon Désaulniers
ce8af64775
removed unwanted check when receiving listen request
2016-05-02 15:25:15 -04:00
Simon Désaulniers
97fccc4458
dht: fix drop due to ratelimit bug
2016-05-02 15:25:15 -04:00
Simon Désaulniers
ee31881825
changed license to GPLv3
2016-05-02 15:25:15 -04:00
Simon Désaulniers
dafae934c4
actually cancelling listens when appropriate
...
Just before, listens were "cancelled", but unsued memory in network engine's
data structure would be left there.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
2a88117dd4
netengine: merging RequestStatus, Request
...
This is a change needed to enable easy and clean cancelling of requests from the
upper layer (dht layer). Request's content that was hidden from (dht layer) is
still hidden (private), but enable NetworkEngine as a friend of the Request
class for accessing lower layer attributes.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
65cd72b8d5
dht: remove reply time setting. handled by net engine
2016-05-02 15:25:15 -04:00
Simon Désaulniers
72f4d58f7e
dht: fix listen confirmation, getvalues concurency
...
Upon receiving a listen confirmation, a Request structure shall be left alive in
the NetworkEngine's map so that further 'get values' answers for that same
listen can be treated properly. This was sort of handled before, but with a
concurency issue between the set of values returned associated to the listen
request and just before the listenConfirmation was returned.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
717b58fcc6
dht: handling get token only after 'get' request.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
d52fb6ad5d
make sure expire functions are scheduled
2016-05-02 15:25:15 -04:00
Simon Désaulniers
0240ca6394
dht: fix first put hang due to empty token
...
At some point, old nodes didn't provide token in a find_node request. Since a
find_node request may be used to initiate a search before a 'put', now have to
be provided. In order to discard old nodes which don't have that behavior, we
blacklist the nodes.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
1ecfbb7181
properly handle empty token case after get request
...
Upon a response, if token is empty, the treatment of the response shall not be
done.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
608be10446
using SearchNode::last_get_reply in dumpsearch
2016-05-02 15:25:15 -04:00
Simon Désaulniers
d5f67e97d0
dht: let Dht::inserNode set SearchNode reply time
2016-05-02 15:25:15 -04:00
Simon Désaulniers
ba5953bc6b
reference instead of copy, removing forgotten cout
2016-05-02 15:25:15 -04:00
Simon Désaulniers
4aad11f003
dht: fix Scheduler::run() job calls order
...
When executing a job, the internal jobs map can be changed, therefor successive
job calls have to make another call to timers.begin() to get the first job to
execute.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
dc1e1d9454
stop stacking jobs now rescheduling instead
2016-05-02 15:25:15 -04:00
Simon Désaulniers
674f25fcae
fix listen was not handled...
2016-05-02 15:25:15 -04:00
Simon Désaulniers
abd358f57d
fix: 'get' requests responses without values...
2016-05-02 15:25:15 -04:00
Simon Désaulniers
fa94ce90ac
naming consistency changes in network engine
2016-05-02 15:25:15 -04:00
Simon Désaulniers
2f26580881
fix unused variables...
2016-05-02 15:25:15 -04:00
Simon Désaulniers
6a46466493
dht: mybucket grow time optimization
...
this lets a new network grow faster and appropriately triggers bucket
neighborhood maintenance when intended: when our bucket is growing.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
120dc509cf
fix 'get' request stuck/slow, handling candidates
...
Making a call to searchSendGetValues() when a 'get' request finishes/expires,
accelerates the process in the same way it was done before. Candidates also let
the requests resolve faster.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
ff72487b02
fix no values sent in response to 'find' request
...
This was due to using the wrong InfoHash field from the ParsedMessage when
responding to 'find' request.
2016-05-02 15:25:15 -04:00
Simon Désaulniers
8cc6c21d19
keeping last get reply time in search nodes
2016-05-02 15:25:15 -04:00
Simon Désaulniers
d8716e4bd4
adding missing file includes (src,cmake,autotools)
2016-05-02 15:25:15 -04:00
Simon Désaulniers
66e8cf431b
add missing MSG_CONFIRM definition
2016-05-02 15:25:15 -04:00
Simon Désaulniers
c299385401
add forgotten sendPing signature change
2016-05-02 15:25:15 -04:00
Simon Désaulniers
e32e480a12
fixing scheduler wrong time returned on run()
2016-05-02 15:25:15 -04:00
Simon Désaulniers
8b35e2bc09
fix some segfault errors
2016-05-02 15:25:15 -04:00
Simon Désaulniers
24527e921a
preventing Dht::confirmNode to be auto scheduled twice
...
Since Dht::confirmNode is called on a connectivity change, Dht::confirmNode
would be scheduled and rescheduling itself all over again and such a chain of
event would be triggered *each* time a connectivity change happenned. We only
want Dht::confirmNode to be called once when a connectivity change happen. Then,
the initial chain of confirmNode calls will go on fine.
2016-05-02 15:25:15 -04:00
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
Simon Désaulniers
68fceac433
dht: fixes out of range container erase
2016-04-14 18:07:07 -04:00
Adrien Béraud
8ae95f1284
build: always define HAVE_PIP macro
2016-04-13 12:32:00 -04:00
Adrien Béraud
db5cac4556
crypto: avoid forward declarations
2016-04-11 15:16:36 -04:00
Adrien Béraud
1c8735e71a
crypto: use argon2 for key stretching
2016-04-11 15:16:36 -04:00
Adrien Béraud
52b10819de
crypto: add key stretching
2016-04-11 15:16:36 -04:00
Adrien Béraud
a7da1b4288
Merge pull request #57 from sim590/benchmark-dht-log
...
Enabling dht log in the benchmark
2016-04-11 12:06:42 -04:00
Adrien Béraud
b19e9e1784
Merge pull request #58 from yomgui1/master
...
dht: ensure to not copy Storage instances
2016-04-11 12:03:20 -04:00
Guillaume Roguez
5d9c6090dd
dht: ensure to not copy Storage instances
...
This path deletes copy-constructor and copy-assignement and
default defines move-contructor and move-assignement methods.
Also uses emplace_back than push_back on dht::store vector
to have a better efficiency.
Signed-off-by: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com >
2016-04-11 11:46:24 -04:00
Adrien Béraud
8d69de598a
Merge pull request #55 from sim590/progressive-refill
...
Search progressive refill optimisation
2016-04-11 11:28:44 -04:00
Adrien Béraud
49db43372b
im message: add status field
2016-04-10 19:43:50 -04:00
Simon Désaulniers
30ba6baf39
benchmark: add minor logs in 'get', 'put' requests
2016-04-09 00:42:22 -04:00
Simon Désaulniers
2329239843
add delay between two successive refills
...
3 searchStep calls is what's needed to flag a node expired. So waiting at least
3 times SEARCH_GET_STEP time seems reasonable.
2016-04-08 23:12:09 -04:00
Simon Désaulniers
21667141ad
refill Search in unsynced state as much as needed
...
Search::refilled removed so that any number of refill may be done.
2016-04-08 23:11:02 -04:00
Simon Désaulniers
9e7babc707
changed Search::refill to progressive approach
...
In order to optimize the refill of a search with good SearchNode, the refill is
now done at each call of searchStep(). A "refill" will try to add more good
nodes to the search until the search has reached SEARCH_NODES good nodes.
2016-04-08 23:10:05 -04:00
Simon Désaulniers
e9bda23ae4
add Search::getNumberOfBadNodes() method
2016-04-08 23:10:05 -04:00
Simon Désaulniers
12f4139fcc
dht: removing good and expired nodes appropriately
...
When inserting a node and that the maximum of good nodes has been reached, a
good node must be removed. This is also a good time to remove an expired node
from the search if there is one.
2016-04-08 23:09:58 -04:00
Simon Désaulniers
0f5086fef5
benchmark: toggling bootstrap dht log USR1 signal
2016-04-08 18:36:41 -04:00
Simon Désaulniers
b7004f6051
benchmark: add option for getting bootstrap log
2016-04-08 18:36:41 -04:00
Simon Désaulniers
9868a79381
python: enabling dht log through cython API
2016-04-08 18:36:36 -04:00
Simon Désaulniers
4e54ac3ac3
dht: adding dht::log common utilities namespace
2016-04-08 18:36:02 -04:00
Adrien Béraud
53bea202a2
Merge pull request #46 from sim590/pip-uninstall
...
[autotools] pip to uninstall python files
2016-04-08 11:21:52 -04:00
Simon Désaulniers
daca16a917
disable removing from record file.
2016-04-06 15:26:05 -04:00
Simon Désaulniers
8a281c1d2c
fallback to setup.py generated install record
2016-04-06 15:10:57 -04:00
Adrien Béraud
3e4a739d9f
crypto: check key size in aesEncrypt
2016-04-05 16:00:51 -04:00
Adrien Béraud
fa0f123803
python: run callback in main thread
2016-04-02 20:55:45 -04:00
Adrien Béraud
7b1707299c
crypto: improve documentation
2016-03-24 21:32:05 -04:00
Adrien Béraud
05727a1515
Merge pull request #53 from sim590/benchmark-traffic-test
...
[Benchmark] traffic test
2016-03-23 13:51:40 -04:00
Simon Désaulniers
2289243bfc
benchmark: fix tests + new test: totallyNormalTest
...
The "Totally normal test" is meant to create a realistic environment, i.e.
with normal asynchronous packet activity. This is useful in order to
differentiate normal and data persistence traffic.
2016-03-13 18:46:23 -04:00
Simon Désaulniers
5b3b22edee
benchmark: refactor and enhance network.py IPC
2016-03-13 18:46:23 -04:00
Adrien Béraud
059e0a5fac
Merge pull request #50 from sim590/link-libraries
...
Specifying linking libraries in CMake
2016-03-04 12:46:20 -05:00
Simon Désaulniers
7a27dace9c
Specifying linking libraries in CMake
...
It appears that when cmake runs on some platforms, it can't figure out the
linking flags itself. This patch adds this.
2016-03-04 12:38:03 -05:00
Simon Désaulniers
7168022915
pip to uninstall python files
2016-02-29 12:58:23 -05:00
Adrien Béraud
a4a54af391
bump version to 0.5.2
2016-02-19 01:16:00 -05:00
Adrien Béraud
9f4ca6c8f3
crypto: avoid to copy iv during encryption
2016-02-19 01:16:00 -05:00
Adrien Béraud
c753977d5c
dhtrunner: reduce stack usage
2016-02-19 01:16:00 -05:00
Adrien Béraud
3e4b650aca
Update README.md
2016-02-19 00:58:45 -05:00
Adrien Béraud
b698687f99
crypto: add documentation
2016-02-18 22:24:33 -05:00
Adrien Béraud
92962f78f4
Update README.md
2016-02-16 22:07:18 -05:00
Simon Désaulniers
bfe41dbb45
Merge pull request #36 from kaldoran/log_print
...
Using standard library function for handling ascii out of range characters.
2016-02-15 12:39:58 -05:00
Adrien Béraud
712d8a011b
Merge pull request #35 from sim590/cmake_msgpack
...
Update FindMsgpack.cmake fixing "not found" error
2016-02-15 11:40:21 -05:00
Edric
9fbe11738d
Remove int/unsigned int comparison warning
2016-02-15 11:33:35 -05:00
Kaldoran
47e56f2397
Change ascii value to std::isprint() function
2016-02-15 11:28:44 -05:00
Simon Désaulniers
8c2cc749ab
Update FindMsgpack.cmake fixing "not found" error
...
This fix was written by people working on the neovim project:
https://github.com/neovim/neovim/commit/1d1574e0aca3cd270e7d4b2656e1aa11861d70af
2016-02-15 11:23:20 -05:00
Adrien Béraud
71b6998ea0
dht: step to clear announces in case of failure
2016-01-28 01:07:35 -05:00
Adrien Béraud
b640f34949
rng: fix typo
2016-01-28 01:07:35 -05:00
Adrien Béraud
1d4d67038a
dht: fix compilation on older clang
2016-01-22 15:35:45 -05:00
Adrien Béraud
d5dcfa0889
dht: introduce and enforce a maximum storage size
...
The default storage limit is 64 MB
2016-01-22 02:01:07 -05:00
Adrien Béraud
b304418d43
dht: ensure search response include a token
2016-01-22 01:47:19 -05:00
Adrien Béraud
3d499bff14
dht: reset flags when reanouncing
2016-01-22 01:45:51 -05:00
Adrien Béraud
d6d72597be
dht: check value size before forging packet
2016-01-19 15:24:05 -05:00
Adrien Béraud
3ee22bb6d7
dht: avoid building oversized UDP packets
2016-01-19 15:24:05 -05:00
Adrien Béraud
9ee962bd21
dht: cleanup storage log
2016-01-19 15:23:37 -05:00
Adrien Béraud
a44b809513
dht: get token with find_nodes, use it for announces
2016-01-19 15:23:37 -05:00
Adrien Béraud
b2ee07861d
reduce default storage time to 10 minutes
2016-01-19 15:23:37 -05:00
Adrien Béraud
388d43b89a
reduce maximum value size to 56 KB
...
A larger maximum size was supported by the protocol but
not the underlying transport (UDP).
2016-01-19 15:23:37 -05:00
Adrien Béraud
6b83077a33
Merge pull request #33 from sim590/benchmark-python-test-cleanup
...
Benchmark python test cleanup
2016-01-14 17:03:52 -05:00
Simon Désaulniers
4070a19c59
fixing missing import of modules
2016-01-14 16:56:24 -05:00
Simon Désaulniers
b6d7436595
benchmark: python decorator for setting up tests
2016-01-14 16:37:20 -05:00
Simon Désaulniers
5f9e20998f
python tests refactoring
2016-01-14 16:34:43 -05:00
Adrien Béraud
6910a7c0ae
Merge pull request #32 from sim590/benchmark-refactor
...
Benchmark refactor
2016-01-13 17:00:52 -05:00
Simon Désaulniers
77c480e2cf
refactored python benchmark in separate modules
2016-01-12 12:38:58 -05:00
Simon Désaulniers
2c22c7d984
more code refactoring
2016-01-12 12:38:58 -05:00
Simon Désaulniers
6c3c19c0c8
add test for performance while deleting nodes
2016-01-12 12:38:58 -05:00
Simon Désaulniers
252ff4710c
FeatureTest child classes code factorized.
...
# Conflicts:
# python/tools/benchmark.py
2016-01-12 12:38:58 -05:00
Adrien Béraud
dd107e6f6d
python: fix licenses terms
2016-01-09 18:05:42 -05:00
Adrien Béraud
175b4c9491
python: add Value.id proprety
2016-01-09 16:05:26 -05:00
Adrien Béraud
cd296b9d22
Merge pull request #31 from cyrilleberaud/master
...
python/scanner: add ip number on the plot
2016-01-09 16:02:24 -05:00
Cyrille Béraud
44373bd5f6
python/scanner: add ip number on the plot
2016-01-09 14:30:28 -05:00
Adrien Béraud
e00c8e9598
update copyright headers for 2016
2016-01-07 18:02:35 -05:00
Adrien Béraud
e97355ed49
update version to 0.5.1
2016-01-05 17:06:02 -05:00
Adrien Béraud
180e34538d
Merge pull request #28 from sim590/llvm-lack-of-cpp11
...
Fix #26 : add duration cast
2016-01-05 16:08:49 -05:00
Simon Désaulniers
1aae8f37dd
adding duration cast for llvm compatibility
2016-01-05 15:54:55 -05:00
Adrien Béraud
13a2df8911
python: fix typo in benchmark
2016-01-05 12:25:35 -05:00
Adrien Béraud
922b0e147b
Merge pull request #27 from justusranvier/cmake
...
Minor cmake fixes
2015-12-24 13:12:59 -05:00
Justus Ranvier
9635ebe7a4
update Makefile for msgpack and pthread
2015-12-23 21:26:26 -06:00
Justus Ranvier
4e8182a84e
add KDevelop files to .gitignore
2015-12-23 21:16:56 -06:00
Justus Ranvier
002b8377dd
bump msgpack required version to 1.2 since package doesn't compile against 1.1
2015-12-22 16:19:35 -06:00
Justus Ranvier
263aef687c
add -pthread to CXX_FLAGS
2015-12-22 16:18:51 -06:00
Guillaume Roguez
8c552d3466
default_types: virtualize msgpack_unpack
...
This is needed to override this method in inheriting.
2015-12-22 11:46:43 -05:00
Adrien Béraud
439b7d966c
dhtnode: daemonize with the new -d argument
...
Running dhtnode with -d will make it detach and fork.
Add an argument to -v to log to a file instead of stdio.
2015-12-19 20:33:03 -05:00
Guillaume Roguez
1a888dbe66
Fix RCTP multi-inheriting in Serialized and derived classes
...
This patch fixes Serialized derived classes, using CRTP idom,
by fixing the "constructor forwarding problem".
A derived class has no to use dht::Value::Serialized<Derived, Base>
as super class, by replacing itself in "Derived" and use the
right "Base" class. Ex:
class MyImMessage : public dht::Value::Serializable<MyImMessage, dht::ImMessage>
{
...
}
No more needed to overload getType and define TYPE static.
2015-12-18 21:31:37 -05:00
Adrien Béraud
94bfc67708
value: add non-static unpack<T>()
2015-12-17 15:31:41 -05:00
Adrien Béraud
d5ed6ca8e8
switch to new ICE serialisation
2015-12-17 15:31:41 -05:00
Adrien Béraud
62583557c0
rng: code cleanup
2015-12-17 15:31:41 -05:00
Adrien Béraud
8d1c3f1bbe
dht: drop storage immediately after retransmission
2015-12-17 15:31:41 -05:00
Adrien Béraud
e102e2b673
dht: findStorage now returns iterator instead of pointer
2015-12-17 15:31:41 -05:00
Adrien Béraud
884fcbe1e0
Update README.md
2015-12-17 11:22:47 -05:00
Adrien Béraud
0fafcacdfa
Merge pull request #25 from sim590/dp-enhance
...
Data persistence: only store relevant values
2015-12-16 23:36:04 -05:00
Simon Désaulniers
38306eaec5
only one refill allowed before expiring search
2015-12-15 18:18:17 -05:00
Simon Désaulniers
04632a8288
fix findclosestnodes() (was inverted)...
2015-12-15 18:18:14 -05:00
Simon Désaulniers
2dcaef5c97
accept storing values based on XOR proximity to id.
2015-12-15 18:17:37 -05:00
Simon Désaulniers
e447dc5e36
removed undefined function in header
2015-12-14 17:54:26 -05:00
Adrien Béraud
b7e0f73931
Update README.md
2015-12-13 02:09:17 -05:00
Adrien Béraud
1f25263d71
Update README.md
2015-12-13 02:08:55 -05:00
Adrien Béraud
c37a4411fc
Update README.md
2015-12-13 01:31:03 -05:00
Adrien Béraud
ebb4c5f983
Update README.md
2015-12-13 01:30:40 -05:00
Adrien Béraud
142ca8bf42
Update README.md
2015-12-13 01:13:09 -05:00
Adrien Béraud
0076ae001c
dht: drop value after successfull announce
2015-12-10 17:26:39 -05:00
Adrien Béraud
9a301569a4
dht: use proper value in log
2015-12-10 15:06:25 -05:00
Adrien Béraud
74aae03b5f
dhtnode: gracefully stop node
2015-12-10 13:18:55 -05:00
Adrien Béraud
67464fde9a
dhtrunner: run shutdown in priority queue
...
Fix calling shutdown on a non-connected node.
2015-12-10 13:18:55 -05:00
Adrien Béraud
328a61df00
dht: preserve value creation time
2015-12-10 13:18:55 -05:00
Adrien Béraud
04aa3d3dba
dht: improve value storage log
2015-12-10 13:18:55 -05:00
Adrien Béraud
2842f45cbd
dhtchat: show public key ID
2015-12-09 14:40:58 -05:00
Adrien Béraud
8fd71c7f3d
dhtrunner: add missing shared_ptr<Value> versions of putSigned, putEncrypted.
2015-12-09 14:40:00 -05:00
Adrien Béraud
af6f33e9ee
Merge branch 'casparcedro-master'
2015-12-07 12:20:09 -05:00
Adrien Béraud
aed80a04eb
Merge branch 'master' of https://github.com/casparcedro/opendht into casparcedro-master
2015-12-07 12:11:32 -05:00
Adrien Béraud
7c1beeaa5c
Merge pull request #17 from savoirfairelinux/yomgui-patch-dht
...
Simplify the simplification
2015-12-07 12:01:58 -05:00
casparcedro
895492450c
Updated tools/tools_common.h to remove std::to_string
...
Fixed for building with cygwin.
2015-12-06 23:07:55 -05:00
casparcedro
fb0450d309
Updated tools/dhtnode.cpp to remove std::to_string
...
Fixed for building with cygwin.
2015-12-06 23:06:06 -05:00
Adrien Béraud
0a4195ae08
Update README.md
2015-11-20 22:30:26 -05:00
Adrien Béraud
aa08cf488c
Merge pull request #19 from sim590/dp-enhance
...
performance fix to data persistence feature
2015-11-17 00:43:39 -05:00
Simon Désaulniers
725ca7a4d6
only remove Announce upon value expiration time
2015-11-16 22:15:06 -05:00
Adrien Béraud
d1c4d2446e
add Simon Désaulniers to author lists
2015-11-13 16:45:43 -05:00
Adrien Béraud
cdec9b0d24
value: add documentation
2015-11-08 16:13:04 -05:00
Adrien Béraud
46ab981eab
dhtrunner: update documentation
2015-11-08 16:13:04 -05:00
Adrien Béraud
f94de5ac2b
values: apply a maximum value size
2015-11-08 16:06:30 -05:00
Adrien Béraud
4aebef5e51
dhtrunner: don't block networking thread during processing
2015-11-08 16:06:30 -05:00
Adrien Béraud
7e346cfcb8
update license terms
...
* removed OpenSSL exception
(OpenDHT doesn't make use of OpenSSL)
* properly capitalize "Savoir-faire Linux"
2015-11-08 16:06:30 -05:00
Adrien Béraud
430daf5986
add utils module for common definitions/utilities
2015-11-08 16:06:30 -05:00
Adrien Béraud
78e5c6fc5f
autoconf: readline dependency is mendatory
2015-11-06 13:07:46 -05:00
Adrien Béraud
8575bd4f96
dht: allow to specify address family for getPublicAddress
2015-11-06 01:49:13 -05:00
Adrien Béraud
a340943994
dht: clear bad nodes on connectivity change
2015-11-06 00:51:58 -05:00
Adrien Béraud
a073fd468d
autoconf: add readline dependency for tools
2015-11-06 00:51:58 -05:00
Guillaume Roguez
0a9bd2b783
Simplify the simplification
...
lol!
2015-10-13 18:37:05 -04:00