Ian Jackson
2ae8a52371
bridge descriptors: Add clarification about bridge states
2022-11-03 11:37:30 +00:00
Ian Jackson
ad39873782
bridge descriptors: Improve and fix docs for consider_launching
2022-11-03 11:37:30 +00:00
Ian Jackson
d44bc1d0f8
bridge descriptors: Add comments where StateGuard is dropped
2022-11-03 11:37:30 +00:00
Ian Jackson
54e51cdba5
bridge descriptors: Document `changed` and `earliest_timeout` Options
2022-11-03 11:37:30 +00:00
Ian Jackson
fb4ffb76fd
bridge descriptors: Document updates argument to timeout_task
2022-11-03 11:37:30 +00:00
Ian Jackson
48f48841e1
Require derive_more 0.99.3
...
0.99.[012] have a bug https://github.com/JelteF/derive_more/issues/114
which makes the Deref derive for bridgedesc::StateGuard not work
and therefore breaks minimal-versions CI.
It seems simpler to require the newer version everywhere.
2022-11-03 11:37:23 +00:00
Ian Jackson
8eb7c731a2
bridge descriptors: Tests
2022-11-03 11:37:05 +00:00
Ian Jackson
3a185d61df
bridge descriptors: Provide a consistency check function
...
This is really part of the tests, but I put it here so that it can be
compiled-in if someone wants it during debugging.
2022-11-03 11:37:05 +00:00
Ian Jackson
51b4588cc0
bridge descriptors: Provide an implementation of BridgeDescProvider
...
Tests will come in a moment.
2022-11-03 11:37:05 +00:00
Ian Jackson
0fb535ba28
tor-dirclient: Response: Provide into_output_string
...
This is the missing one of the full set. It turns out that I wanted
this rather than the non-consuming output_string.
2022-11-03 11:37:05 +00:00
Ian Jackson
42f9651b8e
Copy tor-netdoc/testdata/routerdesc1.txt into tor-dirmgr
...
This seems better than having tor_netdoc export a `#[cfg(test)]`
public constant.
2022-11-03 11:37:05 +00:00
Nick Mathewson
66f34ee774
Merge branch 'guards_as_bridges_part3' into 'main'
...
GuardMgr: decouple NetDir from guards and sample code.
See merge request tpo/core/arti!815
2022-11-02 12:41:03 +00:00
Nick Mathewson
c2ed381c99
Refactor CandidateStatus API to simplify code in descs.
...
This removes some duplication.
2022-11-02 08:07:32 -04:00
Nick Mathewson
fc0c12510a
GuardMgr: Fix and improve comments based on review.
2022-11-02 08:07:32 -04:00
Nick Mathewson
6828178dec
guardmgr: fix rustdoc references.
2022-11-02 08:07:32 -04:00
Nick Mathewson
08473872ab
guardmgr: Refactor candidate info; add `full_dir_info`
...
Previously we always set `dir_info_missing` to `false` for new
guards, since new guards could only be taken from ones that were
present in the NetDir. But for bridges, we don't download their
info until _after_ we have chosen them as guards.
2022-11-02 08:07:11 -04:00
Nick Mathewson
5867318a35
guardmgr: Implement Universe for bridges.
...
Now we can use a group of bridges as the basis for a sample of
guards.
2022-11-02 08:06:43 -04:00
Nick Mathewson
79dade342a
guardmgr: Universe API should look up by ChanTarget
...
This will be necessary for bridges.
2022-11-02 08:06:43 -04:00
Nick Mathewson
82e9a57012
guardmgr: take sampled guards from Universe.
...
This is a trickier case, since we have to deal with weights.
2022-11-02 08:06:43 -04:00
Nick Mathewson
7733146c8c
guardmgr: Continue porting porting code to use Universe.
...
Two more simple cases that can use Universe instead of Netdir.
2022-11-02 08:06:20 -04:00
Nick Mathewson
fbcacea993
guardmgr: Begin to decouple guards from NetDir.
...
In this and the upcoming commits I'll be changing how guards related
to `NetDir` and to `Relay`. Previously, a guard could only come
from (or be updated from) a `Relay` in a `NetDir`. Soon it will be
able to be built from a bridge as well.
To do this, I'm defining a `Universe` trait (name negotiable) that
represents a set of things that may be guards. I'm going to
continue extending its functionality until there are no more
methods in guard.rs or sample.rs that take `NetDir`.
This commit removes most of the usage of `NetDir` and `Relay` in
`guard.rs`.
2022-11-02 08:05:51 -04:00
Nick Mathewson
b5f498021d
guardmgr: Rename microdescriptor_missing to dir_info_missing
2022-11-02 07:59:56 -04:00
Nick Mathewson
39ea0518ee
guardmgr: Allow guards to be constructed from any ChanTarget.
2022-11-02 07:59:56 -04:00
Nick Mathewson
1cb6ea1e77
guardmgr: Include PtTarget in guards.
...
Use a vector, since we may (someday) want to allow a Guard to have
multiple PtTargets.
2022-11-02 07:59:56 -04:00
Ian Jackson
0489d2d4be
Merge branch 'notify' into 'main'
...
refactor config reload triggering
Closes #562
See merge request tpo/core/arti!819
2022-11-01 13:31:17 +00:00
trinity-1686a
c487de6c46
debounce reload cfg events
2022-11-01 13:42:05 +01:00
Ian Jackson
0a60e9e7cc
Merge branch 'remove-deps' into 'main'
...
remove unused dependancies
See merge request tpo/core/arti!817
2022-11-01 11:07:03 +00:00
trinity-1686a
d29f38603d
set all crate edition to 2021
2022-11-01 00:17:33 +01:00
trinity-1686a
ce886e209f
rename unused field
2022-10-30 12:36:13 +01:00
trinity-1686a
5cf2933d33
update some strings
2022-10-30 12:31:07 +01:00
trinity-1686a
5abddfb579
use iife so we can try! instead of custom error handling
2022-10-30 12:31:07 +01:00
trinity-1686a
66c08c967e
refactor so events always indicate reload
2022-10-30 12:31:07 +01:00
trinity-1686a
749746a609
depends less on notify types
2022-10-30 12:31:07 +01:00
trinity-1686a
e6e064ac8a
remove unused dependancies
2022-10-29 13:29:55 +02:00
Nick Mathewson
a962683222
Merge branch 'upgrade_20221028' into 'main'
...
Upgrade and update dependencies
See merge request tpo/core/arti!816
2022-10-28 19:22:26 +00:00
Nick Mathewson
0c7cdae8f9
Upgrade dependencies in preparation for upcoming release(s)
2022-10-28 14:51:01 -04:00
Nick Mathewson
0b167f1b1c
update to latest arti-corpora
2022-10-28 09:30:16 -04:00
Nick Mathewson
29c46d08b5
Merge branch 'guards_as_bridges_part2' into 'main'
...
Use ByRelayIds to hold guards in GuardSet
See merge request tpo/core/arti!808
2022-10-27 21:09:47 +00:00
Nick Mathewson
557a07677e
guardmgr: Rename and clarify of non-persistent-state copy fns
...
These will need a bigger overhaul: see #612 and #611 .
2022-10-27 16:40:35 -04:00
Ian Jackson
4f171acaf7
Clarify fix_consistency
2022-10-27 16:40:35 -04:00
Ian Jackson
7180079112
Clarify what it means to be "an identity" for a primary guard.
2022-10-27 16:40:35 -04:00
Ian Jackson
15d464a929
tor-guardmgr: Add big doc comment about guard id handling
2022-10-27 16:40:35 -04:00
Ian Jackson
fdbd213a6d
Merge branch 'bridge-api-yaks' into 'main'
...
Misc minor changes to BridgeDescProvider APIs
See merge request tpo/core/arti!812
2022-10-27 15:37:17 +00:00
Ian Jackson
4a59d384b6
tor-dirmgr: impl Default for FlagPublisher
2022-10-27 15:57:57 +01:00
Ian Jackson
94325cd456
tor-dirmgr: impl FlagEvent for BridgeDescEvent
2022-10-27 15:57:57 +01:00
Ian Jackson
26a7aa9aa6
BridgeDescProvider: Make BridgeDescEvent repr(u16) and derive traits
...
This will enable us to impl FlagEvent for it.
2022-10-27 15:57:54 +01:00
Ian Jackson
a56efbfdf0
impl Hash for BridgeConfig and various PT information
...
The bridge descriptor manager wants to index data structures by the
BridgeConfig.
2022-10-27 15:57:54 +01:00
Ian Jackson
a89daba1c8
tor-guardmgr: bridges: export BridgeDescError at toplevel
2022-10-27 15:57:54 +01:00
eta
84a2624401
Merge branch 'fuzz_ptmgr_ipc' into 'main'
...
ptmgr: Add a fuzzer for ptmessage.
See merge request tpo/core/arti!814
2022-10-27 14:51:35 +00:00
eta
b3d8f3b5ee
Merge branch 'simpler_quote_skipping' into 'main'
...
ptmgr::ipc: Try an alternate approach to initial quotes.
See merge request tpo/core/arti!813
2022-10-27 14:50:56 +00:00