Skip to content

2.2.0 snapshot - #1

Merged
cdo03c merged 9 commits into
mainfrom
2.2.0-SNAPSHOT
Nov 6, 2026
Merged

cdo03c merged 9 commits into
mainfrom
2.2.0-SNAPSHOT

Conversation

@cdo03c

@cdo03c cdo03c commented Nov 5, 2026

Copy link
Copy Markdown
Collaborator

2.2.0 - 2026-11-05

Added

  • Full SHA-256 integrity hash: Replaced 64-bit truncated SHAKE-256 with standard 32-byte cryptographic SHA-256 in Protobuf wire format and models.
  • Header Hash Display: Printed SHA-256 hash in PDF page header for human eye inspection and out-of-band comparison.
  • Verification Mode (verify_qr_pdf / /verify / qrdm verify): Non-destructive document verification reporting named check flags (payload_valid, hash_matches, code_count_correct, no_unexpected_codes, missing_codes).
  • Command-Line Interface (qrdm): Zero-dependency CLI entrypoint with encode, decode, and verify subcommands.
  • Minimal-Page Mode (minimal_mode): Suppresses verbose captions, body text, and footers, rendering only filename, truncated SHA-256, and page numbers.
  • Strict Validation Mode: Optional enforcement rejecting NUL bytes (0x00), payload size overages, and binary executable/archive signatures (ZIP, DOCX/XLSX/PPTX, OLE2, ELF, PE, PDF).
  • Foreign Barcode Detection: Ability to detect and optionally reject non-QRDM barcodes on pages (reject_unexpected_codes).
  • Missing Sequence Reporting: QRDecodeError now tracks and reports exact missing sequence indices via missing_codes.
  • Deterministic PDF Output: Set include_timestamp=False to omit UTC timestamp and produce bit-identical deterministic PDFs.
  • Degraded-Scan Test Suite: Added automated regression tests simulating skew, blur, JPEG compression loss, and low DPI.
  • Security Threat Model: Published comprehensive threat model documentation in docs/source/threat_model.md.
  • Self-signed TLS generator: Added conf/nginx/generate_certs.sh and removed committed sample private keys from repository.
  • Offline Install Bundle: Added scripts/create_offline_bundle.sh for air-gapped environments.

Changed

  • Privacy Default: Made printing plaintext document text opt-in (include_text=False by default).
  • Upgraded fitz import to pymupdf to silence deprecation warnings.
  • Added automatic fallback search paths for libzbar on macOS (/opt/homebrew, /opt/miniconda3, etc.).

Security

  • Removed committed private key (server-key.pem) and certificate from git history.
  • Upgraded wire-format checksum from truncated 64-bit hash to SHA-256.

- Upgrade document integrity hash from 64-bit SHAKE-256 to full 32-byte SHA-256.
- Print full SHA-256 digest in the PDF header for human verification.
- Add structured verification mode (verify_qr_pdf, /verify, and qrdm verify) reporting named check flags without writing files.
- Add minimal-page mode (minimal_mode) showing only filename, hash, and page numbers.
- Add standalone command-line interface (qrdm encode/decode/verify).
- Add strict validation mode rejecting NUL bytes, size overages, and binary signatures.
- Add support for detecting and optionally rejecting foreign/unexplained barcodes.
- Add automated regression tests for degraded scans (rotation, blur, JPEG loss).
- Add security threat model documentation (docs/source/threat_model.md).
- Add offline bundle creation script (scripts/create_offline_bundle.sh).
- Bump version to 2.2.0 in __init__.py, pyproject.toml, and CHANGELOG.md.
…ification

- Add 'photo' and 'flatbed' presets in encode_qr_pdf, CLI, and REST endpoint.
- 'flatbed' preset packs up to 12 codes/page (double capacity) for high-res scanners.
- 'photo' preset produces larger codes with Quartile ECC for mobile phone cameras.
- Drop Python 3.9 (past EOL) and require Python >= 3.10 in pyproject.toml.
- Publish full QRDM format specification (docs/source/format_specification.md).
- Add unit tests for preset encoding, capacity, and decoding.
…ntation

- Update FastAPI pinning from hard-pinned 0.109 to >= 0.115.0 and modernize all dependency versions in pyproject.toml.
- Format all source, tests, and ui code using black and ruff with 0 lint errors.
- Exclude generated protobuf code from ruff and black.
- Update Sphinx documentation for backend endpoints (/verify, presets, minimal_mode), frontend controls, and API references.
- Verify full test suite passes (30/30 passed) and documentation builds cleanly.
…d PyPI publish

- Add ci.yml: runs black formatting, ruff linting, and pytest matrix across Python 3.10, 3.11, and 3.12 with zbar.
- Add release.yml: triggers on merge to main, parses clean release version from SNAPSHOT branch/commit (e.g. 2.2.0), tags v<version>, creates GitHub Release with CHANGELOG notes and distribution assets, builds and deploys latest docs to GitHub Pages (gh-pages), and publishes package to PyPI.
@cdo03c
cdo03c requested a review from ericqLL November 5, 2026 12:02
@cdo03c cdo03c self-assigned this Nov 5, 2026
@cdo03c
cdo03c merged commit 3d9ad0f into main Nov 6, 2026
8 checks passed
@cdo03c
cdo03c deleted the 2.2.0-SNAPSHOT branch November 6, 2026 11:12
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