Extend checks during received data decompression


Implement zip bomb protection aligned with Qt Network's
QDecompressHelper approach:
- Once decompressed output exceeds 10 MB (DecompressedSafetyCheckThreshold),
  check the compression ratio. If it exceeds 40:1 for gzip/deflate,
  abort decompression as a potential archive bomb.
  This allows legitimate large responses with normal compression ratios
  to pass through, while catching pathological payloads early.

Additionally:
- Pass 'safetyThresholdSize' to parseResponse() for all
response types (not just file responses), closing a gap where JSON/XML
responses had no protection.
- Add setSafetyDecompressedThresholdSize() and
safetyDecompressedThresholdSize() APIs to make the safety threshold
size configurable.
- Add test cases verifying a new logic of the ratio-based bomb
  detection.

Task-number: QTBUG-147739
Pick-to: 6.12
Change-Id: I6bbedd8d4e25d47b85ae8c98ecfdb8c0900dc932
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
commit3fae11f843b9801df7df34684d174cacf1f57cfd
parent13fe665b5f80e5f013ea934070966a5af6b58a94
authorTatiana Borisova <tatiana.borisova@qt.io>
committerTatiana Borisova <tatiana.borisova@qt.io>
commit timeSat, 11 Jul 2026 13:33:22 +0000