Repository navigation
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The repo was transferred from
Trust-Machines/wststoxoloki/wsts, but nothing inside it reflected that. Crate metadata, badges, documentation links and the security policy all still named the old orgs, and three of those links were simply dead:stacks-sbtc.github.io/wsts/wstsand/wsts.pdfboth 404, andtmurl.netno longer resolves at all.This matters more than tidiness, for two reasons.
README.mdis inlined as the crate's rustdoc front page via#![doc = include_str!("../README.md")], so every stale link here is also on docs.rs. And crates.io metadata is immutable per version, so whateverrepositorysays when15.0.0is published is what it says forever — which is why this lands before the release tag.There is also a deadline. The
Trust-Machines/wstsredirect is load-bearing, and GitHub rename redirects break permanently the moment anyone creates a repo at the old name. The Trust-Machines org still exists.Metadata
repositorynow points atxoloki/wsts, withhomepage = "https://wsts.xyz"anddocumentation = "https://wsts.xyz/wsts"added — both were unset on crates.io.Added
excludefor repo scaffolding that served no purpose inside the published archive. Combined with dropping the binary below, this takes the published crate from 41 files to 30:.github/,.doc/,CNAME,coverage.shandrust-toolchain.tomlno longer ship.README.mdis deliberately not excluded, since bothreadmeand theinclude_str!need it.Added
[package.metadata.docs.rs] all-features = trueso docs.rs coverage is intentional rather than incidental, matching the site change below.Dropped
primitive-types— it was a direct dependency with zero references anywhere insrc/orbenches/. It remains in the lockfile as a transitive dependency ofp256k1, which is correct; it just isn't ours to declare.Documentation and prose
tmurl.netlink behind the project name, and both documentation links now point atxoloki/wstsandwsts.xyz.USAGE.mdaudit-issue links re-pointed. The issue numbers still resolve: CR-01 Missing Inbound Messages Authentication #66 (CR-01) and CR-02 Authorization Logic Missing in Critical Functions #67 (CR-02) came across with the transfer.wsts.texself-citation re-pointed, and the bibitem key renamed fromtmfrost(the "TM" being Trust Machines) towstsimpl.USAGE.mdusedwsts::v1::Signer, which does not compile without--features with_v1, and referenced four undefined bindings. Rewritten againstv2with every binding defined, plus a note about thewith_v1gate.The safety notice
The old notice said this crate is "only considered safe to use in the specific configuration, parameterization, and protocol flow in which it is used by the sBTC system." That is no longer true in a way that matters: sBTC does not consume this crate. It vendored
wsts14.0.0 into its own tree in sbtc#1938 (2026-03-02) and the two have diverged in both directions since.As written, the notice invited readers to transfer sBTC's audit and operational history onto a tree sBTC has never run. The replacement states the history, then says plainly that it does not describe this code and that neither tree's history transfers to the other.
Supporting detail, since this is a security-relevant claim: sbtc's root
Cargo.tomlhaswsts = { path = "./wsts" };sbtc/wsts/Cargo.tomlisversion = "14.0.0"with onlydefault/with_p256k1_bindgen; commits3f2cf538,531f870fanda950bff6stripv1, the bitcoin helpers, the binary and the benches; andbbf92c81(sbtc#1968) reworked polynomial-commitment validation by introducing aPublicPolynomialnewtype andCommonError::InvalidPolynomialacross 10 files — none of which exist here. Meanwhile this crate fixed the same class of bug differently in #224, which their copy does not have.Replacing the bare URL with a markdown link also clears the
rustdoc::bare_urlswarning that fired fromREADME.md:3on every single doc build.Security policy
SECURITY.mdwas three lines delegating the entire policy to sBTC's repo — no contact, no supported-versions statement, nothing actionable. Rewritten with: GitHub private vulnerability reporting as the primary channel, email as an explicit fallback for anyone who will not use GitHub or wants to negotiate encryption first, latest-release-only support, and a section routing sBTC reports to sBTC.No PGP key, deliberately. An unused key is a liability rather than an asset — expired, secret half lost, no revocation published — and it fails exactly when someone is trying to report a live bug in a signing library.
The disclosure section states that a GHSA is followed by a companion advisory against
rustsec/advisory-db. Those are separate databases andcargo auditandcargo denyread RustSec, not GitHub, so publishing only a GHSA would leave Rust consumers unwarned.Build scripts
.doc/build.shand.doc/install-latex-ubuntu.shhad no shebang and no error handling, and both workflows invoke them directly — so they ran under/bin/shand apdflatexorcargo docfailure left the step green while publishing an incomplete site. Both now have#!/usr/bin/env bashandset -euo pipefail,pdflatexgets-halt-on-error, andapt-get installgets--yes(now mandatory, sinceset -ewould otherwise turn the interactive prompt into a hard failure).cargo docinbuild.shnow runs--all-features. It was building default features only, which is whywsts.xyz/wsts/v1/currently 404s whiledocs.rs/wsts/14.0.2/wsts/v1/resolves fine. Also addedRUSTDOCFLAGS="-D warnings", sinceRUSTFLAGSdoes not reach rustdoc and broken intra-doc links were going uncaught — which matters in a PR that rewrites this much doc text. Verified clean.Deleted
.doc/cloudflare.sh: every functional line was already commented out and nothing referenced it.Code hygiene
No behaviour change. Test counts are unchanged at 88 and 164.
Deleted
src/main.rsand its[[bin]]target. 103 lines of DKG/sign timing demo, duplicating whatbenches/already does with criterion, and holding 17 panic sites — the highest density in the crate.Removed three stale
#[allow(dead_code)]:src/util.rs(hash_to_scalarispubin apub mod, so it can never be dead code, and it is used in five modules) and two infire.rswhose_v2callers directly above them are already un-gated. The three infrost.rsandsigner/mod.rsare not stale and are deliberately left alone — their only callers arewith_v1-gated, so they belong with the test fixes in the next PR.Deleted 12 lines of commented-out code from
taproot.rsandsigner/mod.rs.Doc defects:
lib.rscarried a verbatim copy ofv1's doc comment abovepub mod v2and a "using"/"used" typo onvss;errors.rshad")]"leaking from#[error(...)]into two doc comments, and aFromimpl sitting in the middle of theAggregatorErrorsection, above the type it converts into;v2.rs'sDebugimpl printed the field as"part_id";coordinator/mod.rshad "Retrive"; andstate_machine/mod.rsdescribed the module as "a simple FROST coordinator" when it has hosted both FROST and FIRE for some time.Lockfile
Cargo.lockis now committed and CI builds with--locked. With both a floating lockfile and (until #230) a floating toolchain, CI had two independent ways to turn red without a code change. It also pins a real surprise:Cargo.tomlasks forpolynomial = "0.2.5"but resolution picks0.2.6, which raised its ownrust-versionto 1.70.Also dropped
-A clippy::op-ref -A clippy::needless-range-loopfrom the clippy job. Those duplicated the four#[allow(clippy::op_ref)]insrc/lib.rs, and clippy is verified clean with no-Aflags at all, so localcargo clippynow matches CI exactly.Dropped from this PR: the MSRV declaration
The plan called for
rust-version = "1.80.0"plus an MSRV CI job. Both are omitted, because 1.80.0 is not achievable and nothing below 1.85 is even testable. Installing 1.80.0 and runningcargo check --all-features --lockedfails before compiling anything:Scanning every manifest in the resolved graph, the true floor is 1.88 —
home 0.5.12declaresrust-version = "1.88"— with 11 edition-2024 packages requiring Cargo >= 1.85 (clap,getrandom,hashbrown,indexmap,zeroize, thetoml_*family,home).All of it is dev and build tooling:
homearrives viawhich/toolchain_find,clapvia criterion. So the library's own floor really is around 1.80 (std::sync::LazyLockinsrc/btc.rssets it), but that number is untestable and therefore undeclarable, because resolution drags dev-dependencies through the same manifest parse. Declaring 1.80.0 would be a verifiable falsehood.Making a meaningful MSRV claim means pinning those transitive deps to pre-edition-2024 versions in the lockfile and deciding whether dev-dependencies should constrain a published library's MSRV at all. That is its own piece of work with its own tradeoffs, so it is filed as a follow-up rather than smuggled in here.
Not done: the copyright line
README.mdstill readsCopyright 2022-2024, Nassau Machines Inc, held deliberately pending Trust-Machines' answer on what they want done with it. It is the only old-org reference left in the repo — verified by sweeping forTrust-Machines,tmurl,Nassauandstacks-sbtc.github.ioacross everything buttarget/andCargo.lock.Verification
Under the pinned 1.97.1:
cargo fmt --all -- --check— cleancargo clippy --all-targets --all-features -- -D warnings— exit 0, zero diagnostics, with no-Aflagscargo check --locked— clean, confirming the lockfile matches the manifest after droppingprimitive-typescargo test --locked— 88 passedcargo test --locked --features with_v1— 164 passedcargo build --all-features— cleanRUSTDOCFLAGS="-D warnings" cargo doc --no-deps --all-features— exit 0, zero diagnostics; thebare_urlswarning is gonecargo publish --dry-run --locked— packages and verify-builds clean, 30 filesbash -non both.docscriptsThe LaTeX half of
build.shcannot be checked locally (pdflatexis unavailable; the installer is Ubuntu-only), so thedocjob is the real test of-halt-on-errorand the--all-featuresrustdoc build.🤖 Generated with Claude Code