aboutsummaryrefslogtreecommitdiff
path: root/crates/arti
Commit message (Collapse)AuthorAgeFilesLines
...
* | | arti: Test hss onion-name behavior when the hsid is missing.Gabriela Moldovan2024-09-172-0/+17
|/ /
* | arti: Move proxy subcommand to a separate module.Gabriela Moldovan2024-09-122-41/+42
| | | | | | | | | | | | | | | | No functional changes, this is just code motion. This helps organize the code in `arti/src/lib.rs` a bit. It now only contains the argument parsing and various other setup, and all the subcommands are contained in separate modules.
* | arti: Move arti::run to subcommands::proxy.Gabriela Moldovan2024-09-122-156/+172
| | | | | | | | No functional changes, this is just code motion.
* | arti: Add a new module for the proxy subcommand.Gabriela Moldovan2024-09-122-0/+19
| | | | | | | | | | The implementation for `arti proxy` will soon be relocated to this new module.
* | Merge branch 'rpc_proxy_info_fix' into 'main'Ian Jackson2024-09-121-1/+1
|\ \ | | | | | | | | | | | | rpc: Fix argument type for rpc_session_get_rpc_proxy_info See merge request tpo/core/arti!2409
| * | rpc: Fix argument type for rpc_session_get_rpc_proxy_infoNick Mathewson2024-09-111-1/+1
| | | | | | | | | | | | | | | | | | | | | Without this, we get a panic on startup when running with RPC! (This stresses the need for an integration test for RPC; I will start writing that after the Python wrapper lands.)
* | | arti: Remove onion service anonymity setting.Gabriela Moldovan2024-09-121-7/+0
|/ / | | | | | | We don't support this yet, see #727.
* | Merge branch 'publisher-svc-status' into 'main'David Goulet2024-09-101-1/+15
|\ \ | | | | | | | | | | | | | | | | | | tor-hsservice: Improve descriptor publisher status reporting Closes #1216 and #1572 See merge request tpo/core/arti!2397
| * | tor-hsservice: Log the onion svc status.Gabriela Moldovan2024-09-091-1/+15
| |/ | | | | | | We now log the onion service status on change.
* / Fix a typo in WRONG_PROTOCOL_PAYLOAD.Pier Angelo Vendrame2024-09-101-2/+3
|/
* socksproto: Add a const for suggested buffer length.Nick Mathewson2024-09-091-2/+2
| | | | | Ticket #1509 will probably get rid of this constant, but for now we may as well put it in one place.
* rpc: More specificity surrounding SOCKS-rpc integrationNick Mathewson2024-09-091-2/+25
|
* Suggestion about describing non-RPC behavior of SOCKS protocol from @diziet.Nick Mathewson2024-09-091-1/+3
|
* arti/rpclib: Tweak proxy_info format.Nick Mathewson2024-09-092-2/+4
| | | | | | | Renamed address to tcp_address, and made it optional, so that later we can have a unix_path, etc. On deser side, add support for unrecognized listener types.
* arti/rpclib: Lowercase our socks5 listener variant.Nick Mathewson2024-09-091-0/+1
|
* arti: Add a comment explaining how RPC and SOCKS interactNick Mathewson2024-09-091-0/+181
| | | | | | | | | This belongs in a spec, but adding things to a spec is slow and fraught. Instead we'll put it here for now and move it later. There are some XXXXs about "finalizing" the design that we need to resolve before we can merge !2373 and implement stream creation in `arti-rpc-client-core`.
* arti: add and document get_rpc_proxy_info method.Nick Mathewson2024-09-091-2/+38
| | | | | | | | Currently this behaves the same as get_proxy_info, but this may change in the future, if we introduce RPC-unsuitable proxy ports. (Also rename the get_proxy_info method to avoid x_ prefix.)
* arti: Temporarily disable a flaky test.Ian Jackson2024-09-051-0/+1
| | | | | | | | This effectively reverts 71e3d52f5aeb34ca7bca80053079a8c7505b99ac, which was itself a revert of disabling this test the first time. Sadly it still doesn't seem to be reliable. We have agreed on IRC to disable it for now.
* Merge branch 'slow-test' into 'main'Ian Jackson2024-09-051-2/+15
|\ | | | | | | | | | | | | arti: Make the config watcher debounce interval configurable. Closes #1589 See merge request tpo/core/arti!2387
| * arti: Make the config watcher debounce interval configurable (fmt).Gabriela Moldovan2024-09-041-1/+9
| |
| * arti: Make the config watcher debounce interval configurable.Gabriela Moldovan2024-09-041-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | Previously, the `reload_cfg::test::watch_multiple` test would take about 3s to run. This test modifies 3 files and waits for the corresponding `reconfigure()` events to fire. Because of the `sleep(DEBOUNCE_INTERVAL)` in `run_watcher`, it would wind up waiting for about 1s for each of them. This makes the event debouncing optional, and disables it in the tests. Closes #1589
* | Merge branch 'reload-cfg-test' into 'main'David Goulet2024-09-041-2/+4
|\ \ | |/ |/| | | | | | | | | arti: Write the test config atomically. Closes #1549 See merge request tpo/core/arti!2375
| * Revert "arti: Temporarily disable a flaky test."Gabriela Moldovan2024-08-291-1/+0
| | | | | | | | This reverts commit ececf6be2eaffc201666cd3413dc19c025be66de.
| * arti: Write the test config atomically.Gabriela Moldovan2024-08-291-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | The flakiness from the `watch_single_file` test was caused by the race between the config write, and the fake SIGHUP "signal" sent on `sighup_tx`: sometimes, the sighup would get handled between creating the config file and writing its contents. In those cases, the config received in `TestModule::reconfigure` would be `Default::default()`, which caused an assertion to fail (because the test is expecting to receive the `ArtiConfig` it wrote to disk). Closes #1549
* | Provide a MemoryQuotaTracker in TorClientIan Jackson2024-09-041-1/+0
| | | | | | | | Nothing uses this yet.
* | arti: Proper testing of the memory limit config parsingIan Jackson2024-09-042-2/+57
| | | | | | | | | | | | Including testing that uncommenting the example generates a config with tracking enabled, and that the example low_water is the default value for the example max.
* | arti cfg tests: Provide resolve_return_resultsIan Jackson2024-09-041-0/+6
| |
* | arti cfg tests: strip_prefix: Leave section markers unchangedIan Jackson2024-09-041-1/+6
| |
* | arti cfg tests: strip_prefix: Document error behaviourIan Jackson2024-09-041-1/+3
| |
* | Look for memquota configuration in the TorClient configurationIan Jackson2024-09-042-1/+39
| | | | | | | | Tests are not entirely trivial and will come in a moment.
* | Add memquota cargo features to arti and arti-clientIan Jackson2024-09-041-0/+2
| | | | | | | | | | | | * In arti, memquota simply turns on in memquota arti-client * In arti-client, add an (unconditional) dependency on tor-memquota, and have the memquota feature turn on the feature in tor-memquota.
* | arti/Cargo.toml: Sort the experimental features listIan Jackson2024-09-041-3/+3
| |
* | Bump arti crate to 1.2.7Gabriela Moldovan2024-09-031-1/+1
| | | | | | | | | | | | | | | | Done using: ``` cargo set-version --bump patch -p arti ```
* | Bump all the unstable tor- and arti- crates to 0.22.0.Gabriela Moldovan2024-09-031-13/+13
| | | | | | | | | | | | | | | | | | | | Done using: ``` for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do cargo set-version -p $crate 0.22.0 done ```
* | Fix formatting issues introduced by fixup-features.Gabriela Moldovan2024-09-031-2/+11
| |
* | arti: Remove the XXXXs added by fixup-features.Gabriela Moldovan2024-09-031-1/+0
| | | | | | | | The `restricted-discovery` feature is reachable from `experimental`.
* | Run fixup-features in preparation for release.Gabriela Moldovan2024-09-031-2/+4
| |
* | Fix typosDimitris Apostolou2024-09-032-2/+2
|/
* arti: Set the COLUMNS env var in the CLI tests.Gabriela Moldovan2024-08-283-11/+14
| | | | | | | | This sets `COLUMNS` to a large value to prevent line wrapping. Prompted by https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2370#note_3067346 Closes #1574
* arti: Elide some text in the expected hsc test output.Gabriela Moldovan2024-08-281-2/+1
| | | | | | These file paths occupy more than 2 lines on some platforms. See also the motivation behind 2b8a7a196b3ea5cd8350dd77f5e5120fed8521e0
* arti: Implement the hsc subcommand using an inert tor client.Gabriela Moldovan2024-08-283-8/+4
| | | | | | | | | This allows us to reenable the `arti hsc` tests, which were previously disabled due to flakiness (see #1496). The `help` test bit rotted a bit, so I had to tweak its expected output. Closes #1496
* extract tor_async_utils::oneshot into ::oneshot-fused-workaroundJim Newsome2024-08-281-2/+2
| | | | | | | | | | | | | | Having this in the `tor-async-utils` crate prevents us from doing both of the following without introducing a circular dependency: * using it in `tor-rtmock` (which we currently do, particularly in tests). * using `tor-rtmock` to test things in `tor-async-utils`. We don't do this yet, but it is generally sensible to do so. In particular we want to move the `stream_peak` module there, which is currently tested with `tor-rtmock`. Moving this into its own crate avoids this circular dependency.
* Merge branch 'expose-proxy-setting' into 'main'Nick Mathewson2024-08-286-13/+308
|\ | | | | | | | | | | | | RPC: Add experimental method to list SOCKS proxy addresses. Closes #1523 See merge request tpo/core/arti!2359
| * rpc: Use MockRuntime for set_proxy_info test.Nick Mathewson2024-08-282-2/+3
| |
| * rpc: Add a test for setting proxy info.Nick Mathewson2024-08-282-0/+43
| |
| * rpc: Rename E::SenderDroppedNick Mathewson2024-08-281-5/+6
| |
| * rpc: Try another incantation for watching for ProxyInfo.Nick Mathewson2024-08-281-13/+7
| |
| * rpc: Add another layer of indirection on proxyinfoNick Mathewson2024-08-282-3/+12
| |
| * rpc: Try using postage::watch to initialize ProxyInfo.Nick Mathewson2024-08-286-35/+82
| | | | | | | | | | (This is a bit trickier than I would like, but it ensures that we never return a "not initialized yet" code.)
| * Re-wrap a Cargo.toml.Nick Mathewson2024-08-281-1/+5
| |