| Commit message (Collapse) | Author | Age | Files | Lines |
| |\
| |
| |
| |
| | |
clippy: deny `mod_module_files`
See merge request tpo/core/arti!2689
|
| | |
| |
| |
| |
| |
| | |
Denies 'mod.rs' files for consistency.
https://rust-lang.github.io/rust-clippy/master/index.html#mod_module_files
|
| |/ |
|
| |
|
|
|
| |
This time, we make explicit that it is a _base_ resolver,
and that it is client-only.
|
| |
|
|
|
|
|
|
| |
In 1.83, this warning triggers on many of our crates.
We're thinking of fixing them all, but for now,
we're going to disable the warning.
This is part of #1765.
|
| | |
|
| | |
|
| |
|
|
|
|
| |
Rather than using `arti_client::config::path_resolver()`, third-party
code can get the path resolver using `TorClientConfig`s
`AsRef<CfgPathResolver>` impl instead.
|
| | |
|
| |
|
|
| |
Also updated to use the `PATH_RESOLVER` resolver.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a big change across multiple crates since there isn't a good way
to break it up.
This changes the signature of `CfgPath::path` to:
```
pub fn path(&self, path_resolver: &CfgPathResolver) -> Result<PathBuf, CfgPathError> {
```
Making this change means that our global `CfgPathResolver` needs to be
stored in the 'arti-client' library instead of `tor-config-path`, and
must be passed through to anything that calls `path` to expand the
variables.
|
| | |
|
| | |
|
| | |
|
| |\
| |
| |
| |
| |
| |
| | |
tor-hscrypto: Abolish the HasKind impl of HsIdParseError.
Closes #1483
See merge request tpo/core/arti!2607
|
| | |
| |
| |
| |
| | |
We only ever return `BadOnionAddress` is we are asked to connect to a
.onion address that doesn't parse.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Also changes the `ErrorKind` of `BadOnionAddress` to
`ForbbiddenStreamTarget`.
See context in
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2246#note_3045683
Closes #1483
|
| |/
|
|
|
| |
Also updated other packages to get `CfgPath` directly from
`tor-config-path' instead of 'tor-config'.
|
| |
|
|
|
|
|
| |
Now
cargo check --workspace --no-default-features --all-targets
cargo build -p arti --no-default-features --features=memquota,tokio,native-tls
are both clean.
|
| |\
| |
| |
| |
| |
| |
| | |
rpc spec: Start to document method naming convention
Closes #1678
See merge request tpo/core/arti!2539
|
| | |
| |
| |
| | |
Closes #1678.
|
| |/
|
|
| |
Fixes a TODO.
|
| |
|
|
|
| |
This broke because `tor_keymgr::config::arti` was moved to
`tor_keymgr::config`.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
This deduplicates the keymgr building logic in preparation for
supporting C Tor keystores (building the keymgr in a central place makes
things a bit easier, because regardless of the `kind` of the primary
keystore, we will need to extend the `KeyMgrBuilder` with the configured
secondary `ctor` keystores, if any).
|
| |
|
|
|
|
|
|
| |
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`
|
| |\
| |
| |
| |
| |
| |
| | |
Default allow_onion_addrs to true.
Closes #1402
See merge request tpo/core/arti!2506
|
| | |
| |
| |
| |
| |
| |
| | |
This was disabled due to lack of vanguard support. Now that we support
vanguards, we should enable this by default.
Fixes: #1402
|
| |/
|
|
|
|
|
|
|
|
| |
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
|
| |\
| |
| |
| |
| | |
Implement memory quota tracking
See merge request tpo/core/arti!2493
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
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.
|
| | |
| |
| |
| |
| |
| | |
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.
|
| |\ \
| | |
| | |
| | |
| | |
| | |
| | | |
arti-client: Clarify the launch_onion_service_with_hsid() docs.
Closes #1626
See merge request tpo/core/arti!2494
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | | |
This updates the docs to mention that the specified key may get
actually persisted to disk.
Closes #1626
|
| |\ \ \
| |_|/
|/| |
| | |
| | |
| | |
| | | |
Use the new "restricted discovery" terminology throughout
Closes #1476
See merge request tpo/core/arti!2495
|
| | |/
| |
| |
| | |
Part of #1476
|
| | | |
|
| |/
|
|
|
|
| |
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`.
|
| |\
| |
| |
| |
| | |
Miscellaneous cleanups, mostly in tor-memquota
See merge request tpo/core/arti!2461
|
| | |
| |
| |
| |
| | |
It turns out that my fingers want to treat "memquota" as a word. We
have this in tor_memquota etc. too.
|
| |\ \
| |/
|/|
| |
| | |
Upgrade dependencies in preparation for next week's releases.
See merge request tpo/core/arti!2450
|
| | |
| |
| |
| |
| |
| | |
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.
|
| |\ \
| |/
|/|
| |
| |
| |
| | |
rpc: Rename SingletonId to SingleIdResponse
Closes #1585
See merge request tpo/core/arti!2448
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
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.
|
| |/
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
| |
The keystore settings only configure the *primary* keystore, so they
should be under `keystore.primary`.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| | |
|