GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(id): sign_upload refuses envelopes every backup store refuses by dezren39 · Pull Request #10916 · developing-today/code

Conversation

@dezren39

@dezren39 dezren39 commented Nov 17, 2026 •
edited by blacksmith-sh Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Before: sign_upload signed any envelope bytes. A malformed envelope (wrong length, bad magic, unsupported version, KDF or cipher id, out-of-range KDF parameters) got a valid signature, and every backup store then refused the upload, because BackupStore::upload runs validate_envelope before it looks at the signature.

After: sign_upload runs the same validate_envelope first and returns Result<[u8; 64], BackupError>, refusing with MalformedEnvelope and the rule that failed. Valid envelopes sign byte for byte as before.

How: one predicate, validate_envelope, now serves both the signer and the store, so they cannot drift. The epoch rules (StaleEpoch, Tombstoned) stay receipt-only, since they depend on the store's record. All callers were tests in backup.rs; receipt-side tests that need a signature over a malformed envelope use a test-only sign_upload_unchecked.

Testing: new sign_upload_refuses_malformed_envelopes_at_sign_time, and the malformed-header test now also checks the sign-time refusal. cargo test -p id --lib backup:: passes (17), clippy --all-targets --all-features and fmt are clean.

Fixes #8842


Generated by Claude Code


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@claude
fix(id): sign_upload refuses envelopes every backup store refuses
8691b97
BackupStore::upload runs validate_envelope before it checks the
signature, so a signature over a malformed envelope (bad length, magic,
version, KDF or cipher id, out-of-range KDF parameters) was useless:
signing reported success and every store refused the upload.
sign_upload now runs the same validate_envelope first and returns
Result, so the predicate is defined once and shared by signer and
store. Valid envelopes sign byte for byte as before; receipt and the
epoch rules are unchanged.

Fixes #8842

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@dezren39
dezren39 marked this pull request as ready for review November 17, 2026 02:46
@dezren39
dezren39 requested a review from a team as a code owner November 17, 2026 02:46
@dezren39
dezren39 merged commit fd6693d into main Nov 17, 2026
@coderabbitai

coderabbitai Bot commented Nov 17, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

Share

  • X
  • Mastodon
  • Reddit
  • LinkedIn
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39
dezren39 deleted the claude/backup-sign-validate branch November 17, 2026 02:46
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 17, 2026

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39 dezren39 mentioned this pull request Nov 17, 2026
id(backup): sign_upload signs envelopes every store refuses — mirror validate_envelope at sign time (gap from #6488) #8842
Closed
4 tasks
@dezren39 dezren39 added the audit:complete PR fully implemented spawning issue label Nov 24, 2026
This was referenced Nov 24, 2026
AUDIT-7 Lane 4 — MERGED-PR-AUDIT: merged PRs since 2026-10-23 vs their spawning issues #13879
Open
feat(id): server-side identity backup per #5033 decision (#7360) #7658
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

audit:complete PR fully implemented spawning issue

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

id(backup): sign_upload signs envelopes every store refuses — mirror validate_envelope at sign time (gap from #6488)

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@dezren39 @claude
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.