Goal. A complete, by-hand construction of a single stamp line — all plain ASCII, deterministic, and ready to audit.
Inputs
- UTC timestamp:
iso_utc = "2025-10-13T10:53:57Z" - File bytes (ASCII): the 6-byte string
hello\n
Step 1 — UTC to epoch seconds
- Compute
unix_seconds = seconds_since_1970_UTC(iso_utc) = 1760352837
Step 2 — Deterministic clock from UTC
- Angle primitives:
wrap360(x) = x - 360*floor(x/360) - Raw angle:
(unix_seconds / 86400) * 360 = 163.48749999981374 + 360*k - Normalize:
theta_deg = 163.48749999981374 - Canonical print (binary64, half-even), default
theta_prec = 5:theta_str = "163.48750" - Discrete sector:
rasi_idx = floor(theta_deg / 30) = 5
Step 3 — File content hash
- Select file algorithm (default):
algo = sha256 - Digest over exact bytes (streaming allowed):
h_file = sha256(file_bytes) - For
hello\n(68 65 6c 6c 6f 0a):h_str = "5891b5b522d5df086d0ff0b110fbd9d21bb4fc7163af34d08286a2e846f6be03"
Step 4 — Build the stamp core (ASCII, no spaces)
stamp_core = "SSMCLOCK1|" + iso_utc + "|" + rasi_idx + "|" + theta_str + "|" + h_str- Result:
SSMCLOCK1|2025-10-13T10:53:57Z|5|163.48750|5891b5b522d5df086d0ff0b110fbd9d21bb4fc7163af34d08286a2e846f6be03
Step 5 — Append-only chain (first record)
- Chain seed:
chain_0 = "0"*64 - Chain algorithm (default):
chain_algo = sha256 - Recurrence:
chain_1 = sha256( ascii(chain_0 + "|" + stamp_core) ) - Result:
chain_str = "e5243368aaaf8168f02927dd69e02276bce15aa96e261d17bae5ba0e8d315801"
Step 6 — Final stamp line (emit one ASCII line)
- Base form:
SSMCLOCK1|2025-10-13T10:53:57Z|5|163.48750|5891b5b522d5df086d0ff0b110fbd9d21bb4fc7163af34d08286a2e846f6be03|e5243368aaaf8168f02927dd69e02276bce15aa96e261d17bae5ba0e8d315801 - Optional tail (illustrative; non-breaking):
SSMCLOCK1|2025-10-13T10:53:57Z|5|163.48750|5891b5b5...6be03|e5243368...15801|kv:algo=sha256;chain_algo=sha256;theta_prec=5;float=ieee75464;time_mode=derived_utc
Quick verification (by hand)
- Hash check: recompute
h' = sha256(file_bytes)→ must equalh_str. - Clock check: recompute from
iso_utc; requirerasi'_idx = 5andtheta_str' = "163.48750". - Chain check (first row): with
chain_0 = "0"*64, recomputesha256( ascii(chain_0 "|" stamp_core) )→ must equalchain_str.
Tiny variant (for contrast)
- If the file were
hello(no newline), the digest field would be:sha256("hello") = 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824
(All other steps unchanged ifiso_utcstays the same.)
Navigation
Back: SSM-Clock Stamp – Canonical Formatting & Parsing (7.1)
Next: SSM-Clock Stamp – Conformance Checklist (7.3)