build: select iroh TLS backend explicitly (tls-aws-lc-rs) instead of defaults - #1141
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (5)
🚧 Files skipped from review as they are similar to previous changes (5)
📝 WalkthroughWalkthroughThe five mesh crates now configure Changesiroh feature configuration
Estimated code review effort: 1 (Trivial) | ~5 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Thanks for your first contribution! I'll get this reviewed. |
i386
left a comment
There was a problem hiding this comment.
Approved — the explicit features match iroh 1.0.0's defaults, with only tls-ring replaced by tls-aws-lc-rs. No issues found.
|
@michaelneale Net effect: iroh will use AWS-LC-RS rather than |
…defaults The five crates that depend on iroh declared it as a bare `iroh = "1.0.0"`, which enables iroh's default features — including `tls-ring`. Because cargo features are additive and iroh prefers ring when both TLS backends are compiled in, this makes it impossible for any downstream consumer to build a mesh-llm-enabled binary without ring in the dependency graph. That matters for FIPS 140-3 deployments: ring is not FIPS-validated, while aws-lc-rs has a validated mode. Any embedder that must keep its crypto on a single validated module (e.g. via rustls' aws-lc-rs provider) currently has to patch iroh itself to strip ring out. This change declares the iroh dependency with `default-features = false` and the same explicit feature set as before, swapping `tls-ring` for `tls-aws-lc-rs`: - behavior is unchanged (iroh supports both backends equivalently) - downstream embedders get a single-TLS-backend graph for free - dev-dependencies are left untouched (they don't propagate to consumers) If you'd rather keep ring as the project default, the alternative is plumbing passthrough `tls-ring`/`tls-aws-lc-rs` features through every crate between the SDK surface and iroh — happy to rework the PR that way, but this is the minimal-diff version. Signed-off-by: Miguel Amador <home@amador.one>
e4c839c to
de24ffd
Compare
What
Declares the
irohdependency explicitly in the five crates that use it (mesh-llm-protocol,mesh-llm-routing,mesh-client,mesh-llm-commands,mesh-llm-host-runtime), replacing the bareiroh = "1.0.0"withdefault-features = falseplus the same feature set iroh's defaults enable today — excepttls-ring, which is swapped fortls-aws-lc-rs.Why
Cargo features are additive: a bare
iroh = "1.0.0"enables iroh'sdefaultfeature, which includestls-ring, and no downstream consumer can subtract it. When both TLS backends are compiled in, iroh prefers ring — so any embedder of the mesh-llm SDK ships ring in its binary no matter what it does in its own manifest.For deployments that need FIPS 140-3 alignment this is a hard blocker: ring is not FIPS-validated, while aws-lc-rs has a validated mode and is what rustls' FIPS story is built on. Today the only workaround is
[patch.crates-io]-ing iroh itself to redefine its defaults, which every embedder has to carry independently.With this change the resolved graph (normal deps) becomes:
— no
default, notls-ring.Notes
mesh-llm-host-runtime'siroh/iroh-relaytest deps) — they don't propagate to consumers.cargo tree -e normal,features -i iroh(output above) andcargo checkon all five crates.tls-ring/tls-aws-lc-rsfeatures plumbed through every crate between the SDK surface and iroh. That's a much larger diff; happy to rework this PR that way if you want backend choice rather than a swap.Summary by CodeRabbit