Skip to content

sign the payload, not just the identifier (SFT-8090) - #2

Draft
max-lt wants to merge 1 commit into
mainfrom
SFT-8090-sign-the-payload
Draft

max-lt wants to merge 1 commit into
mainfrom
SFT-8090-sign-the-payload

Conversation

@max-lt

@max-lt max-lt commented Sep 10, 2026

Copy link
Copy Markdown

The signed message was post:{hash}:{timestamp}, so a captured request replayed with any payload. It becomes post2:{hash}:{timestamp}:{sha256}:{length}.

prepare_post_backup now takes the ciphertext rather than its hex, so the signed digest cannot disagree with what the request carries. post_message is public because backup-server repeats the same string, and both sides pin it in a test.

Undraft once https://github.com/Foundation-Devices/backup-server/pull/8 is merged and deployed

The signed message was post:{hash}:{timestamp}, so a captured request replayed with any payload. It becomes post2:{hash}:{timestamp}:{sha256}:{length}.

prepare_post_backup now takes the ciphertext rather than its hex, so the signed digest cannot disagree with what the request carries. post_message is public because backup-server repeats the same string, and both sides pin it in a test.

The request carries the new signature alone. The server takes exactly one, so it ships before this.
@max-lt
max-lt requested a review from InvertedX September 10, 2026 12:04
@max-lt max-lt self-assigned this Sep 10, 2026
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.

1 participant