| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| |
|
|
|
|
|
|
|
| |
The fields are never read but need to be present in order for the
dummy `KeyMgrBuilder` to have the same interface as the real one.
(We could of course manually implement the builder, or let the dummy
`KeyMgrBuilder` impl diverge from the real one, but for now let's leave
this as-is and simply mark the fields as unused).
|
| |
|
|
|
| |
We no longer have any dummy keymgr operations that return an error,
so this error type is unused.
|
| | |
|
| |
|
|
| |
This is not used anywhere (or exported publicly).
|
| |
|
|
|
| |
This commit applies Diziet's suggestion from
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2631#note_3130234
|
| |
|
|
|
|
|
| |
These are not actually needed anywhere.
In fact, it's a bad idea to have them in the first place (see the
comment from the dummy `KeyMgr` impl block).
|
| |
|
|
|
|
|
|
| |
This is based on a recent discussion with @Diziet on IRC.
For the full context, see the chat log attached to the ticket.
Closes #1732
|
| |
|
|
|
|
|
|
|
|
| |
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.
|
| | |
|
| |
|
|
| |
Part of #1115
|
| | |
|
| |
|
|
| |
Part of #1115
|
| |
|
|
|
|
| |
This trait extracts a `KeyPathInfo`, not a `KeyInfo`.
Part of #1115
|
| | |
|
| |
|
|
|
| |
Not calling it results in an error (it instantiates the plugin
registry for our type).
|
| |\
| |
| |
| |
| |
| |
| | |
tor-keymgr: Derive Builder for KeyMgr.
Closes #1114
See merge request tpo/core/arti!1760
|
| | |
| |
| |
| |
| |
| |
| | |
Eventually these will need to be auto-generated, but that is not
possible right now.
Context: https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1760#note_2969841
|
| | |
| |
| |
| | |
We don't use this now that we have a `KeyMgrBuilder`.
|
| | |
| |
| |
| |
| |
| |
| | |
`KeyMgr` is soon going to have more fields, so now is a good time to
derive `Builder` for it.
Closes #1114
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously, the `tor_keymgr::Error` type was `Box<dyn KeystoreError>`.
This forced us to impl `KeystoreError` for any error returned by the
keymgr (including those that were not coming from a `Keystore` impl).
Now, `tor_keymgr::Error` is an non-exhaustive enum and the `Box<dyn
KeystoreError>` opaque error type is only returned from `Keystore` impls
The reason we're keeping the `dyn KeystoreError` error type is because
it enables `Keystore` implementors to use their own error types. Without
it, they would have to choose from our (closed) set of error variants,
which may not be suitable for their keystore. See #901.
|
| |/
|
|
|
|
|
|
| |
We are about to add a top-level `tor_keymgr::Error` enum that has a
variant that contains a `KeyType`. The error enum needs to be `Clone`,
so we need `KeyType` (both the dummy version and the "real" one, because
the `err` module is not cfg'd behind the `keymgr` feature) to be
`Clone`.
|
| |
|
|
|
|
|
|
|
| |
keys from."
This reverts commit 38a6c74c7894dc96b16c9039cacc2a4023977b05.
This also updates some tests to make them compile with the reverted
version of the code.
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
The caller uses `KeystoreSelector` to specify which keystore to insert
the new key into (only `KeystoreSelector::Id` and
`KeystoreSelector::Default` are supported for `insert`).
The ability to insert keys in a particular keystore will come in handy
when we implement the key management CLI (the CLI will have an option
for specifying the keystore to access/modify).
|
| | |
|
| |
|
|
|
| |
We've been capitalizing the "s" in "KeyStore" inconsistently. This
`s/KeyStore/Keystore/g` across the codebase.
|
| |
|
|
|
| |
`Error` is private to `dummy.rs` so let's not mention it in the docs of
the public items.
|
| |
|
|
|
|
|
|
| |
This fixes a rustdoc warning when building with:
```
cargo doc --locked --offline -p arti --no-default-features --features=full,onion-service-client
```
|
| |
|
|
|
|
| |
We don't really need the `AsRef<dyn StdError>` impls if we make
`StdError` a supertrait of `KeystoreError` (and remove the `AsRef<dyn
StdError>` trait bound).
|
| |
|
|
| |
Part of #901
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
We don't need dummy impls for `Error` and `Result`.
|
| |
|