summaryrefslogtreecommitdiff
path: root/crates
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | | | tor-keymgr: Move assert_found helper to test_utils.Gabriela Moldovan2024-10-082-14/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves `assert_found` out of the `keystore::arti::test` so we can reuse it for testing other keystore implementations too.
| * | | | | tor-keymgr: Add tests for the keystore config.Gabriela Moldovan2024-10-082-0/+165
| | | | | |
| * | | | | tor-config: Expose assert_config_error test helper.Gabriela Moldovan2024-10-085-15/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the `assert_config_error` helper from the restricted discovery config tests to a `testing` module in `tor-config` (I am about to reuse it for the C Tor keystore config tests too).
| * | | | | tor-keymgr: Validate keystore ID uniqueness in ArtiKeystoreConfigBuilder.Gabriela Moldovan2024-10-081-1/+23
| | | | | |
| * | | | | arti-client, tor-keymgr: Remove a couple of now-addressed TODOs.Gabriela Moldovan2024-10-082-6/+0
| | | | | |
| * | | | | tor-key-forge: Remove now-outdated TODO.Gabriela Moldovan2024-10-081-3/+0
| | | | | |
| * | | | | tor-key-forge: Remove unused function.Gabriela Moldovan2024-10-081-8/+0
| | | | | |
| * | | | | arti-client: Use the configured C Tor client keystores.Gabriela Moldovan2024-10-083-3/+14
| | | | | |
| * | | | | tor-keymgr: Add configuration for C Tor client keystores.Gabriela Moldovan2024-10-083-4/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is intentionally partially mis-indented to make this more reviewable (in case the reviewer isn't using `ignore-all-space`).
| * | | | | arti-client: Use the configured C Tor keystores, if any.Gabriela Moldovan2024-10-084-12/+28
| | | | | |
| * | | | | tor-keymgr: Derive Getters for CTorKeystoreConfig.Gabriela Moldovan2024-10-081-1/+1
| | | | | |
| * | | | | tor-keymgr: Derive Getters for the ArtiKeystoreConfig.Gabriela Moldovan2024-10-081-1/+2
| | | | | |
| * | | | | arti-client: Refactor KeyMgr building logic.Gabriela Moldovan2024-10-081-15/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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).
| * | | | | tor-keymgr: Add a keystore for C Tor client keys.Gabriela Moldovan2024-10-084-1/+332
| | | | | |
| * | | | | tor-keymgr: Add a keystore for C Tor service keys.Gabriela Moldovan2024-10-085-0/+479
| | | | | |
| * | | | | tor-keymgr: Rename Filesystem variant to Io for clarity (fmt).Gabriela Moldovan2024-10-082-44/+57
| | | | | |
| * | | | | tor-keymgr: Rename Filesystem variant to Io for clarity.Gabriela Moldovan2024-10-082-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `FilesystemError::Filesystem` variant was actually just for IO errors.
| * | | | | tor-keymgr: Refactor common fs errors into a separate error enum.Gabriela Moldovan2024-10-083-76/+96
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will be reused by other on-disk key stores (such as the C Tor ones we're about to add). I recommend reviewing this commit using `git diff --color-moved=zebra --ignore-space-change`
| * | | | | tor-keymgr: Add RelKeyPath::from_parts constructor.Gabriela Moldovan2024-10-081-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | This will be used to create relative paths representing C Tor keys.
| * | | | | tor-keymgr: Rename RelKeyPath::new to RelKeyPath::arti.Gabriela Moldovan2024-10-082-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | We're about to add a separate constructor for CTor paths.
| * | | | | tor-keymgr: Move the checked_op utils out of the arti module.Gabriela Moldovan2024-10-083-10/+16
| | | | | | | | | | | | | | | | | | | | | | | | We are about to use this for the ctor keystore implementation too.
| * | | | | tor-hsclient: Implement ctor_path for client keys.Gabriela Moldovan2024-10-081-1/+8
| | | | | |
| * | | | | tor-hsservice: Implement ctor_path() for service keys.Gabriela Moldovan2024-10-081-0/+20
| | | | | |
| * | | | | tor-hsservice: Remove now-unused import from internal prelude.Gabriela Moldovan2024-10-081-1/+1
| | | | | |
| * | | | | tor-keymgr: Rename KeyPathRange to ArtiPathRange (fmt).Gabriela Moldovan2024-10-083-6/+6
| | | | | |
| * | | | | tor-keymgr: Rename KeyPathRange to ArtiPathRange.Gabriela Moldovan2024-10-086-10/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is only used for representing portions of `ArtiPath`s, so let's rename it accordingly.
| * | | | | tor-keymgr: Implement KeyPath::matches for CTorPaths.Gabriela Moldovan2024-10-084-22/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `KeyPath::matches` now returns a boolean (because we can't return a matching "range" for `CTorPaths`, because unlike ArtiPaths, they're not represented as `String`s, and do not have variable parts that need to be captured).
| * | | | | tor-keymgr: Reimagine CTorPath as an enum.Gabriela Moldovan2024-10-084-14/+82
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | C Tor's client restricted discovery keys don't have the service hsid encoded in the filename (the hsid of the service each key is associated with is encoded in contents of the key file). This means that given a key specifier like `HsClientDescEncKeypairSpecifier` (which is a wrapper over an HsId), we can't actually compute the relative path of the key in its `KeySpecifier::ctor_path()` implementation. To do so we would need to access the keystore to figure out which path contains the requested HsId, which we can't (and shouldn't!) do from within the `KeySpecifier` impl. This suggests the String newtype (representing a relative path) we previously had is not a good abstraction for `CTorPath`s. Moreover, `CTorPath` are static (they don't have dynamic components like `ArtiPath`), so it makes more sense to model `CTorPath` as an enum. The new `CTorPath::ClientHsDescEncKey(HsId)` variant will be used to instruct the C Tor client keystore to find the file that contains the specified `HsId`, while the `Service` variant will be used for hidden service keys.
| * | | | | arti: Remove extraneous whitespace from example config.Gabriela Moldovan2024-10-081-1/+1
| | | | | |
| * | | | | tor-keymgr: Add configuration for C Tor service keystores.Gabriela Moldovan2024-10-084-4/+245
| | | | | |
| * | | | | tor-keymgr: Return an error if the keystore IDs are not unique.Gabriela Moldovan2024-10-081-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `KeyMgrBuilder` now returns an error if the configured keystores don't have pairwise unique IDs. This is needed because some keymgr operations take a `KeystoreSelector` specifying the ID of the keystore the operation should be performed on, and assume that the keystore ID uniquely identifies a single keystore.
| * | | | | tor-keymgr: Move config/arti.rs to config.rsGabriela Moldovan2024-10-086-119/+120
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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`
| * | | | | tor-hsservice: Move HsNickname to tor-persist.Gabriela Moldovan2024-10-084-7/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We are about to need this in `tor-keymgr`, where we're about to add a config for C Tor service keystores (the C Tor keystore config will have an associated `HsNickname` that specifies which of the arti hidden services it's supposed to be used with).
* | | | | | Merge branch 'dyn-time-2' into 'main'Ian Jackson2024-10-081-11/+15
|\ \ \ \ \ \ | |_|_|_|/ / |/| | | | | | | | | | | | | | | | | tor-rtmock: dyn_time tests: Test the downcast fail path too See merge request tpo/core/arti!2500
| * | | | | tor-rtmock: dyn_time tests: rustfmtIan Jackson2024-10-081-3/+1
| | | | | |
| * | | | | tor-rtmock: dyn_time tests: Check DropCount on type-mismatch pathIan Jackson2024-10-081-1/+7
| | | | | |
| * | | | | tor-rtmock: dyn_time tests: Make try_downcast_string return S, not implIan Jackson2024-10-081-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will make it possible to use on a DropCounter and get a DropCounter back.
| * | | | | tor-rtmock: dyn_time tests: Break out try_downcast_stringIan Jackson2024-10-081-8/+8
| | | | | |
| * | | | | tor-rtmock: dyn_time tests: Rename try_downcast_dc from chkIan Jackson2024-10-081-2/+2
| |/ / / / | | | | | | | | | | | | | | | This will be clearer
* | | | | Merge branch 'update-feature-flag-docs' into 'main'Ian Jackson2024-10-081-3/+3
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | docs: Add vanguard feature flag to README. See merge request tpo/core/arti!2507
| * | | | | arti: Remove outdated information from README.Wesley Aptekar-Cassels2024-10-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We now support pluggable transports, so it's not true that there's no anti-censorship support.
| * | | | | docs: Add vanguard feature flag to README.Wesley Aptekar-Cassels2024-10-071-3/+3
| | |_|_|/ | |/| | |
* | | | | Merge branch 'memquota-macro-tidying' into 'main'Ian Jackson2024-10-081-21/+25
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | tor-proto: memquota: Tidying up See merge request tpo/core/arti!2508
| * | | | | tor-proto: memquota: Rationalise macro innardsIan Jackson2024-10-071-11/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | No functional change, but use of ${select1 ...} will make it easier to add more approaches.
| * | | | | tor-proto: memquota: Fix a docs typoIan Jackson2024-10-071-1/+1
| | | | | |
| * | | | | tor-proto: memquota: Rename SpecificAccount::Parent to ConstructedFromIan Jackson2024-10-071-11/+13
| |/ / / / | | | | | | | | | | | | | | | This was already a bit inaccurate and it's going to become more so.
* | | | | Merge branch 'circmgr-code-motion-for-tests' into 'main'Ian Jackson2024-10-081-193/+193
|\ \ \ \ \ | |_|/ / / |/| | | | | | | | | | | | | | Circmgr code motion for tests See merge request tpo/core/arti!2513
| * | | | CircMgr: Move note_external_{failure, success} methods to generic impl.Wesley Aptekar-Cassels2024-10-031-27/+27
| | | | |
| * | | | CircMgr: Move get_or_launch_dir_specific method to generic impl.Wesley Aptekar-Cassels2024-10-031-18/+18
| | | | |
| * | | | CircMgr: Move get_or_launch_exit method to generic impl.Wesley Aptekar-Cassels2024-10-031-45/+45
| | | | |