Skip to content

fix: reject corrupted attachment stream decrypts#92

Open
Ap4sh wants to merge 1 commit into
session-foundation:devfrom
Ap4sh:fix-attachment-stream-decrypt-errors
Open

fix: reject corrupted attachment stream decrypts#92
Ap4sh wants to merge 1 commit into
session-foundation:devfrom
Ap4sh:fix-attachment-stream-decrypt-errors

Conversation

@Ap4sh

@Ap4sh Ap4sh commented Jun 5, 2026

Copy link
Copy Markdown

summary

  • make attachment stream decrypt wrappers throw when Decryptor::update() or finalize() rejects corrupted data
  • keep partial output cleanup for file decrypt paths
  • add coverage for final-byte corruption and full-chunk corruption across the file/buffer decrypt wrappers

testing

  • cmake -G Ninja -S . -B Build -DENABLE_NETWORKING=ON -DUSE_LTO=OFF
  • ./utils/format.sh verify
  • cmake --build Build --target testAll --parallel 4
  • Build/tests/testAll "Attachment streaming decryption rejects corrupted data" -s
  • Build/tests/testAll "Attachment streaming decryption rejects corrupted full chunks" -s
  • Build/tests/testAll "[attachments]"
  • Build/tests/testAll

@Ap4sh Ap4sh force-pushed the fix-attachment-stream-decrypt-errors branch from aa63284 to 01db5c8 Compare June 5, 2026 21:29
@Ap4sh Ap4sh marked this pull request as ready for review June 5, 2026 21:49
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