summaryrefslogtreecommitdiff
path: root/crates/tor-config
Commit message (Collapse)AuthorAgeFilesLines
* release: Bump `arti-*` and `tor-*` crates to 0.39.0Wesley Aptekar-Cassels2026-02-021-6/+6
| | | | | | | | | | Done via: ``` for crate in $(./maint/list-crates | rg '^(tor|arti-)'); do cargo set-version -p $crate 0.39.0 done ```
* Merge branch 'legacy-port-config' into 'main'wesleyac2026-02-022-79/+1
|\ | | | | | | | | | | | | arti: Remove `proxy.socks_port` and `proxy.dns_port` Closes #2300 See merge request tpo/core/arti!3622
| * tor-config: remove `resolve_alternative_specs` functionSteven Engler2026-02-012-81/+1
| |
| * arti: remove `resolve_listen_port!` macroSteven Engler2026-01-291-3/+5
| | | | | | | | | | | | I'm undecided whether we want to keep `resolve_alternative_specs` around, but it seems possible/likely that we'll want it in the future, so I think we can keep it.
* | Merge branch 'main' into 'main'gabi-2502026-02-021-1/+1
|\ \ | |/ |/| | | | | fix(minver): Update paste dependency to be minver compatible See merge request tpo/core/arti!3610
| * fix(minver): Update paste dependency to be minver compatibleSamuel Cobb2026-01-261-1/+1
| |
* | maint/add_warning: Run script to add new warningGabriela Moldovan2026-01-271-0/+1
|/ | | | This adds the lint to all our crates.
* meta: Remove all semver.md files post-releaseClara Engler2026-01-131-2/+0
| | | | | Fix the conflict in tor-netdoc/semver.md by hand, including the new entries already landed since v1.9.0.
* cargo: Update `arti-*` and `tor-*` to `0.38.0`Clara Engler2026-01-121-6/+6
| | | | | | | | | Done using the following: ```bash for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do cargo set-version -p $crate 0.38.0 done ```
* tor-config: small typo fix in docsSteven Engler2026-01-071-1/+2
|
* tor_config::listen: Warn on explicit port zero.Nick Mathewson2025-12-161-2/+17
|
* tor_config::Listen: Add methods to check for auto and port 0.Nick Mathewson2025-12-161-0/+37
|
* tor_config::Listen: Add "auto" itemsNick Mathewson2025-12-161-7/+55
| | | | These are a nicer syntax than using port "0" explicitly.
* tor_config::Listen: Deprecate localhost_port_legacy.Nick Mathewson2025-12-161-1/+5
| | | | Nothing actually uses it any more, which is good.
* tor_config::Listen: Refactor legacy methods.Nick Mathewson2025-12-161-22/+26
| | | | | Have the part of them that does the "no multiple addresses" work be common, so that we can simplify how they actually behave.
* tor-config: Make derive(Flattenable) use $crate.Nick Mathewson2025-12-091-4/+3
|
* Revert "tor-config: Code to serialize Option<Option<Duration>> via humantime"Nick Mathewson2025-12-093-28/+0
| | | | This reverts commit c7c8eb5a03439ce31319389183e64cb0db539fc9.
* tor-config: new derive_deftly(TorConfig) template.Nick Mathewson2025-12-093-0/+3042
| | | | | | | | This template is meant to replace most of our use of derive_builder for configuration objects. Where possible and reasonable, it delegates to existing macros, and automatically infers what special patterns we use for individual types. In other cases, it uses compile-time errors to inform the caller about pattern violations.
* tor-config: New Buildable trait.Nick Mathewson2025-12-091-2/+18
| | | | | | | | This trait will be implemented by every type that our derive_deftly(TorConfig) template generates. It will, among other things, help us figure out the Builder type for a given config type in cases where string-pasting magic is intractable, or where we want to use assert_not_impl to double-check the attributes.
* tor-config: Helper types for setters to take as argumentsNick Mathewson2025-12-092-0/+135
| | | | | The derive-deftly TorConfig template will use these as appropriate for the inputs to setter functions, based on field types.
* tor-config: Code to serialize Option<Option<Duration>> via humantimeNick Mathewson2025-12-093-0/+28
|
* tor_config: Make ListBuilders implement ExtendBuilder.Nick Mathewson2025-12-091-0/+11
|
* tor-config: Give Flattenable template a location.Nick Mathewson2025-12-091-0/+1
| | | | | | If we don't do this, then any attempt to use it from a derive-deftly template will cause a warning about referring to it as $crate::macroname.
* tor-config: Allow Flattenable to apply to types with generics.Nick Mathewson2025-12-091-1/+2
|
* map_builder: Alternative syntax for use by derive(TorConfig)Nick Mathewson2025-12-091-5/+51
| | | | | | | | | | derive_deftly wants to expand types before passing them to macro_rules macros, which is quite reasonable. But map_builder wants its input collection type to be an `ident`, not a `path`. (And macro_rules doesn't accept `path` before a `<`.) To fix this, we're providing an alternative syntax for map_builder, where the inputs are the map type and the builder map type.
* extend_builder: Implement ExtendBuilder for HashMap.Nick Mathewson2025-12-091-1/+17
|
* tor-config: missing #[allow(dead_code)] in derive_list_builder_helperNick Mathewson2025-12-091-0/+1
|
* tor-config: missing $crate in derive_list_builder_helperNick Mathewson2025-12-091-1/+1
|
* tor-config: obviate need for Educe in derive_list_builder_helperNick Mathewson2025-12-091-2/+11
| | | | | | We were only using it for Default, and it is easier to implement Default by hand than it is to keep this particular layer in our leaning tower of macros.
* Update to derive-deftly 1.6.0Ian Jackson2025-12-031-1/+1
| | | | | | | | | This has: * Fixes to hygiene spans from the new modules feature, needed for my WIP netdoc encoder derive. * A substantially richer `${error }` construct.
* Merge branch 'listen' into 'main'opara2025-12-022-112/+313
|\ | | | | | | | | tor-config: Refactor `Listen` to make usable for arti-relay See merge request tpo/core/arti!3469
| * tor-config: improve comments about adding functionalitySteven Engler2025-12-021-5/+7
| |
| * tor-config: add more comments to `ListenItem`Steven Engler2025-12-021-1/+10
| |
| * tor-config: rename `Listen::is_localhost_only` to `is_loopback_only`Steven Engler2025-12-022-2/+11
| | | | | | | | Assumes that 0.37.0 will be the next version number.
| * tor-config: add new `CustomizableListen`Steven Engler2025-12-021-101/+193
| |
| * tor-config: fix some localhost vs loopback names/commentsSteven Engler2025-11-141-4/+5
| |
| * tor-config: made `InvalidListen` privateSteven Engler2025-11-142-1/+2
| | | | | | | | There was no reason for this to be public.
| * tor-config: simplify a match statementSteven Engler2025-11-141-8/+4
| | | | | | | | This does a little extra cloning, but I think is easier to read.
| * tor-config: add serde error messages to `ListenSerde` and `ListenItemSerde`Steven Engler2025-11-141-2/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For example the old message would look like: ```text target/debug/arti: error: read configuration: Config contents not as expected: Couldn't load configuration: data did not match any variant of untagged enum ListenSerde for key "default.proxy.socks_listen" in command line ``` The new message looks like: ```text target/debug/arti: error: read configuration: Config contents not as expected: Couldn't load configuration: value was not a bool, `u16` integer, string, or list of integers/strings for key "default.proxy.socks_listen" in command line ```
| * tor-config: add more tests for `Listen`Steven Engler2025-11-141-0/+81
| |
| * tor-config: remove unneeded `Serialize`/`Deserialize`Steven Engler2025-11-131-2/+1
| |
* | Bump all the unstable tor- and arti- crates to 0.37.0.Gabriela Moldovan2025-12-021-6/+6
| | | | | | | | | | | | | | | | | | Done using: ``` for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do cargo set-version -p $crate 0.37.0 done
* | Bump the versions of the non-{arti-,tor-} cratesGabriela Moldovan2025-12-021-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The non-{arti-,tor-} crates are: ``` ./maint/list_crates | rg -v '^(tor|arti)' oneshot-fused-workaround slotmap-careful test-temp-dir fslock-guard hashx equix caret fs-mistrust safelog retry-error futures-copy ``` We split them in the following categories: * crates with no changes (no version bumps): None ``` maint/changed_crates -v "arti-v$LAST_VERSION" 2>&1 >/dev/null | grep -i "no change" | grep -v '\(tor\|arti\)-' ``` * crates that only have non-functional changes (bump the patch version, but not the dependend-on version): - oneshot-fused-workaround - slotmap-careful - test-temp-dir - fslock-guard - equix - caret - safelog - retry-error * crates where functional changes were made, but no APIs were added or broken: - hashx - fs-mistrust - futures-copy * crates where APIs were broken (bump minor): None The bumps from this commit were created using this script: ``` PATCH_NF=( oneshot-fused-workaround slotmap-careful test-temp-dir fslock-guard equix caret safelog retry-error ) PATCH=" hashx fs-mistrust futures-copy " ./maint/bump_nodep "${PATCH_NF[@]}" for crate in $PATCH; do cargo set-version --bump patch -p $crate; done ```
* tor-config: fix error source for `ConfigLoadError`Steven Engler2025-11-131-1/+7
|
* Bump derive-deftly to 1.5.0Ian Jackson2025-11-071-1/+1
| | | | | | | This has the meta attributes with optional values feature and also hygiene rework for modules. The breaking changes don't break arti.
* Merge branch 'deftly-1.4' into 'main'opara2025-11-061-1/+1
|\ | | | | | | | | Bump derive-deftly to 1.4.0 See merge request tpo/core/arti!3448
| * Bump derive-deftly to 1.4.0Ian Jackson2025-11-061-1/+1
| | | | | | | | | | | | This will let us use the new modules feature. There are no breaking changes to beta features in 1.4.0.
* | Fix name of clippy lint to unchecked_time_subtraction (2)Ian Jackson2025-11-0613-14/+14
|/ | | | Run maint/add_warning
* maint: bump minor versions of all published cratesSteven Engler2025-10-291-8/+8
| | | | | | | ```bash readarray -t publish < <(cargo metadata --format-version 1 | jq -r '.packages[] | select((.id | startswith("path+file:///")) and (.rust_version != null) and (.publish == null or .publish == true or .publish != [])) | .name') for package in "${publish[@]}"; do echo "$package:"; cargo set-version --bump minor -p "$package"; done ```
* Bump MSRV from 1.85.1 to 1.86Clara Engler2025-10-211-1/+1
|