| Commit message (Collapse) | Author | Age | Files | Lines | ||
|---|---|---|---|---|---|---|
| ... | ||||||
| * | tor-keymgr: Use tor-keys crate and remove dead code | David Goulet | 2024-09-04 | 1 | -1/+2 | |
| | | | | | | | | | | | | Everything copied in the previous commits to tor-keys is now removed and tor-keys crate is used accross the code. Minor changes to tor-keys to accomodate this change. Part of #1137 Signed-off-by: David Goulet <[email protected]> | |||||
| * | extract tor_async_utils::oneshot into ::oneshot-fused-workaround | Jim Newsome | 2024-08-28 | 3 | -3/+4 | |
| | | | | | | | | | | | | | | | 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. | |||||
| * | tor-hsservice: Recreate the file watcher on every key_dir change event. | Gabriela Moldovan | 2024-08-27 | 1 | -0/+3 | |
| | | | | | | | | This ensures that if a directory used as a `key_dir` is moved (e.g. renamed), and then moved back to its original location (the one specified in `key_dirs`), our watcher continues watching the `key_dirs` contents. | |||||
| * | tor-config: Rename watch_file to watch_path. | Gabriela Moldovan | 2024-08-27 | 1 | -2/+2 | |
| | | | | | `FileWatcher::watch_file` can be used with arbitrary paths. | |||||
| * | tor-hsservice: Make sure we always watch the parents of the key_dirs. | Gabriela Moldovan | 2024-08-27 | 1 | -15/+24 | |
| | | | | | | This ensures that if a `key_dir` is created after we start watching it (or if it's moved), we are still able to detect changes. | |||||
| * | tor-hsservice: Always recreate the file watcher if the config changes. | Gabriela Moldovan | 2024-08-27 | 1 | -59/+6 | |
| | | | | | | | While this means we will be recreating the watcher slightly more often than necessary, this new approach is less error-prone than what we had before. | |||||
| * | tor-hsservice: Add a TODO about rethinking publish rate-limiting. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+11 | |
| | | ||||||
| * | tor-hsservive: Document how restricted discovery live reloading works. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+48 | |
| | | ||||||
| * | tor-hsservice: Remove a TODO that is no longer relevant. | Gabriela Moldovan | 2024-08-21 | 1 | -16/+1 | |
| | | | | | This is now implemented. | |||||
| * | tor-hsservice: Add TODO about updating publisher status on error. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+1 | |
| | | | | | | This is a general issue with the publisher that will need to be addressed soon. | |||||
| * | tor-hsservice: Update the authorized_clients and watcher when the config ↵ | Gabriela Moldovan | 2024-08-21 | 1 | -1/+5 | |
| | | | | | changes. | |||||
| * | tor-hsservice: Store a FileWatcher in the publisher reactor. | Gabriela Moldovan | 2024-08-21 | 1 | -2/+137 | |
| | | | | | | This `FileWatcher` is watching the `restricted_discovery.key_dirs` directories for changes. | |||||
| * | tor-hsservice: Pass watch_configuration down to restricted discovery config. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+8 | |
| | | | | | | | We need to know if `watch_configuration` is set in the descriptor publisher reactor to know whether we should be watching the `restricted_discovery.key_dirs` directories. | |||||
| * | tor-hsservice: Derive getters for OnionServiceConfig, RestrictedDiscoveryConfig. | Gabriela Moldovan | 2024-08-21 | 2 | -7/+5 | |
| | | ||||||
| * | tor-hsservice: Schedule descriptor republication whenever the key_dirs ↵ | Gabriela Moldovan | 2024-08-21 | 1 | -1/+57 | |
| | | | | | contents change. | |||||
| * | tor-hsservice: Add helper for reading authorized_clients. | Gabriela Moldovan | 2024-08-21 | 1 | -8/+17 | |
| | | | | | | This will soon be used in the `key_dirs` change handler, which will re-read the authorized_clients list. | |||||
| * | tor-hsservice: Add channel for receiving key_dirs change events. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+11 | |
| | | ||||||
| * | tor-hsservice: Log a message whenever restricted discovery mode is toggled. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+13 | |
| | | ||||||
| * | tor-hsservice: Only republish if the config changes are relevant. | Gabriela Moldovan | 2024-08-21 | 1 | -8/+1 | |
| | | | | | | | | | | | | | Previously, the publisher would always publish a new descriptor if the config changed. Now, it only republishes if the parts of the config that changed are relevant (i.e. if they are part of `OnionServiceConfigPublisherView`). A future change will make it so that we trigger a republish task whenever the restricted discovery mode authorized clients change. This will involve looking at the contents of the configured `key_dirs`, as well as the `OnionServiceConfigPublisherView`. | |||||
| * | tor-hsservice: Make restricted_discovery updateable. | Gabriela Moldovan | 2024-08-21 | 1 | -1/+1 | |
| | | ||||||
| * | tor-hsservice: Make the reactor take a reference to the config. | Gabriela Moldovan | 2024-08-21 | 2 | -3/+3 | |
| | | | | | This resolves a clippy warning. | |||||
| * | tor-hsservice: Use OnionServiceConfigPublisherView in the publisher. | Gabriela Moldovan | 2024-08-21 | 2 | -16/+11 | |
| | | | | | | Resolves the TODO prompted by https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1603#note_2944902 | |||||
| * | tor-hsservice: Create a type for the descriptor publisher's view of the config. | Gabriela Moldovan | 2024-08-21 | 1 | -1/+49 | |
| | | | | | | Partially addresses https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1603#note_2944902 | |||||
| * | tor-hsservice: Log the client nicknames the descriptor is encrypted for. | Gabriela Moldovan | 2024-08-21 | 1 | -1/+4 | |
| | | | | | Knowing the nicknames can be useful when debugging. | |||||
| * | tor-hsservice: Log if we are about to generate a new descriptor. | Gabriela Moldovan | 2024-08-21 | 1 | -0/+1 | |
| | | ||||||
| * | Resolve unreachable_patterns warnings from nightly. | Nick Mathewson | 2024-08-13 | 1 | -16/+13 | |
| | | | | | | | | | | | | | | | Nightly rust doesn't like it when you have a `match` arm that can never be reached because of an uninhabited type. As such, we can't say stuff like: ``` let x: Option<Void> = ...; match x { Some(_) => unreachable!(), None => ... } ``` | |||||
| * | tor-hsservice: Log whether the service is running in restricted discovery mode. | Gabriela Moldovan | 2024-08-13 | 1 | -0/+12 | |
| | | ||||||
| * | tor-hsservice: Move authorized_clients out of RunningOnionService. | Gabriela Moldovan | 2024-08-13 | 3 | -31/+9 | |
| | | | | | | | We now create the authorized_clients in the publisher (we don't need the authorized_clients anywhere else, so it makes little sense to keep them in `RunningOnionService`). | |||||
| * | tor-hsservice: Remove unnecessary docsrs cfg_attr. | Gabriela Moldovan | 2024-08-07 | 1 | -1/+0 | |
| | | | | | | The module is correctly documented as "only available on crate feature restricted-discovery" without it. | |||||
| * | tor-hsservice: Add comments about the cfg_attrs around restricted_discovery. | Gabriela Moldovan | 2024-08-07 | 1 | -0/+3 | |
| | | ||||||
| * | tor-hsservice: Add missing docsrs cfg to restricted_discovery module. | Gabriela Moldovan | 2024-08-06 | 1 | -0/+1 | |
| | | | | | | | | | | | | Without it, if the `restricted-discovery` feature is compiled out, the module gets documented as: ``` Non-restricted-discovery (Available on non-crate feature `restricted-discovery` only) ``` which is inaccurate. | |||||
| * | tor-hsservice: Add an extra log in the descriptor publisher. | Gabriela Moldovan | 2024-08-05 | 1 | -0/+4 | |
| | | | | | This helped me debug some shadow test failures. | |||||
| * | tor-hsservice: Fix broken doc links in RestrictedDiscoveryConfig. | Gabriela Moldovan | 2024-08-05 | 1 | -6/+4 | |
| | | ||||||
| * | tor-hsservice: Rewrite read_keys impl to be more functional. | Gabriela Moldovan | 2024-08-05 | 1 | -21/+11 | |
| | | ||||||
| * | tor-hsservice: Use DirEntry::file_name to simplify key file reading logic. | Gabriela Moldovan | 2024-08-05 | 1 | -19/+14 | |
| | | ||||||
| * | tor-hsservice: Reduce code duplication in restricted mode tests. | Gabriela Moldovan | 2024-08-05 | 1 | -6/+3 | |
| | | ||||||
| * | tor-hsservice: Give static_keys precedence over key_dirs (fmt). | Gabriela Moldovan | 2024-08-05 | 3 | -16/+8 | |
| | | ||||||
| * | tor-hsservice: Give static_keys precedence over key_dirs. | Gabriela Moldovan | 2024-08-05 | 2 | -32/+100 | |
| | | | | | | This rewrites `RestrictedDiscoveryConfig::read_keys` to give `static_keys` precedence over the keys from `key_dirs`. | |||||
| * | tor-hsservice: Do not error if there are more than ↵ | Gabriela Moldovan | 2024-08-05 | 3 | -93/+24 | |
| | | | | | | | MAX_RESTRICTED_DISCOVERY_CLIENTS. Prompted by https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2266#note_3051758 | |||||
| * | tor-hsservice: Add a note about live updates. | Gabriela Moldovan | 2024-08-05 | 1 | -0/+7 | |
| | | ||||||
| * | tor-hsservice: Use the configured authorized clients when encrypting the ↵ | Gabriela Moldovan | 2024-08-05 | 5 | -8/+49 | |
| | | | | | descriptor. | |||||
| * | tor-hsservice: Remove unused import from internal prelude. | Gabriela Moldovan | 2024-08-05 | 1 | -1/+0 | |
| | | | | | | The base64ct dependency is now unused in tor-hsservice, so we should consider removing it at some point. | |||||
| * | tor-hsservice: Remove unused config types. | Gabriela Moldovan | 2024-08-05 | 1 | -79/+0 | |
| | | ||||||
| * | tor-hsservice: Store the client keys in RunningOnionService. | Gabriela Moldovan | 2024-08-05 | 2 | -0/+41 | |
| | | ||||||
| * | tor-hsservice: Use restricted config option in OnionServiceConfig. | Gabriela Moldovan | 2024-08-05 | 1 | -13/+30 | |
| | | ||||||
| * | tor-hsservice: Add restricted discovery configuration. | Gabriela Moldovan | 2024-08-05 | 3 | -1/+914 | |
| | | ||||||
| * | tor-hsservice: Remove extraneous whitespace. | Gabriela Moldovan | 2024-08-05 | 1 | -2/+2 | |
| | | ||||||
| * | tor-hsservice: Add OnionServiceBuilder, deprecate OnionService::new. | Gabriela Moldovan | 2024-07-15 | 2 | -1/+36 | |
| | | | | | Closes #1490 | |||||
| * | tor-hsservice: Abolish OnionServiceState (fmt). | Gabriela Moldovan | 2024-07-15 | 1 | -24/+27 | |
| | | | | | Includes both `cargo fmt` and some manual code motion. | |||||
| * | tor-hsservice: Abolish OnionServiceState. | Gabriela Moldovan | 2024-07-15 | 1 | -38/+21 | |
| | | | | | | | | | | | | | | | | This removes a mostly-unnecessary struct holding the state of an `OnionService` or `RunningOnionService`. It only exists because I wanted to reduce the duplication of the `OnionService` and `RunningOnionService` fields. I am removing it because `OnionService` will soon become a builder, and this inner structure is making it difficult to create an ergonomic builder API (if we keep `OnionServiceState`, the builder fields won't map 1:1 to the fields of the build `OnionService` type). Note: this commit intentionally a bit misformatted to make reviewing easier. The reformatting will come in a future commit. | |||||
