aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | Merge branch 'warn' into 'main'gabi-2502023-07-211-1/+1
|\ \ \ \ \ \ | |_|_|_|_|/ |/| | | | | | | | | | | | | | | | | tor-geoip: Fix a doc warning See merge request tpo/core/arti!1430
| * | | | | tor-geoip: Fix a doc warningIan Jackson2023-07-211-1/+1
|/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cargo doc --locked --document-private-items --workspace --all-features warning: unclosed HTML tag `CountryCode` --> crates/tor-geoip/src/lib.rs:90:54 | 90 | /// We store these as NonZeroU8 so that an Option<CountryCode> only has to | ^^^^^^^^^^^^^ | = note: `#[warn(rustdoc::invalid_html_tags)]` on by default
* | | | | Merge branch 'access2' into 'main'Ian Jackson2023-07-212-0/+7
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | tor-linkspec: impl AsRef<str> for PtTransportName See merge request tpo/core/arti!1426
| * | | | | tor-linkspec: impl AsRef<str> for PtTransportNameIan Jackson2023-07-202-0/+7
| |/ / / /
* | | | | Merge branch 'pwd-grp' into 'main'Nick Mathewson2023-07-202-33/+6
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Update pwd-grp to 0.1.1 to fix MacOS build etc. See merge request tpo/core/arti!1427
| * | | | | Update pwd-grp to 0.1.1 to fix MacOS build etc.Ian Jackson2023-07-202-33/+6
| |/ / / / | | | | | | | | | | | | | | | This also gets rid of a duplicate copy of derive-adhoc.
* | | | | Merge branch 'rlimit_up' into 'main'gabi-2502023-07-202-3/+3
|\ \ \ \ \ | |_|/ / / |/| | | | | | | | | | | | | | Bump requirement to rlimit 0.10.1 See merge request tpo/core/arti!1423
| * | | | Bump requirement to rlimit 0.10.1Nick Mathewson2023-07-202-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There was a bug in 0.10.0 that broke MacOS. Part of #963.
* | | | | Merge branch 'cc_niche' into 'main'Nick Mathewson2023-07-201-5/+37
|\ \ \ \ \ | |/ / / / |/| | | | | | | | | | | | | | geoip: Enable the niche optimization for CountryCode. See merge request tpo/core/arti!1384
| * | | | geoip: Use from_raw_parts instead of transmute.gabi-2502023-07-131-1/+5
| | | | |
| * | | | geoip: Enable the niche optimization for CountryCode.Nick Mathewson2023-07-071-5/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since we're going to be using `Option<CountryCode>` all over, let's save the extra byte. Sadly this required std::mem::transmute(), which is unsafe, so maybe we should think twice.
* | | | | Merge branch 'chanmgr_rustdoc_links' into 'main'gabi-2502023-07-191-2/+2
|\ \ \ \ \ | |_|_|_|/ |/| | | | | | | | | | | | | | Fix a pair of rustdoc links in chanmgr. See merge request tpo/core/arti!1419
| * | | | Fix a pair of rustdoc links in chanmgr.Nick Mathewson2023-07-191-2/+2
|/ / / /
* | | | Merge branch 'issue961_01' into 'main'Nick Mathewson2023-07-191-6/+3
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | geoip: Allow ASNs as zeros when creating NetDefn Closes #961 See merge request tpo/core/arti!1417
| * | | | geoip: Add derive macros to GeoipDbjuga2023-07-181-0/+1
| | | | | | | | | | | | | | | | | | | | to be able to debug it, for instance.
| * | | | geoip: Allow ASNs as zeros when creating NetDefnjuga2023-07-181-6/+2
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | so that GeoipDb can be created from files including ASNs generated with tor/scripts/maint/geoip/geoip-db-tool. Closes #961
* | | | Merge branch 'error' into 'main'Ian Jackson2023-07-1911-29/+105
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | Print sources for errors in RetryError Closes #958 See merge request tpo/core/arti!1416
| * | | tor-hsclient: Document API break.Ian Jackson2023-07-191-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This would be a break in higher-layer crates which incorproate this error but: 1. That's just arti-client which hides it behind the detailed errors cargo feature 2. I'm hoping cargo-semver-checks would spot it, anyway.
| * | | retry-error: Attempts must be AsRef<dyn Error>; print their sourcesIan Jackson2023-07-194-10/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The effect is that everywhere a RetryError is used, the error sources for the contained errors will be Display'd. In tor-hsclient we no longer need to explicitly wrap things up in tor_error::Report.
| * | | retry-error: Introduce a Wrapper type in a testIan Jackson2023-07-193-2/+16
| | | | | | | | | | | | | | | | | | | | We're going to require that a RetryError contains things that are AsRef<dyn Error> and ParseIntError isn't so we need a newtype.
| * | | retry-error: Provide fmt_error_with_sources in retry-errorIan Jackson2023-07-196-17/+69
| | | | | | | | | | | | | | | | | | | | This code came from tor-error. So now tor-error depends on retry-error.
| * | | tor-circmgr: impl AsRef<dyn std::error::Error> for some error typesIan Jackson2023-07-182-0/+4
|/ / / | | | | | | | | | We're about to want this.
* | | Merge branch 'lock' into 'main'gabi-2502023-07-181-3/+30
|\ \ \ | | | | | | | | | | | | | | | | Update Cargo.lock for d-a versions See merge request tpo/core/arti!1414
| * | | Update Cargo.lock for d-a versionsIan Jackson2023-07-181-3/+30
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | !1410 and !1412 had a semantic conflict *in the Cargo lockfile*! !1410 added a new indirect dependency on derive-adhoc, which is used in pwd-grp. pwd-grp is still declaring a dependency on d-a 0.6.1. (This ought to be updated there in due course, but isn't a bug.) !1412 updated our direct dependency on derive-adhoc to require 0.7.x. In fact, the breaking change 0.6.x to 0.7.x is minor and we could have written a more relaxed dependency.But cargo's syntax for that is very clumsy - here is an example from derive-adhoc iteself: itertools = ">=0.10.1, <0.12" Fix this for now in our tree with a `cargo update`, to unbreak main.
* | | Merge branch 'upgrades_20230717' into 'main'Alexander Færøy2023-07-174-34/+25
|\ \ \ | | | | | | | | | | | | | | | | Mid-month dependency upgrades See merge request tpo/core/arti!1412
| * | | Upgrade to latest derive-adhoc.Nick Mathewson2023-07-172-5/+5
| | | |
| * | | Upgrade to latest rlimit.Nick Mathewson2023-07-172-28/+19
| | | |
| * | | keymgr: Upgrade to latest itertools.Nick Mathewson2023-07-172-2/+2
| | | | | | | | | | | | | | | | (Everything else is already on 0.11.0.)
* | | | Merge branch 'no_longer_want' into 'main'Alexander Færøy2023-07-171-4/+0
|\| | | | |_|/ |/| | | | | | | | WANT_FROM_OTHER_CRATES: Remove note about async-rustls See merge request tpo/core/arti!1411
| * | WANT_FROM_OTHER_CRATES: Remove note about async-rustlsNick Mathewson2023-07-171-4/+0
| | |
* | | Merge branch 'pwd-grp' into 'main'gabi-2502023-07-178-134/+192
|\ \ \ | |/ / |/| | | | | | | | | | | | | | Replace use of unmaintained users crate with homegrown pwd-grp Closes #877 See merge request tpo/core/arti!1410
| * | cargo audit: un-ignore RUSTSEC-2023-0040 ("`users` is unmaintained"Ian Jackson2023-07-141-3/+0
| | |
| * | fs-mistrust: Run rustfmt to apply deferred formatting churnIan Jackson2023-07-141-10/+10
| | |
| * | fs-mistrust: In a test, simplify env var handlingIan Jackson2023-07-141-17/+10
| | |
| * | fs-mistrust: users: Use OsStr and OsString a lot lessIan Jackson2023-07-141-13/+23
| | | | | | | | | | | | | | | | | | | | | | | | We don't use OsString now except where it appears in our public API, or where we get it from std::env. Moving the `use` statements into the use sites enabled me to see that I had found all the places I wanted to change.
| * | fs-mistrust: Remove a now-unneeded suppressionIan Jackson2023-07-141-1/+0
| | | | | | | | | | | | This function is actually (properly) fallible now.
| * | fs-mistrust: forbid unsafe codeIan Jackson2023-07-141-0/+8
| | |
| * | fs-mistrust: Replace a direct libc call in a testIan Jackson2023-07-141-1/+1
| | |
| * | fs-mistruct: Abolish some now-unneeded mutsIan Jackson2023-07-141-26/+25
| | | | | | | | | | | | | | | MockPwdGrpProvider has internal mutability and is Sync, so its add functions take &self.
| * | fs-mistrust: Use pwd-grp's getgroups functionIan Jackson2023-07-141-24/+1
| | | | | | | | | | | | | | | This gets rid of some unsafe code here, with doubtful error handling, in favour of the unit-tested version in pwd-grp.
| * | fs-mistruct: switch from users to pwd-grpIan Jackson2023-07-143-53/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | users is unmaintained. pwd-grp is the crate I have just written to replace it. In this commit: Change the cargo dependency and imports. Replace the cacheing arrangements. users has a built-in cache; pwd-grp doesn't. Now, instead of cashing individual lookups, we cache the trusted user and trusted gid calculation results. This saves on some syscalls, and is also more convenient to write. (Mocking is still done via the dependency.) Many systematic consequential changes of details: * The entrypoint names to the library are different: pwd-grp uses the names of the corresponding Unix functions. * pwd-grp's returned structs are transparent, so we don't call accessors for .uid(), .name(), etc. * pwd-grp's methods are much more often fallible (returning io::Result<Option<...>) * We're using the non-UTF-8 pwd-grp API, which means we must use turbofish syntax in some places. * The mocking API is a bit different.
| * | fs-mistrust: Introduce tempoary PwdGrpProvider aliasIan Jackson2023-07-141-4/+8
| | | | | | | | | | | | | | | This allows us to change a number of trait bounds in advance, reducing noise in the next commit.
| * | fs-mistrust: impl Hash for TrustedUser and TrustedGroup (config)Ian Jackson2023-07-142-2/+3
| | |
| * | fs-mistrust: users: tests: Introduce mock_users etc.Ian Jackson2023-07-141-25/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add some wrapper functions for convenience. The pwd-grp crate has a richer and more faithful, but not so convenient, way of creating dummy user/group entries. Also the type names are all going to change. Doing this now reduces churn.
| * | fs-mistrust: users: Make several functions fallibleIan Jackson2023-07-142-26/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | The actual underlying operations here *are* fallible. The `users` crate hides those errors in several cases. (Failures are very rare (at least unless NIS is involved), so this is not of much practical import, but it's going to be necessary when we use the more careful pwd-grp crate.
* | | Merge branch 'keymgr-config-tweaks' into 'main'gabi-2502023-07-1713-178/+141
|\ \ \ | |/ / |/| | | | | | | | | | | | | | tor-keymgr config updates Closes #939 See merge request tpo/core/arti!1404
| * | arti-client: Add TODO about expanding the keystore_dir in build().Gabriela Moldovan2023-07-171-0/+2
| | |
| * | arti-client: Log whether a keystore is in use.Gabriela Moldovan2023-07-131-1/+4
| | |
| * | tor-config: Remove unused ItemOrBool helper.Gabriela Moldovan2023-07-132-63/+1
| | | | | | | | | | | | | | | `ItemOrBool` is currently not used anywhere (it was previously used by the keymgr config).
| * | arti cfg tests: Add keystore to example config.Gabriela Moldovan2023-07-132-14/+22
| | | | | | | | | | | | Closes #939