aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-hsservice/src
Commit message (Collapse)AuthorAgeFilesLines
...
| * tor-hsservice: tests: IptKeySpecifier: Do round trip testIan Jackson2023-12-071-8/+8
| |
| * tor-hsservice: IptKeySpecifier: impl KeySpecifier via macroIan Jackson2023-12-071-14/+8
| |
| * tor-hsservice: IptKeySpecifier: make it ownedIan Jackson2023-12-072-5/+5
| | | | | | | | | | The macro is going to want to be able to do a back-conversion from an ArtiPath, so there has to be an owned version.
| * tor-hsservice: IptKeySpecifier: reorder fieldsIan Jackson2023-12-071-2/+2
| | | | | | | | | | Now they are in the order they appear in the ArtiPath, which is a bit clearer.
| * tor-hsservice: IptKeyRole: impl FromStr and KeySpecifierComponentIan Jackson2023-12-071-1/+4
| |
| * tor-hsservice: IptLocalId: impl KeySpecifierComponentIan Jackson2023-12-071-0/+3
| |
| * tor-hsservice: IptLocalId: impl FromStr (fmt)Ian Jackson2023-12-071-4/+2
| |
| * tor-hsservice: IptLocalId: impl FromStrIan Jackson2023-12-072-27/+18
| | | | | | | | And implement serde that way, using SerdeStringOrTransparent.
| * tor-hsservice: Expose SerdeStringOrTransparent to crateIan Jackson2023-12-072-2/+4
| | | | | | | | | | And make it useable elsewhere by not expecting the particular error type.
| * tor-keymgr: Make KeySpecifierComponent::as_component fallibleIan Jackson2023-12-071-1/+1
| | | | | | | | | | | | | | | | | | | | This allows a principled implentation via Display. The alternative would be to have runtime panics whenever someone uses KeySpecifierComponentViaDisplayFromStr but the Display impl can produce wrong syntax (that doesn't fit in an ArtiPathComponent). Bug seems like the right error since implemnting KeySpecifierComponent implies that every value is representable in an ArtiPathComponent.
| * tor-keymgr: Introduce InvalidKeyPathComponentValue errors (fmt)Ian Jackson2023-12-071-9/+8
| |
| * tor-keymgr: Introduce InvalidKeyPathComponentValue errorsIan Jackson2023-12-071-1/+7
| | | | | | | | | | | | | | | | This is a variant in KeyPathError, which contains the actual wrong value, and the key name. But it is also a unit struct to return from the trait impl. This replaces ArtiPathError::InvalidDenotator.
| * tor-hsservice: Prepare for different denotator error handlingIan Jackson2023-12-071-5/+6
| | | | | | | | | | Save the ArtiPathComponent in a variable and separate out the Ok(tp) for clarity. No functional change.
| * tor-keymgr: Have KeySpecifierComponent::from_component take a refIan Jackson2023-12-071-1/+1
| | | | | | | | | | Call sites are shortly going to need the component on the error path, so this function ought probably not to consume it.
| * tor-keymgr: Replace assert_key_specifier_rountrip macro with function (fmt)Ian Jackson2023-12-071-12/+3
| | | | | | | | Formatting churn at call sites.
| * tor-keymgr: Replace assert_key_specifier_rountrip macro with functionIan Jackson2023-12-071-13/+8
| | | | | | | | The new function checks both directions. The (misspelled) macro didn't.
| * tor-keymgr: provide KeySpecifierComponentViaDisplayFromStr and use itIan Jackson2023-12-071-13/+2
| | | | | | | | Now the only manual impl is TimePeriod, which is indeed special.
| * ArtiPaths: derive FromStr for ArtiPath ArtiPathComponent HsNickname (fmt)Ian Jackson2023-12-071-2/+13
| | | | | | | | Mandatory horrible formatting.
| * ArtiPaths: derive FromStr for ArtiPath ArtiPathComponent HsNicknameIan Jackson2023-12-071-0/+1
| |
* | Add a "Shutdown" status, and clarify places where status should change.Nick Mathewson2023-12-074-5/+19
| |
* | Add a status API to OnionService.Nick Mathewson2023-12-073-11/+168
|/ | | | | | (This doesn't yet send any status events.) Begins work on arti#1083.
* tor-hsservice: Add more info to an internal error (fmt).Gabriela Moldovan2023-12-051-6/+7
|
* tor-hsservice: Add more info to an internal error.Gabriela Moldovan2023-12-051-1/+9
| | | | | Logging the current time and the start of the time period might help us debug #1143 (we'll at least know how far off `now` is from `start`).
* tor-hsservice: Fix clippy warning.Gabriela Moldovan2023-12-051-1/+1
|
* tor-hsservice: Wrap some long lines in a helper macro.Gabriela Moldovan2023-12-051-4/+11
|
* tor-hsservice: Add a cross-reference to KeystoreSweeper.Gabriela Moldovan2023-12-051-0/+7
|
* tor-keymgr: Abolish the KeyDenotator trait in favour of KeyPathComponent (fmt).Gabriela Moldovan2023-12-051-2/+6
|
* tor-keymgr: Abolish the KeyDenotator trait in favour of KeyPathComponent.Gabriela Moldovan2023-12-051-2/+4
|
* tor-hsservice: Stop the KeystoreSweeper task when the service exits (fmt).Gabriela Moldovan2023-12-053-57/+62
|
* tor-hsservice: Stop the KeystoreSweeper task when the service exits.Gabriela Moldovan2023-12-052-7/+30
|
* tor-hsservice: Make shutdown a broadcast channel.Gabriela Moldovan2023-12-052-11/+13
| | | | | We will soon need another component to be able to subscribe to the shutdown signal.
* tor-hsservice: Move remove_if_expired macro inside task (fmt).Gabriela Moldovan2023-12-051-9/+3
|
* tor-hsservice: Move remove_if_expired macro inside task.Gabriela Moldovan2023-12-051-37/+22
|
* tor-keymgr: Update key summary strings to be less verbose.Gabriela Moldovan2023-12-051-5/+5
|
* tor-hsservice: Test the TryFrom<&KeyPath> KeySpecifier impl.Gabriela Moldovan2023-12-051-1/+7
|
* tor-hsservice: Add some useful derives for the key specifiers.Gabriela Moldovan2023-12-051-5/+5
|
* tor-hsservice: Add a helper for removing expired keys.Gabriela Moldovan2023-12-052-3/+154
| | | | Closes #1043
* tor-hsservice: Make the KeySpecifier fields crate-public.Gabriela Moldovan2023-12-051-7/+7
| | | | We're about to use them.
* tor-keymgr: Store an owned type instead.Gabriela Moldovan2023-12-056-43/+52
| | | | | | We need this because the key specifier types will soon be owned types too (they will soon grow a From<&KeyPath> impl). We _could_ make them store `Cow`s instead, but I think that's a premature optimization.
* tor-keymgr: Make all arguments of arti_pattern optional.Gabriela Moldovan2023-12-051-1/+1
| | | | | We're going to need this soon (to match all hidden service keys, regardless of nickname, for example).
* tor-keymgr: Introduce a KeySpecifierComponent trait.Gabriela Moldovan2023-12-051-1/+19
| | | | | | | | | Now the fields of a `DefaultKeySpecifier` no longer have to implement `Display` (they need to implement `KeySpecifierComponent`). See https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1733#note_2966400 Closes #1127
* tor-keymgr: Change KeyDenotator error type to KeyPathError.Gabriela Moldovan2023-12-051-2/+2
| | | | | This is a separate class of errors that deserves its own error type. We will soon use `KeyPathError` in other contexts as well.
* tor-hsservice: IptKeySpecifier: add a TODO HSSIan Jackson2023-12-041-0/+2
|
* tor-hsservice: ipt_set: Remove a blocking TODOIan Jackson2023-12-041-1/+0
| | | | This function became non-dead in some earlier commit.
* tor-hsservice tests: Add some TODOs re IPT accepting stateIan Jackson2023-12-041-0/+8
|
* tor-hsservice tests: Check that restart gives us the same IPTs (fmt)Ian Jackson2023-12-041-11/+18
| | | | Mandatory formatting degradation.
* tor-hsservice tests: Check that restart gives us the same IPTsIan Jackson2023-12-041-2/+24
| | | | | | Store the IptParameters in the MockEstabState, and provide a function to list what the IPTs are. Then we can check the IPTs are reloaded and restored after restart.
* tor-hsservice tests: Test restarting the IPT managerIan Jackson2023-12-041-0/+9
| | | | | This is supposed to reload the state. In the next commit we'll check at least some of the things.
* tor-hsservice tests: Break out shutdown_check_no_tasksIan Jackson2023-12-041-4/+7
| | | | We're going to add another call site in a moment.
* tor-hsservice: Use keystore to store and reuse IPT keysIan Jackson2023-12-044-9/+85
|