Skip to content

Fail closed on unknown Qwen3 TTS runtime hashes - #54

Draft
Blackspirits wants to merge 2 commits into
upl/review-base-9be1from
fix/qwen3tts-runtime-failclosed-9be1
Draft

Blackspirits wants to merge 2 commits into
upl/review-base-9be1from
fix/qwen3tts-runtime-failclosed-9be1

Conversation

@Blackspirits

@Blackspirits Blackspirits commented Sep 12, 2026

Copy link
Copy Markdown
Owner

Summary

Qwen3 TTS engine and voices archives are already checked against DownloadHashManager, but the integrity helper currently returns without verification when the hash key/digest cannot be resolved or when the stream is empty. That can turn a future resolver/registry mismatch into an unauthenticated unpack.

This change:

  • fails closed when the Qwen3 TTS engine/voices hash key is missing
  • fails closed when the current digest is missing
  • rejects empty/tampered payloads instead of treating an empty stream as verified
  • rejects streams that cannot be safely read and rewound
  • always rewinds the stream after hashing, including failure/cancellation paths
  • preserves all existing engine/voices URLs, release pins, registered digests, GGUF model-download behavior and unpack flow
  • adds regressions for all seven current engine/voices digests, the real HTTP engine path, the real HTTP voices path, null/unknown keys, empty streams and non-seekable streams

Validation

  • no URL or digest values were changed
  • all six current engine registry hashes were independently compared with the sha256: asset digests published by the official niksedk/qwen3-tts.cpp release v0.4.6; all six match
  • the current voices hash was independently compared with the sha256: asset digest published by the official SubtitleEdit/support-files release qwen3-tts-cpp-2026-5; it matches
  • current callers only unpack engine/voices after their download task completes successfully
  • dynamic GGUF model downloads are intentionally out of scope because they do not use this pinned runtime hash registry
  • full solution restore passed
  • full solution build passed
  • full solution test suite passed on the first run
  • retry step was not used
  • validation run: #34705034411

Base is upstream 9be10e12d0f04655f2f134718b00679f89b2b15f.

This PR supersedes internal draft #45.

AI assistance: ChatGPT was used to independently re-audit the Qwen3 TTS integrity and unpack paths on current upstream, compare current registry hashes with official release asset digests, strengthen fail-closed verification, and add regression coverage.

Copy link
Copy Markdown
Owner Author

Independent adversarial re-check on current upstream base: confirmed all six Qwen3 TTS engine hashes against niksedk/qwen3-tts.cpp v0.4.6 and the voices hash against SubtitleEdit/support-files qwen3-tts-cpp-2026-5; engine and voices are only unpacked after the verified task completes successfully; null/unknown keys, empty streams, non-seekable streams and tampered payloads now fail closed. Full current-base CI run #34705034411 passed on the first test run with no retry. No blocker identified. Keep draft; no merge/promotion performed.

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