Skip to content

chore: sync upstream SecretSpec 0.21.1 post-release work and security fixes - #100

Merged
ifiokjr merged 8 commits into
mainfrom
chore/sync-upstream-post-0-21-1
Oct 24, 2026
Merged

ifiokjr merged 8 commits into
mainfrom
chore/sync-upstream-post-0-21-1

Conversation

@ifiokjr

@ifiokjr ifiokjr commented Oct 24, 2026

Copy link
Copy Markdown
Owner

What

Bundles the full upstream sync that was sitting uncommitted in the working tree (a port of cachix/secretspec b3a29191..50ff51e8, documented per-path in sync-report.txt), rebased onto current main, plus the three substantive upstream commits after that cutoff, a missed C-side wire fix the conformance suite caught, and dependency advisory bumps.

Upstream sync (b3a29191..50ff51e8)

Follow-up ports after the cutoff

Security audit and dependency advisories

A full security audit ran against this tree (exec wrappers, secret lifetime/zeroization, dotenv/file write paths, IPC daemon, HTTP layer, npm wrappers, workflows, C resolver). Findings acted on here:

  • restored the wire_integer module and MAX_JSON_INTEGER declarations a rebase dropped from monosecret_rpc's crate root (the integer-bounds hardening was unbuildable without it)
  • cargo audit advisories fixed where releases exist: rustls 0.23.46 (secret-exposing Debug impls, KEX downgrade), rustls-webpki 0.103.16 (distrusted-intermediate acceptance), webpki-root-certs 1.0.11 (emSign distrust). The legacy rustls 0.21 chain pinned under the AWS SDK stack and the unfixed rsa Marvin advisory remain as accepted risk; the zip advisories are stale unreachable lock entries.

Not ported, deliberately: the Elixir SDK and python-wheels CI/docs commits (the fork carries no Elixir package; workflows are fork-managed).

Testing

  • cargo test -p monosecret -p monosecret_rpc -p monosecret-rpc-conformance — all green, including the new check_leaves_no_as_path_files_behind, get_keeps_the_as_path_file_it_prints, and the protonpass field-ref tests
  • client-additive-initialize conformance case now passes against both the C and Rust clients
  • cargo clippy clean, dprint check clean (this PR also fixes the local-only broken dartfmt dprint exec command that made every local commit fail the format hook)
  • Commits are signed and verify

Created on behalf of Ifiok Jr. (@ifiokjr), generated with GLM-5.3 at high thinking level.

…ff51e)

Port the upstream post-0.21.1 changes into the fork:

- retry transient provider failures (cachix#478) with RetryPolicy plumbing
- credential generators and X.509 identities (cachix#483)
- preserve encoded X.509 identities on text writes (cachix#493)
- profile selection for import (cachix#494)
- redact ResolvedSecret values in Debug output (cachix#470)
- bound v1 JSON integers for portable clients (cachix#467)
- accept additive v1 response fields (cachix#466)
- add schema directive to generated manifest (cachix#465)
- warn about ignored unknown fields in secret declarations (cachix#485)
- make block_on safe inside current-thread runtimes (cachix#468)
- accept additive v1 initialize result members in resolver-c (cachix#471)
- install fake provider CLIs without holding a write descriptor (cachix#479)

sync-report.txt documents the per-path port status.

Also fix the local dprint dart exec command to run dart format in
stdin mode (the exec plugin contract); the dartfmt wrapper never
drained stdin so every local dprint run over dart files failed with
a broken pipe. CI never noticed because the lint job runs dart
format directly. Two dart files local dprint could never reach are
formatted as part of this.
- fix(check): stop persisting as_path temp files (upstream cachix#469,
  123cdfb): check never prints the paths, so decrypted secrets
  accumulated in the temp directory; they now drop with the command.
  Regression tests pin get/export persistence and check cleanup.
- fix(kdbx): keepass 0.13.17 -> 0.13.21 for correct DeletionTime
  serialization (upstream cachix#498, bd45207).
- feat(protonpass): read item fields through `field` refs (upstream
  cachix#500, 12fe45b); field refs stay read-only because pass-cli only
  accepts field values as command-line arguments, which would expose
  them in the process list.
- fix(ipc): port the missed C half of additive v1 initialize results
  (upstream cachix#471, 16cd582): requests stay strict, results tolerate
  unknown members. Caught by the client-additive-initialize conformance
  case the sync ported.
- restore the wire_integer module and MAX_JSON_INTEGER declarations the
  rebase dropped from monosecret_rpc's crate root.
- chore(deps): rustls 0.23.46, rustls-webpki 0.103.16,
  webpki-root-certs 1.0.11 for RUSTSEC advisories (secret-exposing
  Debug impls, KEX downgrade, distrusted intermediates, emSign
  distrust).
The sync pointed @monosecret/cli's optional platform dependencies at
workspace:* but left pnpm-lock.yaml at the 0.4.4 specifiers, so every
CI job's frozen-lockfile install failed during setup.
- pulumi standalone feature: name dep:http like every other reqwest
  feature; the shared response buffering in provider/http.rs builds an
  ::http::Response, so --no-default-features --features pulumi failed.
- docs: port the VersionCompatibility marker as a local component for
  the mdx pages and as plain markdown (badge notes and Changed-in
  callouts) for the md pages, which cannot use components; upstream
  left a stray closing tag behind the extraction section, now a proper
  callout. Upstream 0.22 version markers map to the fork's 0.5.0.
vercel.rs reads its team ID through preferred_env, but the re-export
was gated on cloudflare/openbao/scaleway/vault only, so a standalone
--features vercel check failed to find it. The full standalone feature
matrix now passes locally.
The port bounded response integers to the 2^53-1 range every v1 JSON
peer can represent, but the checked-in IPC schemas still advertised
u64::MAX maximums. The discover document embeds those schemas verbatim,
so its own response failed the new integer validation and degraded to
an internal error — the wire.notifications conformance case caught it
because it is the first case to call rpc.discover. Clamp the schema
maximums to 9007199254740991, matching upstream.
The rebase onto main replayed only the sync diff, so rpc and C files
that an earlier partial port had already carried but the sync commit
itself never touched fell back to their pre-port versions:

- error.rs: the wire-integer serde bounds on InteractionReference and
  ErrorData, and the tolerant (additive) error parsing from upstream
  7a2502c — the ported integer_bounds tests failed without them
- internal.h, json.c, fake_peer.c, regressions.c in the C resolver
- the dead root test crate stays deleted; the shell fixtures the bw
  tests include_str! are kept
- the canonical root schema/ copies now match the clamped crate copies,
  including the missing cleared maximum the schema-agreement test
  checks
The fork's packaging check requires npm manifests to reference the
platform packages by publishable exact versions: registry clients
cannot resolve workspace: protocols, and monochange rewrites the pins
on release through monochange.toml's versioned_files entries. The sync
port had adopted upstream's workspace:* style, which the policy rejects.
@codecov-commenter

codecov-commenter commented Oct 24, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 24.07681% with 2570 lines in your changes missing coverage. Please review.
✅ Project coverage is 35.41%. Comparing base (22c0434) to head (aa9c1c2).

Files with missing lines Patch % Lines
crates/monosecret/src/config.rs 18.14% 415 Missing ⚠️
crates/monosecret/src/x509_identity.rs 0.00% 403 Missing ⚠️
crates/monosecret/src/secrets.rs 34.36% 319 Missing ⚠️
crates/monosecret/src/generator.rs 0.00% 253 Missing ⚠️
crates/monosecret/src/provider/http.rs 0.00% 191 Missing ⚠️
crates/monosecret/src/spec.rs 0.00% 167 Missing ⚠️
crates/monosecret/src/provider/retry.rs 70.85% 109 Missing ⚠️
crates/monosecret/src/typed.rs 3.44% 84 Missing ⚠️
crates/monosecret/src/provider/protonpass.rs 0.00% 63 Missing ⚠️
crates/monosecret/src/provider/scaleway.rs 0.00% 58 Missing ⚠️
... and 31 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #100      +/-   ##
==========================================
+ Coverage   35.18%   35.41%   +0.23%     
==========================================
  Files         117      121       +4     
  Lines       38697    41516    +2819     
  Branches       49       49              
==========================================
+ Hits        13614    14703    +1089     
- Misses      25074    26804    +1730     
  Partials        9        9              
Flag Coverage Δ
crate-monosecret 34.81% <24.07%> (+0.28%) ⬆️
crate-monosecret-derive 34.81% <24.07%> (+0.28%) ⬆️
dart 94.50% <ø> (ø)
dart-monosecret 89.33% <ø> (ø)
dart-monosecret-builder 100.00% <ø> (ø)
npm 27.74% <ø> (ø)
npm-monosecret-client 27.74% <ø> (ø)
rust 34.81% <24.07%> (+0.28%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
crates/monosecret/src/compiled_spec.rs 94.82% <100.00%> (+1.49%) ⬆️
crates/monosecret/src/provider/bws.rs 55.20% <100.00%> (+55.20%) ⬆️
crates/monosecret/src/provider/ejson.rs 0.00% <ø> (ø)
crates/monosecret/src/provider/fly.rs 0.00% <ø> (ø)
crates/monosecret/src/provider/passbolt.rs 0.00% <ø> (ø)
crates/monosecret/src/provider/registry.rs 62.96% <ø> (+11.11%) ⬆️
crates/monosecret/src/resolve.rs 47.87% <ø> (ø)
crates/monosecret_rpc/src/blocking.rs 84.27% <ø> (-1.27%) ⬇️
crates/monosecret_rpc/src/deadline.rs 100.00% <100.00%> (ø)
crates/monosecret_rpc/src/error.rs 76.73% <ø> (+2.97%) ⬆️
... and 42 more

... and 6 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ifiokjr
ifiokjr merged commit f75f46a into main Oct 24, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants