The keycloak project ended with four open questions that design could not
settle. A two-VM lab was built to answer them by measurement, and this is
that material: 26 experiments, 125 raw command outputs, 22 browser captures.
Follows the import procedure in README.md.
source/ the originating repository verbatim — 78 documents, 28 SVGs,
8 manifests, plus .source-revision recording the commit
final/ the SSOT
document.md 729 lines written from the 29 experiment documents, not
concatenated: what was predicted, what was measured, and
where the measurement itself was wrong
evidence/raw 125 outputs, flattened to <experiment>__<file> because
the originals collided (01-baseline.txt appeared three
times) and the audit only globs the top level
evidence/meta one per raw file; command and exitCode are null and the
README says why rather than inventing them
evidence/browser 22 captures
assets/ three diagrams through techviz
.techviz/ their VizSpecs
A separate project rather than an addition to keycloak: the B-layer answers
that project's four questions, but the A, C and D layers are about cluster
failure, SSO and operations, and one document.md should hold one subject.
The four question records there can point here through 관계.
Recorded rather than papered over: only three of the 28 diagrams were
remade. The repository forbids hand-drawn SVG and forbids titles inside the
canvas; all 28 originals carry both, so converting them is redrawing, not
reformatting. They stay in source/ and the gap is written into the document.
verify-pipeline.py passes. audit-records.py reports no issues.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
53 lines
3.0 KiB
Markdown
53 lines
3.0 KiB
Markdown
---
|
|
kind: CONCEPT
|
|
slug: adapter-outbound-objectstorage-c06
|
|
title: 다른 route의 identity로 만든 키는 파싱 단계에서 거부된다
|
|
topic: schema-and-wire-models
|
|
project: clean-architecture-backend-template
|
|
status: 게시 전
|
|
sourceRevision: 21234e38cdb9a926cbc92bb97a2aee2e4a7d2916
|
|
rootTreeNode: concept:adapter-outbound-objectstorage-c06
|
|
evidenceCapturedOn: 2026-09-01
|
|
assets:
|
|
- key: adapter-outbound-objectstorage-c06
|
|
file: ../../../final/evidence/rendered/adapter-outbound-objectstorage-c06.svg
|
|
evidence:
|
|
- ../../../final/evidence/raw/adapter-outbound-objectstorage-c06.txt
|
|
source:
|
|
- 원본 분석 절은 analysis/09-adapter-outbound-objectstorage.md#L273 이다.
|
|
module: adapter-outbound-objectstorage
|
|
---
|
|
|
|
# 다른 route의 identity로 만든 키는 파싱 단계에서 거부된다
|
|
|
|
키를 만드는 인코더가 각 계열마다 하나뿐이고, route 격리와 핸들 계열 분리가 파싱 시점 검사로 성립한다.
|
|
|
|
## 본문
|
|
|
|
<!-- body:start -->
|
|
|
|
`ObjectControlKeyCodec`과 `ObjectDataKeyCodec`이 각각 "Sole encoder"를 자칭하고, 저장소에서 `"control/v1/"`·`"data/v1/"` 리터럴은 이 두 파일에만 있다(`152-...` §8.3). 키 형태는 `control/v1/<family>/<route>/<shard>/<identity>`이고 shard는 identity의 SHA-256 앞 두 자리다.
|
|
|
|
## ObjectControlKeyCodec 참조 위치
|
|
|
|
:::evidence key="adapter-outbound-objectstorage-c06" alt="코드베이스에서 ObjectControlKeyCodec 를 검색한 출력 15줄. 이 기록이 세는 참조가 그 출력에 그대로 보인다." caption="ObjectControlKeyCodec 코드베이스 검색 — 15줄 · exit 0" zoom="true"
|
|
:::
|
|
|
|
## route 격리가 구조적이다
|
|
|
|
`requireMatchingRoute(route, routedIdentity)`가 routed identity의 route 구획을 파싱해 현재 route와 다르면 거부한다("routed identity belongs to a different route"). reference·session·stage handle 키 모두 이 검사를 지난다.
|
|
|
|
## 핸들 계열이 접두사로 분리된다
|
|
|
|
`osh1`(stage), `osu1`(direct upload), `osm1`(multipart), `osv1`(version), `osr1`(reference). `ObjectNamespaceCodecTest.referenceAndHandleFamiliesRemainSeparated`가 그 분리를 고정하고, `dataKeyApiHasNoRawNameStringParameter`는 **API 서명 자체에 raw 이름 문자열이 없음**을 단언한다.
|
|
|
|
## 잘림을 조용히 넘기지 않는다
|
|
|
|
`CrockfordBase32`는 소문자 정규 알파벳(`0123456789abcdefghjkmnpqrstvwxyz` — I·L·O·U 제외)을 쓰고, 인코딩 후 남은 값이 있으면 거부한다("base32 output length is too small").
|
|
|
|
## 무엇이 이 성질을 고정하고 있나
|
|
|
|
property-based 검사가 있다 — `routeParserRejectsArbitraryNonCanonicalText(@ForAll String candidate)`(jqwik), `namespaceRejectsAliasesAndTraversalInputs`. fingerprint codec에는 **golden vector**가 고정돼 있다(`canonicalIntentHasAFrozenGoldenVector`, `sameIntentIsStableAndEverySemanticChangeChangesTheFingerprint`). `policySnapshotCodecIsCanonicalAndContainsNoCredentialSurface`는 정책 스냅샷에 자격증명 표면이 없음을 test로 고정한다.
|
|
|
|
<!-- body:end -->
|