Commit Graph

5633 Commits

Author SHA1 Message Date
Ian Jackson e068c5c2bc Merge branch 'ptmgr-errs' into 'main'
ptmgr: error fixes

See merge request tpo/core/arti!906
2022-11-30 15:58:26 +00:00
Ian Jackson e6d721c497 arti: transports parsing: Record this as a ticket 2022-11-30 15:56:16 +00:00
Ian Jackson 598f4e2e28 arti: BridgesConfig is evidently not too high up
Since apparently it was possible to write all the other code without
moving it.
2022-11-30 15:51:10 +00:00
Ian Jackson e4ac39e638 bridge config: Add a TODO about a redundant clone 2022-11-30 15:49:34 +00:00
Ian Jackson 429d2c7cb7 bridge config: Rename accessors
As per
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/904#note_2858480
2022-11-30 15:49:34 +00:00
Ian Jackson 117bee5808 bridge config: Use unreachable, not None.expect
As per
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/904#note_2858479
2022-11-30 15:49:34 +00:00
Ian Jackson bb6c98bdc1 BridgeAddr tests: dedupe slightly 2022-11-30 15:49:34 +00:00
Ian Jackson 199a6e0754 Separate BridgeAddr and PtTargetAddr
As per
  https://gitlab.torproject.org/tpo/core/arti/-/issues/668#note_2858220

This commit is difficult to split up.

The innards of BridgeAddr and PtTargetAddr are still a bit entangled.
2022-11-30 15:49:34 +00:00
Ian Jackson a74ee097f5 arti: pt mgr spawns the task itself in new 2022-11-30 15:48:31 +00:00
Ian Jackson 455295457f Merge branch 'redaction_fix' into 'main'
Fix a logic error in Redacted.

Closes #671

See merge request tpo/core/arti!905
2022-11-30 15:39:41 +00:00
Ian Jackson d747ec877b changelog: Add status of bridge/PT features 2022-11-30 15:33:20 +00:00
Ian Jackson f1bbe036d3 changelog: Add more blurb 2022-11-30 15:32:09 +00:00
Nick Mathewson d853fdb5cb ptmgr: Do not construct an empty select_all future.
Closes #670.

Closes #672.
2022-11-30 10:22:09 -05:00
Ian Jackson 1e63a89ce8 ptmgr: change error UnconfiguredTransportDueToConcurrentReconfiguration
Rename it from UnconfiguredTransport.  Change descriptions, kind, and
retry.  Add a TODO.

As per
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/901#note_2858455
2022-11-30 15:21:49 +00:00
Ian Jackson d705454313 ptmgr: Clarify E::NotAFile
As per
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/901#note_2858454
2022-11-30 15:21:39 +00:00
Ian Jackson f19d8e0397 ptmgr: Fix kind for E::StatedirCreateFailed
As per
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/901#note_2858456
2022-11-30 15:21:39 +00:00
Nick Mathewson 80d9248b50 Merge branch 'merge_ptreactor' into 'main'
Merge PtReactor, resolve a few of my comments.

See merge request tpo/core/arti!903
2022-11-30 15:21:13 +00:00
Ian Jackson 8db7c7d929 Merge branch 'early_ownership' into 'main'
arti-client: Try to take ownership of state earlier.

See merge request tpo/core/arti!902
2022-11-30 14:38:17 +00:00
Nick Mathewson f0084e3fd4 Fix a logic error in Redacted.
Previously it was redacting exactly when safelogging was _disabled_,
which obviously isn't correct.

Fixes #671. Regression test included.
2022-11-30 09:07:33 -05:00
Nick Mathewson dacb3eafda ptmgr: report an error if PT transports don't match requested.
(I think this may be impossible now, since we check in ipc.rs, but
IMO it's best to check.)
2022-11-29 20:01:19 -05:00
Nick Mathewson 5f0f5f81b1 arti-client: Try to take ownership of state earlier.
There's no harm in doing this, since we'll try to take ownership of
the state soon as soon as we use it: We just want to try early, so
that we'll get it before we decide that we're using bridges.

Fixes bug #669; bug introduced by !889.
2022-11-29 19:58:42 -05:00
Nick Mathewson fdc49b1fed Register transport in pt reactor even if it has no pending requests 2022-11-29 19:35:38 -05:00
Nick Mathewson 9765fdc2e6 ptmgr: Use anonymize_home when displaying paths in errors 2022-11-29 19:30:50 -05:00
Nick Mathewson f6311c83f7 ptmgr: Use PluggableTransport::identity in logs.
This lets us avoid logging the user's path.
2022-11-29 19:20:44 -05:00
Nick Mathewson bb0749cd42 Centralize the "find an identifier for the pt name" logic in one place. 2022-11-29 19:13:32 -05:00
Nick Mathewson 21e7e52ad5 Merge remote-tracking branch 'eta/ptreactor-v1' into merge_ptreactor
Resolved several conflicts while doing so; mostly with !893 and
!895.
2022-11-29 18:55:49 -05:00
eta 9b4fc50625 tor-ptmgr: add PtReactor
This fleshes out the PtReactor that was previously a stub, making it
actually do reactor-ey things. Note that this is entirely untested, and
might not work at all. Hopefully it does, though.
2022-11-29 20:13:32 +00:00
Nick Mathewson 30140cb07b Check off items in README.md, remove inaccurate parentheticals. 2022-11-29 14:51:41 -05:00
Nick Mathewson 7ef9dde99c Merge branch 'todos-chanmgr' into 'main'
chanmgr: resolve several remaining "TODO pt-client" issues

See merge request tpo/core/arti!897
2022-11-29 19:31:48 +00:00
Nick Mathewson dc5551114c Merge branch 'list-builder-lint' into 'main'
tor-basic-utils: list_builder: Use standard test lint block

See merge request tpo/core/arti!900
2022-11-29 19:25:07 +00:00
Nick Mathewson 88c9a676b1 Merge branch 'changelog' 2022-11-29 14:21:06 -05:00
Nick Mathewson ffeb427bef Start a changelog for 1.1.0. 2022-11-29 14:20:32 -05:00
Ian Jackson f3c8b0433b tor-basic-utils: list_builder: Use standard test lint block
This gets rid of a spurious warning on nightly about the use of dbg!
2022-11-29 18:41:56 +00:00
Nick Mathewson bdddb78828 Merge branch 'more-linkspec-tests' into 'main'
Add tests for a bunch of code in tor-linkspec

See merge request tpo/core/arti!867
2022-11-29 18:41:54 +00:00
Nick Mathewson 8cc09c2728 chanmgr: Distinguish failure to connect to proxy from other IO failures 2022-11-29 13:41:35 -05:00
Ian Jackson c3bdb30025 Merge branch 'ptmgr-optional-dep-test' into 'main'
MultilineListBuilder etc.: add serde tests

See merge request tpo/core/arti!899
2022-11-29 18:37:43 +00:00
Ian Jackson b36a23cfd3 Merge branch 'ptmgr-optional-dep' into 'main'
Support building without pluggable transports

Closes #649

See merge request tpo/core/arti!898
2022-11-29 18:26:30 +00:00
Ian Jackson 303fafe81b Merge branch 'll-todo-fixes' into 'main'
Fix and resolve TODO pt-client comments in guardmgr, linkspec.

See merge request tpo/core/arti!896
2022-11-29 18:14:25 +00:00
Ian Jackson cdc1e574f9 tor-config MultilineListBuilder: Test deserialisation 2022-11-29 17:53:04 +00:00
Ian Jackson 255f3b6bf6 tor-config MultilineListBuilder: Print line number starting at 1, not 0 2022-11-29 17:53:04 +00:00
Ian Jackson ef07c2e99d tor-config list_builder tests: Move Outer up a level
We're going to reuse this.
2022-11-29 17:53:04 +00:00
Ian Jackson b6a4f2388d CI: test that we can compile, and test cfg, with/without bridges/PTs 2022-11-29 17:52:12 +00:00
Nick Mathewson 3ccf605449 Merge branch 'ptmgr-cleanup-redux' into 'main'
More post-merge cleanups for ptmgr

See merge request tpo/core/arti!895
2022-11-29 17:45:41 +00:00
Ian Jackson 211a832f6d Clarify internal error. 2022-11-29 17:22:16 +00:00
Ian Jackson 143b331ef7 arti-client: Make ptmgr actually optional 2022-11-29 16:32:14 +00:00
Ian Jackson 1bd606ab5c guardmgr: Conditionalise DisplayRule::Redacted
This is unused in bridgeless configs.  Fixes a compiler warning.
2022-11-29 16:32:14 +00:00
Ian Jackson c92dcb5f50 arti, arti-client: Conditionalise various things on pt-client 2022-11-29 16:32:14 +00:00
Ian Jackson d05d383fa5 arti cfg tests: Add some more debug output 2022-11-29 16:32:14 +00:00
Ian Jackson 71e81bf7b4 MultilineListBuilder: Use a manual implementation of Deserialize
The error message from `#[serde(untagged)]` would otherwise start to
appear when we try to deserialise unsupported PT configurations, when
compiled with bridge but not PT support.
2022-11-29 16:32:14 +00:00
Nick Mathewson c6aa587dc8 chanmgr: remove a now-stale TODO. 2022-11-29 11:15:36 -05:00