SSM-Clock Stamp – Quickstart (9)

Goal. Stamp a file, verify it, make a daily anchor, and (optionally) share a verify pack — fully offline, plain ASCII.


9.1 Stamp a file

Run your wrapper (Windows example):

call 21_ssmcs_stamp.cmd "<file>"

Optional kv: policy (defaults shown):

--kv "algo=sha256;chain_algo=sha256;theta_prec=5;float=ieee75464;time_mode=derived_utc"

You should see:

SSM-CS STAMPED
SSMCLOCK1|iso_utc|rasi_idx|theta_deg|sha256(file)|chain[|kv:...]
SIDECAR: <file>.ssmclock.txt
LEDGER:  <ledger_csv_path>

Core formulas (pure ASCII):

  • wrap360(x) = x - 360*floor(x/360)
  • theta_deg = wrap360( (unix_seconds / 86400) * 360 )
  • rasi_idx = floor(theta_deg / 30)
  • h_file = H_algo(file_bytes)
  • chain_k = H_chain( ascii(chain_{k-1} + "|" + stamp_core) ) with chain_0 = "0"*64
  • stamp_core = "SSMCLOCK1|" + iso_utc + "|" + rasi_idx + "|" + theta_deg + "|" + h_file

Stamp line shape (one line, ASCII):

SSMCLOCK1|iso_utc|rasi_idx|theta_deg|sha256(file)|chain[|kv:...]


9.2 Verify a file and the ledger

Per-file verify:

call 22_ssmcs_verify.cmd "<file>"

Expected:

HASH_OK=true CLOCK_OK=true CHAIN_OK=true
VERDICT=PASS

Ledger continuity:

call 25_ssmcs_check_ledger.cmd

Expected:

LEDGER_OK=true


9.3 Make and verify a daily anchor (UTC date)

Make roll-up from sidecars:

call 24b_ssmcs_rollup_from_sidecars.cmd YYYY-MM-DD

Verify parity and publish note:

call 24c_ssmcs_verify_anchor.cmd YYYY-MM-DD
call 24d_ssmcs_anchor_note.cmd  YYYY-MM-DD

Anchor rule (pure ASCII):

  • rollup_D = sha256( ascii(Stamp_1 "|" ... "|" Stamp_n) )
  • canonical sort key: (iso_utc, stamp_core, chain)

Anchor note (ASCII):

SSM-Clock Stamp (SSM-CS) -- Daily Anchor
date=YYYY-MM-DD
count=n
rollup_sha256=<64-hex>
source=sidecars


9.4 One-shot audit

call 33_ssmcs_verify_all.cmd

You should see per file:

HASH_OK=true CLOCK_OK=true CHAIN_OK=true
VERDICT=PASS

Then:

LEDGER_OK=true
ANCHOR_LEDGER_OK=true
ANCHOR_SIDECARS_OK=true
VERDICT=PASS


9.5 Share a verify pack

Build, hash, list:

call 40_ssmcs_make_verify_pack.cmd
call 41_ssmcs_hash_pack.cmd
call 41b_ssmcs_list_pack.cmd

ASCII hash file:

file=verify_pack.zip
size_bytes=<int>
sha256=<64-hex-lower>

Publish verify_pack.zip with verify_pack.zip.sha256.txt. Recipients recompute sha256(verify_pack.zip) and compare.


9.6 Troubleshooting mini checklist

  • CLOCK_OK=false → ensure iso_utc is YYYY-MM-DDTHH:MM:SSZ (UTC only; no offsets/subseconds); print theta_deg with theta_prec=5 digits, ties-to-even.
  • CHAIN_OK=false → rewalk the ledger; if needed, resync from sidecars.
  • Anchor mismatch → rebuild the day set, canonical sort, recompute rollup_D.
  • Leap-second inputs → stamps with ...:60Z are invalid by policy.
  • ASCII hygiene → only | as delimiter; lowercase 64-hex digests; no Unicode punctuation.
  • kv: tail → unknown keys ignored; malformed values for recognized keys fail syntax.

Navigation
Back: SSM-Clock Stamp – Minimal CLI (8.3)
Next: SSM-Clock Stamp – Glossary & Notation (10)