Ian Jackson
e004316942
impl_standard_builder: Use for tor_guardmgr::FallbackDir
2022-06-16 15:42:06 +01:00
Ian Jackson
17caebd284
impl_standard_builder: Use for tor_dirmgr::DownloadSchedule
2022-06-16 15:42:06 +01:00
Ian Jackson
c466f13ce3
impl_standard_builder: Use for arti::logging::LogfileConfig
2022-06-16 15:42:06 +01:00
Ian Jackson
90ba8b15de
impl_standard_builder: Allow for !Default
2022-06-16 15:42:06 +01:00
Ian Jackson
c5bbaf470a
arti: logging config: Replace a manual Debug impl
2022-06-16 15:27:00 +01:00
Ian Jackson
8b724d40f8
impl_standard_builder: Use for tor_dirmgr::DownloadScheduleConfig
2022-06-16 15:27:00 +01:00
Ian Jackson
2ab5c0861e
impl_standard_builder: Use for tor_dirmgr::NetworkConfig
2022-06-16 15:27:00 +01:00
Ian Jackson
e32210a398
impl_standard_builder: Use for tor_dirmgr::DirSkewTolerance
2022-06-16 15:27:00 +01:00
Ian Jackson
c895057cb9
tor-config: impl_standard_builder: handle contexts with local Result
2022-06-16 15:27:00 +01:00
Ian Jackson
4c65e9994d
Add some missing `serde(default)` to uses of humantime_serde::option
...
Without this, if the substructure is provided, these fields are
mandatory within it.
2022-06-16 11:08:16 +01:00
Nick Mathewson
2d39545f8d
Merge branch 'unwrap' into 'main'
...
tor-netdir: testnet: Make construct_netdir infallible
See merge request tpo/core/arti!585
2022-06-13 14:37:08 +00:00
Nick Mathewson
d44dd6f44f
Merge branch 'dormant_directory' into 'main'
...
Use TaskSchedule to sleep in directory bootstrapping
Closes #497
See merge request tpo/core/arti!571
2022-06-13 13:59:26 +00:00
Ian Jackson
3e035927f2
tor-netdir: testnet: Make construct_netdir infallible (rustfmt)
...
Run rustfmt. Separate commit to make review of the substantive commit
easier.
2022-06-13 14:26:32 +01:00
Ian Jackson
7d223ac9e6
tor-netdir: testnet: Make construct_netdir infallible
...
This is a *lot* of unwraps. The function takes no parameters and
is used only for testing. It ought to be infallible.
2022-06-13 14:25:45 +01:00
eta
f7a9274e57
Merge branch 'option' into 'main'
...
config: Be consistent about Option
Closes #488
See merge request tpo/core/arti!582
2022-06-13 12:30:03 +00:00
eta
ca38fbeaaf
Merge branch 'doc' into 'main'
...
tor-error: Fix a broken intra-doc link
See merge request tpo/core/arti!580
2022-06-13 12:29:29 +00:00
Nick Mathewson
2129aee6cd
DirMgr: Use scopeguard crate in place of ad hoc RAII substitutes
2022-06-13 08:28:41 -04:00
Nick Mathewson
a7b406e69f
Put the task schedule back when the dl task exits.
...
This will allow somebody else to call bootstrap() if bootstrap() fails
the first time.
2022-06-13 08:28:41 -04:00
Nick Mathewson
430f4ffb86
New API to expose and use TaskHandle from DirMgr.
...
This change also means that we need to create the handle and scheduler
earlier in the process of creating the DirMgr. If we don't, we won't
have a way to manage the task before bootstrap() returns.
2022-06-13 08:28:41 -04:00
Nick Mathewson
171b406b00
DirMgr: Refactor bootstrap to use a TaskSchedule for sleeping.
...
This change (not yet exposed as an API) will let the TorClient have
a `TaskHandle` corresponding to the directory task, letting it
make the directory task dormant as needed.
2022-06-10 13:59:30 -04:00
Nick Mathewson
947bbe6fe7
TaskSchedule: Add a sleep_until_wallclock method too.
2022-06-10 13:59:30 -04:00
Nick Mathewson
e7681ca135
Merge branch 'nested-read-write' into 'main'
...
tor-bytes: read_nested_*: Take a closure
Closes #498
See merge request tpo/core/arti!579
2022-06-10 14:27:08 +00:00
Nick Mathewson
4f6c4f91c9
Merge branch 'channel' into 'main'
...
Have channel reactor able to send channel padding
See merge request tpo/core/arti!574
2022-06-10 13:28:51 +00:00
Ian Jackson
d22f6007f0
config: document semver change
2022-06-10 14:28:36 +01:00
Ian Jackson
baca49e087
config: Suppose that we might extend resolve_option to non-T::Default
...
As per point 3 in
https://gitlab.torproject.org/tpo/core/arti/-/issues/488
2022-06-10 14:23:16 +01:00
Ian Jackson
77f33176c3
config: Do not strip_option for journald (and in future)
...
As per point 1 in
https://gitlab.torproject.org/tpo/core/arti/-/issues/488
2022-06-10 14:23:13 +01:00
Ian Jackson
abea103bb0
tor-error: Fix a broken intra-doc link
...
I didn't spot this in review amongst the other messages from Nightly.
2022-06-10 13:45:30 +01:00
Ian Jackson
03a19f3877
tor-bytes: read_nested_*: rustfmt
...
I disagree with almost all of these layout decisions...
2022-06-10 12:30:22 +01:00
Ian Jackson
8fe63b3192
tor-bytes: read_nested_*: Take a closure
...
This eliminates the possibility of writing the bug of failing to call
`should_be_exhausted`.
As per this discussion
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/572#note_2811464
Fixes #498
2022-06-10 12:27:00 +01:00
Ian Jackson
a38c86a020
Merge branch 'format-ids' into 'main'
...
Replace four very similar "ids in request"
See merge request tpo/core/arti!577
2022-06-10 11:21:15 +00:00
Ian Jackson
dc387e10a6
dirclient: Fix comments re conssensus request without authorities
2022-06-10 11:25:34 +01:00
Ian Jackson
605a988a60
Merge branch 'typos' into 'main'
...
Fix typos
See merge request tpo/core/arti!578
2022-06-10 10:19:37 +00:00
Dimitris Apostolou
9bbb0cf3dd
Fix typos
2022-06-10 07:03:50 +03:00
Ian Jackson
8731e45001
Merge branch 'nested-read-write' into 'main'
...
Introduce and use nested length reader/writers
See merge request tpo/core/arti!572
2022-06-09 16:46:19 +00:00
Nick Mathewson
a2c6bd08fe
Fix typos in docs and comments
2022-06-09 17:08:56 +01:00
Ian Jackson
bcf3bca211
tor-cell: udp: Remove manual length calculations
...
This does away entirely with `wire_addr_len`, which recapitulates the
length calculation.
2022-06-09 17:08:56 +01:00
Ian Jackson
6f92bf9e86
tor-bytes: Provide nested writers
2022-06-09 17:08:56 +01:00
Ian Jackson
a6a48c3c28
tor-bytes: Provide nested readers
2022-06-09 17:08:56 +01:00
Ian Jackson
04bca2e75a
tor-bytes: Reader: Provide take_rest
...
We'll want this in a moment.
2022-06-09 17:08:56 +01:00
Ian Jackson
655804f804
tor-bytes: Prepare errors for nested reader/writer
...
Writing is going to be able to give errors too.
2022-06-09 17:08:56 +01:00
Ian Jackson
1c6ca6d286
channel padding timer: Explain why next() in select_biased!
2022-06-09 16:56:33 +01:00
Ian Jackson
9c92022663
channel padding timer: document state invariants
...
There aren't very many.
2022-06-09 16:31:11 +01:00
Ian Jackson
be04c05cce
Fix more typos in comments, from a spellchecker
2022-06-09 16:31:08 +01:00
Nick Mathewson
e8999d0b57
Merge branch 'clippy' into 'main'
...
clippy: Allow dbg in tests *again*
See merge request tpo/core/arti!575
2022-06-09 15:17:09 +00:00
Nick Mathewson
2a53460d4e
Merge branch 'topo' into 'main'
...
Fix topo sorting of Cargo.toml and reorganise CI jobs a bit
Closes #495
See merge request tpo/core/arti!576
2022-06-09 15:16:15 +00:00
Nick Mathewson
b9db07fea9
Fix typo in comment
2022-06-09 15:01:56 +00:00
Nick Mathewson
1adc65ab53
Fix erroneous comment
2022-06-09 14:58:30 +00:00
Nick Mathewson
5815e14b94
Fix typos in comments
2022-06-09 14:58:17 +00:00
Nick Mathewson
38fcca7847
Fix typo in clippy-nightly.toml
2022-06-09 14:08:48 +00:00
Ian Jackson
eb7bcc963b
dirclient: Replace four very similar "ids in request"
...
In reviewing !553 I noticed that the empty digest list error had to be
handled in two places. I filed #492 about the duplication.
In fact it turns out to have been quadruplication.
The new code also avoids cloning the underlying objects, instead
sorting a Vec of references.
2022-06-09 15:05:32 +01:00