Repository navigation
chore(deps): OpenTDFKit 5.0.1, whose policy binding is the OpenTDF spec form - #8
Conversation
…ec form Require OpenTDFKit from 5.0.1 (5.0.0 cannot be resolved by version: it pinned ZIPFoundation to a revision; 5.0.1 requires 0.9.20). Resolved: OpenTDFKit 5.0.1 (3512e27), CryptoSwift 1.10.0, ZIPFoundation 0.9.20. OpenTDFKit 5 writes keyAccess.policyBinding.hash in the OpenTDF spec form, base64(HMAC-SHA256(DEK, base64(policy))), the raw 32-byte digest, instead of the legacy base64(hex(HMAC)). The HLS packager, the Standard TDF segment crypto and the key provider take their binding from TDFCrypto.policyBinding, so their manifests now carry the spec form. Rewrap needs a KAS with opentdf/platform#4081; platform.arkavo.net has it. The FairPlay (fMP4) path already wrote the spec form itself and is unchanged. - HLSTDFPackagerPolicyTests decode the binding as base64 of the raw digest (44 characters, 32 bytes) and assert it is not the legacy hex form. - FairPlayPolicyTests gains a cross-check: OpenTDFKit's binding equals the arks golden fixture, so the HLS and fMP4 paths agree. - Doc comments describe the spec form. swift test: 233 tests in 41 suites pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TTtgscNah3Wk739yom9NPF
Code Review ✅ Approved🔴 High risk · Switching policyBinding hashes to the raw-digest spec form could make rewrap fail on KAS versions lacking #4081. Bumps OpenTDFKit to 5.0.1 so dependencies resolve by version, and switches the policy binding in HLS manifests to the OpenTDF spec form (base64 of the raw HMAC-SHA256 digest). No issues found.
Review coverage🤖 Auto-approval Approved 📋 Rules No rules evaluated 🧪 Functional validation Not enabled · Set up OptionsAuto-apply is off → Gitar will not commit updates to this branch. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Gitar |
Summary
from: "5.0.1". 5.0.0 can't be resolved by version because it pinned ZIPFoundation to a revision; 5.0.1, from fix(deps): require ZIPFoundation by version so consumers can resolve OpenTDFKit OpenTDFKit#58, requires 0.9.20 by version.3512e27)f2a627b)22787ff)Behaviour change: the policy binding is now the spec form
OpenTDFKit 5 writes
keyAccess.policyBinding.hashasbase64(HMAC-SHA256(DEK, base64(policy))), the raw 32-byte digest. Version 4 wrote the legacybase64(hex(HMAC)).HLSTDFPackager,StandardTDFSegmentCryptoandStandardTDFKeyProvidertake their binding fromTDFCrypto.policyBinding, so their manifests now carry the spec form.FairPlayPolicy.binding) and is unchanged.Tests
HLSTDFPackagerPolicyTestsdecode the binding as base64 of the raw digest (44 characters, 32 bytes), and assert that it isn't the legacy hex form.FairPlayPolicyTests.openTDFKitBindingMatchesGolden: OpenTDFKit's binding equals the arks golden fixture, so the HLS and fMP4 paths agree.swift test: all 233 tests in 41 suites pass.This will be released as 0.2.0. Consumers' KASes need opentdf/platform#4081.
🤖 Generated with Claude Code
https://claude.ai/code/session_01TTtgscNah3Wk739yom9NPF