fix(security): require signed tenant claims on admin endpoints - #268
fix(security): require signed tenant claims on admin endpoints#268seonghobae wants to merge 181 commits into
Conversation
📝 WalkthroughWalkthroughChanges테넌트 관리자 보안
Estimated code review effort: 4 (Complex) | ~60 minutes Possibly related issues
Possibly related PRs
Sequence Diagram(s)sequenceDiagram
participant AdminClient
participant AdminController
participant TenantAccessService
participant DefaultDocumentConversionService
participant InMemoryConversionJobRepository
participant ConversionJobStateStore
participant AdministrativeAuditLogger
AdminClient->>AdminController: signed tenant claims and admin permission
AdminController->>TenantAccessService: requireSigned
TenantAccessService-->>AdminController: TenantContext
AdminController->>DefaultDocumentConversionService: tenant-scoped operation
DefaultDocumentConversionService->>InMemoryConversionJobRepository: tenant and job identifier
InMemoryConversionJobRepository-->>DefaultDocumentConversionService: scoped result
DefaultDocumentConversionService->>ConversionJobStateStore: tenant-bound retry transition
ConversionJobStateStore-->>DefaultDocumentConversionService: retry outcome
AdminController->>AdministrativeAuditLogger: action, outcome, HTTP status
AdminController-->>AdminClient: scoped HTTP response
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Acknowledging that this work is superseded by #268.
|
Supersession decision after fresh post-#270 reconciliation sweep:
The branch is no longer a defensible integration vehicle. Its valuable semantics have been deliberately decomposed onto current-base or bounded successor lanes rather than rebasing the 139-file descendant: tenant-scoped admin deletion #341; storage-scoped tenant list #342; permanent job-id reservation #345; lifecycle serialization #350; deletion state #351; deletion receipt identity #353; fail-closed ledger persistence #357; tenant-scoped lookup #361/#380; privacy-safe administrative audit #363. The remaining end-to-end deletion cleanup/recovery/user journey stays authoritative under #263, and durable generation/attempt/retry/outbox/idempotency/cancellation/redelivery work stays authoritative under #312 and its current bounded successors. Accordingly, close #268 as superseded. Do not reuse this branch's ancestry, reviews, or checks. Any still-open semantic must advance through its current issue/PR authority and be regenerated against the then-live protected base. |
Security objective
Make administrative conversion-job endpoints fail closed under signed tenant claims, least-privilege permissions, tenant-scoped persistence/mutation, immutable job identity, privacy-safe audit evidence and restart-safe artifact deletion.
Fresh exact stack state — 2026-08-10
8d3fa3d1e7037c1c91411e8b4b6c014e38d04add;fix/pii-logging-16240128950440010639;63cdc36b926af8fd03a1ec689a1a6d5d800b8248;main:83ec6f7fe2b04bdcd28bf98ec350e41e55730a18;ed3863209109cd24a3cf1f1d6bdcd51db16fbef1;diverged, 82 commits ahead and 46 behind, merge baseed3863209109cd24a3cf1f1d6bdcd51db16fbef1;This large child is deliberately not churn-rebased while #270 remains outside protected main. Once the parent integrates, preserve the effective lifecycle/security delta on the new baseline and regenerate every base-sensitive check/review.
Security and lifecycle boundary
admin:readfor tenant-scoped listing andadmin:writefor delete/retry; fail closed before repository access for invalid claims/permission;Historical source-head evidence
For unchanged child head
8d3fa3d1e7037c1c91411e8b4b6c014e38d04add, prior CI31178997607, fuzz31178997148and CodeRabbit status were green. Because the current parent is now 46 commits beyond the historical merge base, those remain source-head history only.Merge gate
Keep Draft. Integrate #270 first. Then reconcile this administrative/deletion delta, verify effective ancestry/diff, rerun exact-head Maven/Surefire/Failsafe, zero-missed owned coverage, public Javadocs, CI, Security Scan, SAST, fuzz, applicable current-head reviews, unresolved-thread, independent-approval and branch-protection evidence. Do not restore demo-tenant fallback, same-UUID replacement, global mutation fallbacks, process-local fairness cursors, exception-selected log content or weakened tests/protection.