summaryrefslogtreecommitdiff
path: root/crates/tor-linkspec
Commit message (Collapse)AuthorAgeFilesLines
* Patchlevel bumps for remaining changed crates.Nick Mathewson2023-02-281-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | These crates have had small code changes, but no API additions: tor-config tor-socksproto tor-cert tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr arti tor-hsservice tor-congestion These crates have had API extensions: fs-mistrust tor-llcrypto tor-bytes tor-checkable tor-linkspec tor-netdoc tor-persist arti-client
* tor-linkspec: New UnparsedLinkspec type.Nick Mathewson2023-02-173-1/+82
| | | | | | | | | | Unlike linkspec, this doesn't validate the actual contents of the specifiers. We'll use this so we can handle the linkspec list for an introduction point in an HsDesc, and just pass it on when constructing our circuits. I haven't added any accessor or constructor functions, because I don't expect to need them.
* tor-linkspec: LinkSpec parsing: use read_nested_u8len (fmt)Ian Jackson2023-02-061-13/+15
|
* tor-linkspec: LinkSpec parsing: use read_nested_u8lenIan Jackson2023-02-061-21/+5
| | | | This eliminates hardcoded length values.
* Bump the patch version of every crate that had API additionsNick Mathewson2023-02-011-3/+3
| | | | | | These crates had API or behavior changes that may affect downstream crates. Fortunately, they're all version 0.x, and don't need minor bumps for this.
* Bump the patch-level version of crates with _minor_ changes.Nick Mathewson2023-02-011-1/+1
| | | | | | | These changes influence behavior, but not effect compatibility. (If I messed up, and any crate except for `arti` has non-breaking API changes, that's still fine, since they are all version 0.x.)
* Bump the patch version of each crate with _trivial_ changes.Nick Mathewson2023-02-011-1/+1
| | | | | These crates have not had changes to their behavior; as such it is not necessary to bump their dependencies to require the new versions.
* Allow clippy::unchecked_duration_subtraction in testsNick Mathewson2023-01-277-0/+7
| | | | | This panics on error, and we're fine with a panic on misbehavior in tests.
* Disable clippy::unlinlined-format-argsNick Mathewson2023-01-271-0/+1
| | | | | | | | This warning kind of snuck up on us! (See #748) For now, let's disable it. (I've cleaned it up in a couple of examples, since those are meant to be more idiomatic and user-facing.) Closes #748.
* Merge branch 'ya-lint' into 'main'eta2023-01-061-1/+4
|\ | | | | | | | | tor-linkspec: Fix an unused lint See merge request tpo/core/arti!935
| * tor-linkspec: Fix an unused lintIan Jackson2022-12-121-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise: cargo +stable clippy -p tor-proto --all-features --all-targets Produces: warning: unused import: `PtTargetAddr` --> crates/tor-linkspec/src/traits.rs:9:28 | 9 | use crate::{ChannelMethod, PtTargetAddr, RelayIdRef, RelayIdType, RelayIdTypeIter}; | ^^^^^^^^^^^^
* | Merge branch 'test-lints' into 'main'eta2023-01-066-0/+48
|\ \ | | | | | | | | | | | | Add test lint blocks to all "mod test" See merge request tpo/core/arti!937
| * | test lint blocks: Add many many automaticallyIan Jackson2022-12-126-0/+48
| |/ | | | | | | | | This is precisely the result of running the rune in maint/adhoc-add-lint-blocks.
* / doc: consistent summary line for the READMEsEmil Engler2022-12-201-1/+1
|/ | | | | This commit introduces a consistency to the summary line of all README.md files in each and every crate.
* Remove semver.md files now that 1.1.0 is released.Nick Mathewson2022-11-301-12/+0
|
* Bump the minor version of every crate.Nick Mathewson2022-11-301-7/+7
| | | | | We made this job easy this time around: by incrementing our MSRV, we have forced ourselves to do at least a minor bump everywhere.
* bridge config: Rename accessorsIan Jackson2022-11-301-2/+2
| | | | | As per https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/904#note_2858480
* BridgeAddr tests: dedupe slightlyIan Jackson2022-11-301-12/+11
|
* Separate BridgeAddr and PtTargetAddrIan Jackson2022-11-303-38/+212
| | | | | | | | | As per https://gitlab.torproject.org/tpo/core/arti/-/issues/668#note_2858220 This commit is difficult to split up. The innards of BridgeAddr and PtTargetAddr are still a bit entangled.
* Merge branch 'more-linkspec-tests' into 'main'Nick Mathewson2022-11-294-15/+160
|\ | | | | | | | | Add tests for a bunch of code in tor-linkspec See merge request tpo/core/arti!867
| * Fix up compatibility issues between linkspec tests and other patchesNick Mathewson2022-11-281-5/+5
| |
| * linkspec: Add some tests for ChannelMethodNick Mathewson2022-11-282-0/+85
| |
| * linkspec: Tests for PtTargetSettingsNick Mathewson2022-11-281-0/+46
| |
| * PtTransportName: Remove unused accessors.Nick Mathewson2022-11-281-13/+0
| |
| * linkspec: Add tests for has_any_identity.Nick Mathewson2022-11-281-0/+7
| |
| * linkspec: Add test for lookup on no-ids.Nick Mathewson2022-11-281-0/+1
| |
| * Add a test for ByRelayIds::remove_by_all_idsNick Mathewson2022-11-281-2/+21
| |
* | Remove deprecated aliases in tor-linkspec.Nick Mathewson2022-11-292-10/+2
| |
* | Add a default debug_redacted impl to save space.Nick Mathewson2022-11-281-4/+0
| |
* | linkspec: Give a Redacted form for chantarget.Nick Mathewson2022-11-285-7/+84
|/
* Make ChannelMethod non-exhaustiveIan Jackson2022-11-242-1/+2
| | | | | | | | | Enums with variants conditional on cargo features must be non-exhaustive, because cargo features are supposed to be additive, meaning that enabling a feature (which might happen due to some random distant thing) ought not to break things using that enum. There were surprisingly few places to fix this.
* tor-linkspec: Provide LoggedChanTarget type alias and utility methodIan Jackson2022-11-233-2/+14
| | | | | This makes it easy to talk about, and construct, a BoxSensitive<OwnedChanTarget>, which is what we'll use in errors.
* TransportId: Fix test case for no pt-targetIan Jackson2022-11-221-16/+19
| | | | | | | | | | | Fixes cargo +stable clippy --manifest-path=/home/ian/Rustup/Arti/arti/Cargo.toml --locked --target-dir=target --offline -p tor-linkspec --no-default-features --all-targets giving 446 | .method(ChannelMethod::Pluggable(PtTarget::new( | ^^^^^^^^^ variant or associated item not found in `transport::ChannelMethod`
* TransportId: Parse "bridge" as builtin transportIan Jackson2022-11-221-3/+8
| | | | | This will allow transport="bridge" in bridge configurations, etc. Doing it at this layer means it will be recognised everywhere.
* TransportId: Provide new_builtin and new_pluggableIan Jackson2022-11-221-0/+15
| | | | | I think normal Rustic practice is to provide a real constructor as well as just `Default`.
* TransportId: Provide name accessor and deconstructorIan Jackson2022-11-221-0/+26
| | | | | We are maintaining the notion that at some point this thing might grow additional variants.
* TransportId: Document and change string repr for builtinIan Jackson2022-11-221-6/+16
| | | | | | * Change the Display of builtin to "-" * Parse "" and "-" as builtin, as well as "<none>" * Document this
* TransportId: Add test case for builtin Display reprIan Jackson2022-11-221-0/+2
|
* BridgeAddr rename from PtTargetAddr: Update in tor-linkspecIan Jackson2022-11-213-29/+38
| | | | | | | | | | | | | | And the error too. We need this for the API for BridgeConfigBuilder, where the user can specify any kind of target "address", even a hostname. It's already non-conditional, it's just that the name is too limiting. In this commit: * Change in tor-linkspec * Export transitional aliases * Add TODOs to remove the transitional aliases
* tor-linkspec: Provide deconstructors for PtTargetSettings and PtTargetIan Jackson2022-11-212-0/+11
|
* Fix a missing import in tests.Nick Mathewson2022-11-181-1/+1
| | | | I'm not sure why the CI didn't reject this the first time around.
* Merge branch 'refactor_into_ownedchantarget' into 'main'Nick Mathewson2022-11-183-9/+21
|\ | | | | | | | | CircMgr: Refactor DirSpecificTarget constructor See merge request tpo/core/arti!866
| * CircMgr: Refactor DirSpecificTarget constructorNick Mathewson2022-11-183-9/+21
| | | | | | | | | | | | | | | | | | | | | | | | This commit replaces the `impl From<&T> for OwnedChanTarget where T:ChanTarget` with a new `IntoOwnedChanTarget` trait. This lets us be explicit that we're constructing an owned object, and not just converting something. No semver change needed, since these APIs haven't been released. ----------- (new description)
* | Merge branch 'mark-bridges-not-experimental' into 'main'Nick Mathewson2022-11-182-5/+10
|\ \ | | | | | | | | | | | | | | | | | | Mark bridge and PT-related APIs as non-experimental. Closes #643 See merge request tpo/core/arti!865
| * | linkspec: Make "pt-client" non-experimental.Nick Mathewson2022-11-162-5/+10
| |/
* | Remove impl Display for OwnedCircTargetNick Mathewson2022-11-172-8/+1
| | | | | | | | | | Nothing used this; if anything wants it, it would be better off calling `.display_chan_target()`.
* | ChanTarget: Add a display function, with better output.Nick Mathewson2022-11-172-13/+80
|/ | | | | | | | | | This change lets us display a ChanTarget's members without first cloning them into an OwnedChanTarget. It also resolves a reliability issue by outputting better info when talking about connections via pluggable transports. Closes #647
* Allow a subset-only ChanMethod match when looking up a BridgeConfigNick Mathewson2022-11-151-0/+15
| | | | | | | | | If we have a bridge guard that is using Direct connection and it knows multiple addresses, our code to match it with a BridgeConfig is wrong, because the BridgeConfig has only one address, and our code looks for an exact match. Fixes #642.
* Remove allow() for a false-positive warn on Rust 1.56.Nick Mathewson2022-11-101-3/+0
|
* Upgrade to serde_with 2, phf 0.11. Closes #526.Nick Mathewson2022-11-101-1/+1
|