summaryrefslogtreecommitdiff
path: root/crates/arti-client
Commit message (Collapse)AuthorAgeFilesLines
...
* tor-keymgr: Move config/arti.rs to config.rsGabriela Moldovan2024-10-082-2/+2
| | | | | | | | The config will soon contain secondary C Tor keystore configuration too, so the `arti` namespacing is about to stop making sense. I recommend reviewing this commit using `git diff --color-moved=zebra --ignore-space-change`
* Merge branch 'allow-onion-addrs-default-true' into 'main'gabi-2502024-10-072-3/+3
|\ | | | | | | | | | | | | Default allow_onion_addrs to true. Closes #1402 See merge request tpo/core/arti!2506
| * Default allow_onion_addrs to true.Wesley Aptekar-Cassels2024-10-072-3/+3
| | | | | | | | | | | | | | This was disabled due to lack of vanguard support. Now that we support vanguards, we should enable this by default. Fixes: #1402
* | arti-client: Fix restricted-discovery dependencies.Wesley Aptekar-Cassels2024-10-071-1/+1
| | | | | | | | | | | | | | | | restricted-discovery should require tor-hsservice to be enabled. This previously caused this command to fail: cargo check -p arti-client --features restricted-discovery,vanguards
* | arti-client: Fix incorrect feature gate for onion-service-client.Wesley Aptekar-Cassels2024-10-071-4/+3
|/ | | | | | | | | | Currently, arti-client doesn't compile with just the features experimental-api and onion-service-client enabled, because it incorrectly depends on tor-hsservice. This fixes that by gating the use statement behind the correct feature. Fixes: #1638
* Merge branch 'mq' into 'main'Ian Jackson2024-10-072-0/+7
|\ | | | | | | | | Implement memory quota tracking See merge request tpo/core/arti!2493
| * memquota: Add a toplevel account in tor-chanmgrIan Jackson2024-10-031-0/+2
| | | | | | | | | | | | | | | | | | Plumb through a top-level account. This doesn't have any channel-specific, circuit-specific or stream-specific accounts yet. tor-circmgr's and tor-hsclient's *tests* need fake account. In arti-relay, use a dummy account for now.
| * arti-client: Provide another variant for memquota errorsIan Jackson2024-10-031-0/+5
| | | | | | | | | | | | During startup we'll call a few not-just-at-startup memquota methods which produce tor_memquota::Error, rather than StartupError. So we need a variant for that.
* | Merge branch 'launch-with-hsid-docs' into 'main'gabi-2502024-10-031-0/+8
|\ \ | | | | | | | | | | | | | | | | | | arti-client: Clarify the launch_onion_service_with_hsid() docs. Closes #1626 See merge request tpo/core/arti!2494
| * | arti-client: Clarify the launch_onion_service_with_hsid() docs.Gabriela Moldovan2024-10-031-0/+8
| | | | | | | | | | | | | | | | | | | | | This updates the docs to mention that the specified key may get actually persisted to disk. Closes #1626
* | | Merge branch 'rename-client-auth' into 'main'Ian Jackson2024-10-031-2/+2
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | Use the new "restricted discovery" terminology throughout Closes #1476 See merge request tpo/core/arti!2495
| * | arti-client: Use the new "restricted discovery" terminology.Gabriela Moldovan2024-10-031-2/+2
| |/ | | | | | | Part of #1476
* | CircMgr: Start writing tests.Wesley Aptekar-Cassels2024-10-031-1/+1
| |
* | Revise RPC documentation to be more informative.Nick Mathewson2024-10-022-5/+28
|/ | | | | | Previous documentation was more-or-less meant for the Arti developer only. This new documentation is intended for actual users of RPC functionality. It's meant to be extracted with `maint/rpc-doc-tool`.
* Merge branch 'misc' into 'main'Ian Jackson2024-10-011-2/+2
|\ | | | | | | | | Miscellaneous cleanups, mostly in tor-memquota See merge request tpo/core/arti!2461
| * arti-client: Change the case of ErrorDetail::MemquotaSetup from MemQuotaSetupIan Jackson2024-09-261-2/+2
| | | | | | | | | | It turns out that my fingers want to treat "memquota" as a word. We have this in tor_memquota etc. too.
* | Remove semver.md files from 1.2.8Nick Mathewson2024-09-301-1/+0
| |
* | Bump arti- and tor- crates to 0.23.0Nick Mathewson2024-09-301-26/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Per our policy, every one of these gets a minor bump. Generated with: ``` for crate in $(./maint/list_crates | grep '^\(tor\|arti\)-' ); do cargo set-version --bump minor -p $crate; done ``` (Note the use of `-` at the end end of the grep pattern to prevent matching the `arti` crate.)
* | Minor bumps on non-tor/arti cratesNick Mathewson2024-09-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These crates are not in the tor/arti namespace, but we have given them MSRV bumps: ``` oneshot-fused-workaround slotmap-careful fslock-guard hashx equix caret fs-mistrust safelog test-temp-dir retry-error ``` We are counting this as a breaking change. Since all of these crates are at 0.x.x, we have indicated the breaking change with a minor version bump. This commit was generated with the following script: ``` BUMPS=" oneshot-fused-workaround slotmap-careful fslock-guard hashx equix caret fs-mistrust safelog test-temp-dir retry-error " for crate in $BUMPS; do cargo set-version --bump minor -p $crate; done ```
* | Merge branch 'msrv-1.77-and-rusqlite-update' into 'main'David Goulet2024-09-261-1/+1
|\ \ | | | | | | | | | | | | Upgrade MSRV to 1.77 , and rusqlite to 0.32.1 See merge request tpo/core/arti!2451
| * | Upgrade MSRV to 1.77Nick Mathewson2024-09-251-1/+1
| |/ | | | | | | This will allow us to upgrade to the latest version of rusqlite.
* | Merge branch 'upgrades-20240925' into 'main'Nick Mathewson2024-09-262-10/+9
|\ \ | |/ |/| | | | | Upgrade dependencies in preparation for next week's releases. See merge request tpo/core/arti!2450
| * Upgrade to derive_more version 1.0.0Nick Mathewson2024-09-252-10/+9
| | | | | | | | | | | | The `derive_more` crate broke backward compatibility with this version, so this change involved quite a few manual fixups. With luck, they'll keep compatibility for some while in the future.
* | Merge branch 'rename_singleton_id' into 'main'Jim Newsome2024-09-251-3/+3
|\ \ | | | | | | | | | | | | | | | | | | rpc: Rename SingletonId to SingleIdResponse Closes #1585 See merge request tpo/core/arti!2448
| * | rpc: Rename SingletonId to SingleIdResponseNick Mathewson2024-09-241-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Calling it "singleton" might have suggested that it was using the [singleton pattern](https://en.wikipedia.org/wiki/Singleton_pattern), which it isn't. (Renaming done with rust-analyzer and double-checked with `git grep`.) Closes #1585.
* | | Run fixup-features in preparation for upcoming release.Nick Mathewson2024-09-251-1/+1
| |/ |/|
* | Merge branch 'hscircpool-builder-generic' into 'main'gabi-2502024-09-241-9/+11
|\ \ | | | | | | | | | | | | Make `HsCircPool` generic over circuit builder type See merge request tpo/core/arti!2420
| * | CircMgr: Make CircMgr and HsCircPool generic over builder type.Wesley Aptekar-Cassels2024-09-241-9/+11
| |/ | | | | | | | | | | | | | | | | | | This will allow for testing, as the CircuitBuilder can be replaced with a mocked version. This did require moving some of what was in the CircuitBuilder impl into the AbstractCircuitBuilder type, since Drop implementations can't be specialized, but that's fine, as we'll probably be doing more of that in the future anyways.
* | Merge branch 'abstract-socket-v2' into 'main'Nick Mathewson2024-09-242-47/+14
|\ \ | |/ |/| | | | | | | | | rtcompat: Second attempt at AF_UNIX support Closes #1152 See merge request tpo/core/arti!2437
| * Documentation updates for "NetStreamProvider" renameNick Mathewson2024-09-242-3/+3
| | | | | | | | | | | | Stop referring to TCP streams in its documentation; update other documentation to refer to NetStreamProvider rather than TcpProvider.
| * rtcompat: Rename TcpProvider to NetStreamProvider.Nick Mathewson2024-09-241-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (And similarly rename TcpListener to NetStreamListener, along with their TcpStream/TcpListener associated types.) These types are about to become generic over addresses, and therefore shouldn't be named after TCP. Renaming was done mostly with Rust Analyzer, except for some macros that needed to be hand-edited. (I'll revise the comments in the next commit; this one is all about renaming.)
| * rtcompat: Remove accept() from TcpListenerNick Mathewson2024-09-241-33/+0
| | | | | | | | | | | | | | | | | | | | It's redundant with the incoming() method (which turns the TcpListener into a Stream of connections), and nothing actually used it outside of tests. Removing this method allows us to simplify our TcpListener code a good deal, as can be seen by some of the implementations we removed from our example and testing code.
| * rtcompat: Add an extension trait for building modified RuntimesNick Mathewson2024-09-241-2/+2
| | | | | | | | | | | | | | With this extension trait, we no longer need to construct `CompoundRuntime` directly outside of tor-rtcompat. This in turn will make it a little less painful when we have to add more generics to CompoundRuntime.
* | tor-keymgr: Move keystore config under keystore.primary.Gabriela Moldovan2024-09-231-1/+1
| | | | | | | | | | The keystore settings only configure the *primary* keystore, so they should be under `keystore.primary`.
* | arti: Reinstate the keystore.enabled option.Gabriela Moldovan2024-09-231-3/+3
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a follow-up from !2394 I want to keep the `keystore.enabled` option, because I'm planning on extending `ArtiKeystoreConfig` to support configuring secondary keystores too (currently, the only supported setting is `keystore.kind`, which configures the primary keystore). `keystore.enabled` will disable keystore use altogether (i.e. both primary and secondary). Currently, we only support configuring the "primary" (previously known as "default") keystore, which can be either "native" (the on-disk Arti keystore), or "ephemeral" (an in-memory keystore). To implement #858, we will need to support configuring additional keystores too, so we will need to move to a config of the form ```toml [storage.keystore] # Whether the keystore is enabled. #enabled = "auto" # Configure the primary keystore. [storage.keystore.primary] # The type of primary keystore to use kind = "auto" | "native" | "ephemeral" # Optionally configure C Tor keystores for arti to use. # # Note: The keystores listed here are read-only (keys are only # ever written to the primary keystore, configured in # `storage.keystore.primary`). [[storage.keystore.ctor]] # If the `kind` is `service`, this should be set to the `HiddenServiceDirectory` # of your hidden service. Arti will read `HiddenServiceDirectory/hostname` # and `HiddenServiceDirectory/private_key`. (Note: if your service is running # in restricted discovery mode, you must set the # `[[onion_services."<the nickname of your svc>".restricted_discovery.key_dirs]]` # to `HiddenServiceDirectory/client_keys` # # If the `kind` is `client`, this should be set to `ClientOnionAuthDir` of # your client. If Arti is configured to run as a client (i.e. if it runs in SOCKS # proxy mode), it will read the client restricted discovery keys from this path. path = "/foo/bar" # The type of keystore `path` should be interpreted as kind = "client" | "service" ``` This moves the current keystore settings to `storage.keystore.primary` in preparation for that change.
* arti-client: Update docs to reflect KeystoreSelector renaming.Gabriela Moldovan2024-09-231-3/+3
|
* tor-keymgr: Rename the primary keystore for clarity.Gabriela Moldovan2024-09-231-6/+6
| | | | | | | | | | Previously, arti's primary keystore was referred to as its "default" keystore. However, "default" is inaccurate here: there is no way to meaningfully override this "default" (the "default" store acts as the main keystore). Throughout the codebase, we query all keystores for keys (including the secondary ones), but only ever write to the default/primary keystore. This is OK for now, because it enables us to have one mutable keystore, and multiple secondary, read-only stores.
* arti-client: added support for constructing ArtiEphemeralKeystore to ↵Morgan2024-09-201-22/+37
| | | | InertTorClient::create_keymgr()
* tor-keymgr: renamed ArtiNativeKeystoreConfig to ArtiKeystoreConfigMorgan2024-09-202-4/+5
|
* arti-client: expose key-mgr/ephemeral-keystore feature in arti-clientMorgan2024-09-201-0/+3
|
* arti-client: Add APIs for rotating service discovery keys.Gabriela Moldovan2024-09-191-0/+80
|
* Merge branch 'msrv-1.75' into 'main'Nick Mathewson2024-09-171-1/+1
|\ | | | | | | | | Bump MSRV from 1.70 to 1.75. See merge request tpo/core/arti!2421
| * Bump MSRV from 1.70 to 1.75.Wesley Aptekar-Cassels2024-09-161-1/+1
| |
* | arti-client: add experimental launch_onion_service_with_hsid() method which ↵Morgan2024-09-151-1/+45
|/ | | | HsIdKeypair
* arti-client: Convert a note to a comment.Gabriela Moldovan2024-09-121-1/+1
| | | | This was supposed to be a comment, not part of the docs.
* arti-client: Remove duplicated documentation.Gabriela Moldovan2024-09-121-42/+4
| | | | | | `TorClient` and `InertTorClient` have a number of identical state-management functions. This makes the `InertTorClient` link to the `TorClient` docs instead of duplicating them.
* arti-client: implemented insert_service_discovery_key and ↵Morgan2024-09-101-1/+168
| | | | remove_service_discovery_key methods
* Merge branch 'relay-err' into 'main'David Goulet2024-09-091-1/+1
|\ | | | | | | | | arti-relay: add and use `Error`/`ErrorDetail` See merge request tpo/core/arti!2392
| * arti-client: minor documentation grammar fixSteven Engler2024-09-051-1/+1
| |
* | Add a TODO RPC call about revising/moving documentationNick Mathewson2024-09-091-0/+6
| |