| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| | |
| |
| |
| |
| |
| | |
So now .arti_pattern() is a trait method.
arti#1151 item 3.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
arti_prefix is no longer used. Abolish prefix too.
arti#1151 item 7.
Closes #1147.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
This is a better API. The implementation has less monomorphisation.
arti#1151 item 2 and the patterns part of 4.
Closes #1126.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
This reduces monomorphisation.
arti#1151 item 4.
The commentary reflects a decision not to do arti#1151
item 9 (using fmt signature for to_component) at this time.
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| | |
Part of arti#1151 item 10.
Discussion in
https://gitlab.torproject.org/tpo/core/arti/-/issues/1151#note_2977278
|
| | |
| |
| |
| | |
This is going to expand and gain private helper methods.
|
| | |
| |
| |
| |
| | |
We don't handle enums and we don't want to try.
Put this here as documentation of this intent.
|
| | |
| |
| |
| | |
arti#1151 item 1.
|
| | |
| |
| |
| | |
Now d-a #27 is fixed, we don't need this.
|
| |/
|
|
|
| |
As recommended in the d-a changelog, I'm not calling this a breaking
change to our APIs.
|
| | |
|
| |
|
|
|
| |
I'm not sure about this. Leaving it this way seems the most
conservative choice for now.
|
| | |
|
| | |
|
| |
|
|
| |
Diziet addressed these in #1049
|
| |
|
|
|
|
|
|
|
| |
Note: any existing x25519 or expanded ed25519 keys you might have in the
keystore will become invalid (your keystore will appear corrupt, so you
will need to manually delete them if you want to continue using the
onion service they were originally generated for).
Part of #1108
|
| |
|
|
|
|
|
|
|
| |
The sub_builder pattern changes `StorageConfigBuilder` so that
instead of holding an `Option<ArtiNativeKeystoreConfig>`,
it holds an `ArtiNativeKeystoreConfigBuilder`.
This makes it a little more ergonomic to use from Rust,
and lets us use defaults for the builder fields so that we
can make them optional in our configuration.
|
| | |
|
| | |
|
| |
|
|
| |
This makes this like the list for ArtiPath.
|
| |
|
|
| |
That would allow construction of invalid paths.
|
| |
|
|
|
|
|
|
|
| |
Test that the FromStr and TryFrom impls give the same answers as
new().
These tests dodn't even compile before
Properly validate in FromStr
because the derive-more generated version has a wrong error type.
|
| |
|
|
|
|
|
| |
As pointed out in
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1796#note_2974513
derive-more just parses like the inner type, so an unvalidated String.
That is wrong.
|
| |
|
|
| |
Now ArtiPath too is TryFrom<String> and AsRef<str>.
|
| |
|
|
| |
This makes it more like ArtiPathComponent and will allow more unification
|
| | |
|
| |
|
|
|
|
| |
Rename VALID_ARTI_PATH_COMPONENTS from _PATHS. These are tested for
validity as components. I want to add a test for a multi-component
path, so make a place to put it.
|
| |
|
|
| |
Rebinding inner locally like this confused me.
|
| | |
|
| |
|
|
| |
These don't seem critical to me.
|
| | |
|
| | |
|
| |
|
|
|
| |
The previous name was ambiguous, and confusable with KeyPathError
(of which it is, basically, a variant).
|
| | |
|
| |
|
|
| |
Fix docs link breakage.
|
| |
|
|
| |
Minimal changes to still compile and pass tests.
|
| |
|
|
|
|
| |
Normally as_... is a cheap and non-consuming (reference to reference)
conversion. to_ is better here since we don't consume, but we do
allocate.
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
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.
|
| | |
|
| |
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
| |
Call sites are shortly going to need the component on the error path,
so this function ought probably not to consume it.
|
| |
|
|
|
|
| |
This is a hostage to fortune.
(In a previous version of !1796 I wanted to make it untrue.)
|
| |
|
|
| |
Make it possible for the role to be a field.
|
| |
|
|
| |
This saves on some stringify! and improves error checking.
|
| | |
|
| |
|
|
|
| |
We're going to do another per-field thing that doesn't want this
condition.
|
| | |
|
| |
|
|
|
|
| |
The `summary` attribute refers to a field in KeyPathInfo but this
field isn't public. We can refer to builder, but there should be
getters or something.
|