summaryrefslogtreecommitdiff
path: root/crates/tor-hsservice/src
Commit message (Collapse)AuthorAgeFilesLines
* hsclient, hsservice: Remove no longer needed conversion functionsGabriela Moldovan2026-01-061-58/+0
|
* keymgr: Use d-d to generate CTorPath<->KeySpecifier conversionsGabriela Moldovan2026-01-061-2/+2
|
* keymgr: Make CTorPath more like the client/service specifiers (fmt)Gabriela Moldovan2026-01-061-6/+2
|
* keymgr: Make CTorPath more like the client/service specifiersGabriela Moldovan2026-01-061-9/+5
| | | | | | | | | | | | | This will make it easier to see the correspondence between CTorPaths and the HS client/service key specifiers. Initially, I was hoping this would make it easier to write a d-d macro that automatically derives a `CTorPath` variant (e.g. `HsClientDescEncKeypair`) from the KeySpecifier type name (`HsClientDescEncKeypairSpecifier`), but alas, I don't think d-d can "chop off" name suffixes ("Specifier", in this case). `from_ctor_path()`/`ctor_path()` implementations for converting `CTorPath`s to and from key specifiers.
* keymgr: Push error handling into the from_ctor_path() functionsGabriela Moldovan2026-01-061-8/+16
|
* keymgr: Remove redundant ArtiPath from error context (fmt)Gabriela Moldovan2026-01-061-4/+2
|
* keymgr: Remove redundant ArtiPath from error contextGabriela Moldovan2026-01-061-5/+3
| | | | | The `ArtiPath` is included in the `KeyPathError::Arti` outer error type, so there is no need to include it in `ArtiPathError` too.
* keymgr: Split out ArtiPathError from KeyPathError (fmt)Gabriela Moldovan2026-01-061-16/+19
|
* keymgr: Split out ArtiPathError from KeyPathErrorGabriela Moldovan2026-01-061-7/+12
| | | | | This makes the error handling around `KeyPath`s a bit more sensible, IMO, and it will make it easier to extend it for `CTorPath` errors.
* keymgr: Specify ctor conversion functions as moduleGabriela Moldovan2026-01-061-42/+46
| | | | | | | This is similar to `#[serde(with = "...")]`, and feels a bit nicer than having to specify two separate functions for the conversions (because with two separate functions, you *can* technically only specify one of them, which shouldn't be allowed).
* keymgr: Extend KeySpecifier macro to support CTorPath conversionsGabriela Moldovan2026-01-061-2/+38
| | | | | This enables us to implement `KeyMgr::describe()`, which relies on the ability to extract the key specifier of the key from its `KeyPath`.
* fix: use wallclock timestamps in all push_timed callsNihal2025-12-171-1/+8
|
* refactor: convert Extend to inherent method, forbid push/extend, fix ↵Nihal2025-12-171-1/+11
| | | | rend_handshake time
* refactor: clean codeNihal2025-12-172-2/+2
|
* feat(retry-error): add timestamps to retry errorsNihal2025-12-172-2/+2
|
* Refactor common code that builds circtargets for HS.Nick Mathewson2025-12-042-63/+35
| | | | | | | | | This code was duplicated across hsclient and hsservice. Logically, it belongs in netdir, since that's where we have the latest required-protocol information, and the ability to look up relays by IDs. Closes #1223
* tor-hsservice: make `build_unvalidated()` privateSteven Engler2025-11-261-1/+1
|
* Merge branch 'intro-dos' into 'main'gabi-2502025-11-251-1/+1
|\ | | | | | | | | arti: Add rate_limit_at_intro to the example config See merge request tpo/core/arti!3493
| * hsservice: Fix typo in rate_limit_at_intro docsGabriela Moldovan2025-11-251-1/+1
| |
* | Merge branch 'max-concurrent-streams' into 'main'Nick Mathewson2025-11-251-0/+5
|\ \ | |/ |/| | | | | hsservice: Clarify what max_concurrent_streams_per_circuit does See merge request tpo/core/arti!3492
| * hsservice: Clarify what max_concurrent_streams_per_circuit doesGabriela Moldovan2025-11-251-0/+5
| | | | | | | | | | | | | | At first glance, this might seem equivalent to C Tor's `HiddenServiceMaxStreams` option, but it's actually `HiddenServiceMaxStreamsCloseCircuit` (Arti doesn't implement the former).
* | opentelemetry: Instrument a bunch of functions.Wesley Aptekar-Cassels2025-11-242-0/+6
|/ | | | | These are all aimed at figuring out in more detail what's going on in #2079 and related issues.
* Merge branch 'disable-hidden-service' into 'main'wesleyac2025-11-122-2/+17
|\ | | | | | | | | | | | | arti/arti-client/tor-hsservice: Support disabling onion services in the config Closes #2133 See merge request tpo/core/arti!3253
| * arti(-client)/tor-hsservice: return None for disabled servicehashcatHitman2025-10-162-9/+5
| | | | | | | | | | | | | | | | | | | | There is no longer a hard error anywhere for trying to launch a service which is disabled in the config. Instead, it always means returning `Ok(None)`. The axum and hyper examples were updated again as a consequence. Signed-off-by: hashcatHitman <[email protected]>
| * arti/tor-hsservice: don't warn on autostarthashcatHitman2025-10-162-13/+4
| | | | | | | | | | | | | | The "enabled" config option is back to using a regular `bool`. When unset, it defaults to true, and the service runs as if it had been set. Signed-off-by: hashcatHitman <[email protected]>
| * tor-hsservice: TODO - allow changing "enabled"hashcatHitman2025-10-161-0/+2
| | | | | | | | | | | | | | | | As requested in the review, there's a TODO now so we can come back some day and allow onion services to be started/stopped while the client is running. Signed-off-by: hashcatHitman <[email protected]>
| * arti/tor-hsservice: warn on service autostarthashcatHitman2025-10-162-4/+13
| | | | | | | | | | | | | | The "enabled" config option now uses `tor_config::BoolOrAuto`. When unset (which defaults to "Auto"), the service will run with a warning. Signed-off-by: hashcatHitman <[email protected]>
| * tor-hsservice: add config to disable servicehashcatHitman2025-10-163-0/+17
| | | | | | | | | | | | | | | | | | Added the `enabled` field to the config options for hidden services. The default is `true`. If it is set to `false`, the service won't start. As of this specific commit, it's a hard error; it'll be checked again at an earlier stage where it won't be once the feature is ready. Signed-off-by: hashcatHitman <[email protected]>
* | Fix name of clippy lint to unchecked_time_subtraction (2)Ian Jackson2025-11-0613-14/+14
| | | | | | | | Run maint/add_warning
* | all: run cargo fmtSteven Engler2025-11-041-1/+1
| |
* | all: replace all uses of `futures::task::SpawnExt` with `tor_rtcompat::SpawnExt`Steven Engler2025-11-043-3/+4
| |
* | proto: Replace ClientCircSyncView in IncomingStreamRequestFilterGabriela Moldovan2025-10-301-1/+1
|/
* Fix new clippy nightly warning about subtracting Durations.Nick Mathewson2025-10-161-7/+11
|
* Merge branch 'file-too-large' into 'main'wesleyac2025-10-061-3/+2
|\ | | | | | | | | tor-hsservice: Replace `libc::EFBIG` with `io::ErrorKind::FileTooLarge` See merge request tpo/core/arti!3218
| * tor-hsservice: Replace `libc::EFBIG` with `io::ErrorKind::FileTooLarge`hashcatHitman2025-09-011-2/+1
| | | | | | | | | | | | | | | | Resolved an MSRV TODO. We used `libc::EFBIG` previously because `io::ErrorKind::FileTooLarge` was still unstable. It has since stabilized and entered our MSRV (>= 1.83.0). Signed-off-by: hashcatHitman <[email protected]>
| * tor-hsservice: Small typo correctionhashcatHitman2025-09-011-1/+1
| | | | | | | | | | | | | | Unless this is a pun, I'm pretty sure this is supposed to be `EFBIG` and not `EFBUG`. Signed-off-by: hashcatHitman <[email protected]>
* | tor-hsservice: Fix time_store test.Wesley Aptekar-Cassels2025-10-011-1/+0
| | | | | | | | | | | | | | | | This behaviour was changed in humantime 2.3.0. Because they made this breaking change on a minor semver bump, if we want to depend on this behaviour, we would need to lock to a specific version. I don't think this is critical, but I am still looking into where exactly this is used.
* | Remove "doc_auto_cfg" incantation from all crates.Nick Mathewson2025-09-291-1/+1
| | | | | | | | This feature has been removed from nightly, in favor of doc_cfg.
* | hsservice: Remove misleading OnionService note.Gabriela Moldovan2025-09-121-1/+1
| | | | | | | | | | | | | | | | An `OnionService` represents a not-yet-running service. To launch it, you have to call `OnionService::launch()`, which consumes the `OnionService` and returns `RunningOnionService`, so the part of the docs saying that an `OnionService` "may or may not be running" was somewhat misleading.
* | hsservice: Say how a RunningOnionService is constructed.Gabriela Moldovan2025-09-121-1/+3
| | | | | | | | | | | | | | This adds some extra docs to `RunningOnionService`. This also removes the TODO about #1228, because that ticket was closed in !1945.
* | hsservice: Remove an already-addressed TODO.Gabriela Moldovan2025-09-121-1/+0
| | | | | | | | In #1247 we decided to stick with the current names.
* | arti: keys: Add `keys check-integrity` CLI toolhjrgrn2025-09-042-42/+76
| |
* | Merge branch 'the-bell-tolls-for-once_cell' into 'main'wesleyac2025-09-031-7/+1
|\ \ | |/ |/| | | | | various crates: Updated MSRV TODOs for `once_cell` removal See merge request tpo/core/arti!2953
| * tor-hsservice: Modified MSRV TODO for `once_cell` removalhashcatHitman2025-08-201-7/+1
| | | | | | | | | | | | | | | | | | - Shortened the TODO added in cad6f9054a5ff4d16e953fd4617d3893639deeef in the style of [this maintainer request] for consistency. [this maintainer request]: https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2953#note_3197719 Signed-off-by: hashcatHitman <[email protected]>
* | proto: Add a circuit module shared between client and relay impls.Gabriela Moldovan2025-08-281-2/+2
| | | | | | | | | | | | | | This is just code motion (I suggest reviewing with `--color-moved`). This also moves the implementation-agnostic parts from `tor_proto::client::circuit` to a new `tor_proto::circuit` module.
* | hsservice: Move derive_more::From out of internal_prelude.Nick Mathewson2025-08-194-1/+4
|/ | | | | | | | | | | | | | This fixes an error from nightly. The trouble is that with nightly, there's a now a [derive macro for From][issue]. That doesn't cause a conflict when we `use derive_more::From`, but it _does_ cause a conflict when we import `derive_more::From` via `use internal_prelude::*`. So as a solution, we just import `derive_more::From` explicitly. Closes #2124 [issue]: https://github.com/rust-lang/rust/pull/144922
* misc: cleanup now that `_report!` macros support fieldsSteven Engler2025-08-181-1/+1
|
* Merge branch 'relay-reactor-placeholder' into 'main'David Goulet2025-08-184-9/+9
|\ | | | | | | | | proto: Add a placeholder for the relay reactor. See merge request tpo/core/arti!3162
| * proto: Move the `stream` module under `client` (breaking).Gabriela Moldovan2025-08-184-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | The `stream` module is client-specific, for the most part, so I am moving it under `client`. Later on, we will factor out the parts that can be shared with the relay implementation. Note: this is a breaking change as the deleted `stream` module was `pub`. We could've kept the module and reexported from it the public types from `tor_proto::client::stream`, but I think it's better to have this `client` namespacing, because it makes the separation between the client and relay parts clearer.
* | Merge branch 'fix-nightly-warn' into 'main'Nick Mathewson2025-08-181-2/+0
|\ \ | | | | | | | | | | | | Fix clippy errors on nightly See merge request tpo/core/arti!3148