Skip to content

CGDMF-141: Extend Integrity Value calculation service#178

Merged
wouterpot merged 7 commits into
developfrom
CGDMF-141-remaining-integrity-algos
Jun 2, 2026
Merged

CGDMF-141: Extend Integrity Value calculation service#178
wouterpot merged 7 commits into
developfrom
CGDMF-141-remaining-integrity-algos

Conversation

@wouterpot

Copy link
Copy Markdown
Collaborator

No description provided.

@wouterpot wouterpot force-pushed the CGDMF-140-file-integrity branch 2 times, most recently from 9a0596e to 094bcf5 Compare May 21, 2026 14:42
@wouterpot wouterpot force-pushed the CGDMF-141-remaining-integrity-algos branch from 7c17a5c to aa7a4e1 Compare May 21, 2026 14:45
@wouterpot wouterpot marked this pull request as ready for review May 21, 2026 15:00
@hartman hartman requested a review from Copilot May 26, 2026 08:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extends the IntegrityCalculationService to support additional integrity algorithms from the Documenten API model (CRC-16/64, Fletcher variants, and HMAC), and refactors the hashing logic into shared helpers used by both byte-array and streaming entrypoints.

Changes:

  • Added checksum/hash implementations and a shared computeHash() dispatcher for more IntegriteitAlgoritme values.
  • Refactored MessageDigest selection into a helper (toJavaMessageDigestName()).
  • Updated withIntegrity() to support the new algorithms, buffering the stream for algorithms without a built-in Java streaming filter.

Comment thread src/main/kotlin/services/IntegrityCalculationService.kt Outdated
Comment thread src/main/kotlin/services/IntegrityCalculationService.kt Outdated
Comment thread src/main/kotlin/services/IntegrityCalculationService.kt Outdated
Comment thread src/main/kotlin/services/IntegrityCalculationService.kt Outdated
Comment thread src/main/kotlin/services/IntegrityCalculationService.kt Outdated
Comment thread src/main/kotlin/services/IntegrityCalculationService.kt
@wouterpot wouterpot force-pushed the CGDMF-140-file-integrity branch 3 times, most recently from 931b253 to a89d6a5 Compare May 29, 2026 07:53
@wouterpot wouterpot force-pushed the CGDMF-141-remaining-integrity-algos branch 3 times, most recently from d2fcf7c to 0c7a5f5 Compare May 29, 2026 11:17
@wouterpot wouterpot force-pushed the CGDMF-140-file-integrity branch from 024ea30 to 62e51cf Compare May 29, 2026 14:11
Base automatically changed from CGDMF-140-file-integrity to develop May 29, 2026 14:19
@wouterpot wouterpot force-pushed the CGDMF-141-remaining-integrity-algos branch from 0c7a5f5 to ddd9d91 Compare June 1, 2026 11:50
wouterpot and others added 7 commits June 2, 2026 09:14
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Make calculating HMAC fail. it's only possible to do with a secret,
and we won't have that generally.
@wouterpot wouterpot force-pushed the CGDMF-141-remaining-integrity-algos branch from 4d6e9de to 3c21385 Compare June 2, 2026 07:14
@wouterpot wouterpot merged commit f02bab1 into develop Jun 2, 2026
3 checks passed
@wouterpot wouterpot deleted the CGDMF-141-remaining-integrity-algos branch June 2, 2026 07:14
github-actions Bot added a commit that referenced this pull request Jun 24, 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.

3 participants