lib

Core libraries for Radroots
git clone https://radroots.dev/git/lib.git
Log | Files | Refs | README

workspace.v1.json (8838B)


      1 {
      2   "schema_version": 1,
      3   "contract_id": "radroots.execution.workspace.v1",
      4   "state": "native_buyer_preparation_window_implemented",
      5   "ownership": {
      6     "domain": "Validated actor, authority, checkpoint and captured-context descriptors; descriptors grant no rights",
      7     "execution": "Owned authenticated workspace session and opaque captured command context",
      8     "storage_sqlite": "Concrete protected native namespace and current grant/authority verification",
      9     "facade": "Explicit local attachment and shared execution entry points",
     10     "protocol": "Closed v1 inquiry/reply command data codec, canonical command/approval-intent hashes; parsing grants no authority"
     11   },
     12   "identity": {
     13     "workspace_executor_operation_grant_bytes": 32,
     14     "integer_wire": "canonical decimal strings bounded by signed 64-bit maximum",
     15     "generation": "positive; distinct from a public cache generation",
     16     "participant": "validated Nostr x-only key; distinct from the authenticated device/principal"
     17   },
     18   "native_scope": {
     19     "namespace": "explicit new execution namespace; existing opens never create or infer authority",
     20     "authentication": "protected high-entropy credential checked against persisted scoped grant and authority state",
     21     "credential_bytes": 32,
     22     "credential_persistence": "verifier only, under protected handling; no plaintext credential in SQL, diagnostics or arguments",
     23     "private_payload_max_bytes": 16384,
     24     "private_codec": "existing context-bound authenticated envelope v2 with explicit qualified provider, key material and unique nonce",
     25     "transactions": "Grant creation/revocation and buyer inquiry preparation observe actual SQLite completion. T0 uses BEGIN IMMEDIATE and exact protected grant-row comparison before current proof/generation/route/deadline checks. Provider work finishes before the transaction. Prepared state does not install a message or invoke signing/delivery.",
     26     "initialization": "explicit fresh local outbox enrollment; no automatic stock ledger or restore from a key/public cache",
     27     "remote_attachment_qualified": false,
     28     "firm_stock_qualified": false,
     29     "private_payload_scope": "Protected grant plaintext and protocol private-record limits remain distinct from the internal retained command journal."
     30   },
     31   "context": {
     32     "constructor": "pure synchronous authenticated workspace-session method; no clock, storage, signer or network effects; arbitrary JSON yields descriptors, never a trusted context",
     33     "fields": [
     34       "operation_id",
     35       "actor",
     36       "workspace_id",
     37       "authority",
     38       "route_digest",
     39       "approval",
     40       "expected",
     41       "not_after",
     42       "correlation_id"
     43     ],
     44     "nullable_fields_required": true,
     45     "approval": "descriptor alone is not consent; authoritative admission validates protected origin, exact intent, scope and expiry",
     46     "idempotency": "captured semantic input is immutable; correlation is diagnostic only",
     47     "revocation": "attachment observation does not replace current transaction-time grant checks"
     48   },
     49   "lifecycle": "attach work and callbacks remain owned across observer loss; close stops admission and drains work before credentials/callbacks and storage are released",
     50   "resource_bounds": {
     51     "native_queued_requests": 32,
     52     "native_in_flight_requests": 1,
     53     "client_workspace_scopes": 16,
     54     "credentials": "zeroizing roots are released at scope/client quiesce; admitted authentication owns its request credential through safe completion"
     55   },
     56   "qualification_required": [
     57     "Actual protected native store and correct credential attachment",
     58     "Wrong credential, participant, workspace, executor, generation, route, grant and checkpoint refusal",
     59     "Revoked/expired grant refusal and persisted reopen behavior",
     60     "No context authority from signer observation, public cache or caller-provided descriptors",
     61     "Full captured context fields, exact strings, explicit null, bounded redacted diagnostics and local/native lifetime checks",
     62     "Owning native/portable/API/contract checks and unchanged coverage policy",
     63     "Independent canonical command and approval-intent vectors and closed shape/byte/depth refusals",
     64     "Actual inquiry commit/reopen/replay, original correlation, digest conflict, proof/revocation/deadline and transaction-time grant checks",
     65     "Actual SQLite statement failure/confirmed rollback, deferred-constraint commit failure/unknown latch, lost observer and bounded queue/drain",
     66     "Protected operation-context substitution refusal and predecessor-schema byte preservation",
     67     "Exact retained preparation/issuance timing bounds and invalid restored-window refusal",
     68     "Actual first-window expiry/clock rollback between checked observation and T0, plus replay/reopen preserving the original window"
     69   ],
     70   "remaining": [
     71     "Complete operation receipts, authenticated reply/history and actual known-kind listing/chat T1/S/T2/D execution",
     72     "Owned durable workers, per-target delivery and process-fault recovery",
     73     "Full stock executor, remote pairing/transfer and restore/fencing",
     74     "Actual browser/platform providers, generated bindings, coherent consumers and final acceptance"
     75   ],
     76   "implementation_claimed": true,
     77   "implementation_scope": "Fresh protected local buyer attachment/context and actual inquiry Prepared admission/query, including the retained checked preparation observation and fixed first-issue window. No installed message, issuance/delivery, complete receipt, seller stock, remote pairing or general recovery qualification.",
     78   "package_publication_authorized": false,
     79   "command_data": {
     80     "types": [
     81       "inbox.inquire",
     82       "inbox.reply"
     83     ],
     84     "raw_and_canonical_max_bytes": 65536,
     85     "chat_utf8_max_bytes": 4096,
     86     "maximum_json_depth": 16,
     87     "canonicalization": "Closed ASCII-key RFC 8785 subset with preserved Unicode, fixed numeric kind 30402, canonical decimal-string exact values and explicit required nulls; not a general-purpose JCS implementation",
     88     "command_digest": "SHA-256(radroots.command.v1 NUL || canonical command excluding context.correlation_id)",
     89     "approval_intent_digest": "SHA-256(radroots.approval.v1 NUL || canonical command excluding context.approval and context.correlation_id)",
     90     "private_buffers": "Zeroizing retained canonical command and decoded private text; borrowed raw private JSON during parsing"
     91   },
     92   "prepared_journal": {
     93     "schema_user_version": 3,
     94     "catalog": [
     95       "workspace_grant",
     96       "operations",
     97       "operation_transaction_identity"
     98     ],
     99     "single_participant_scope": "One protected fresh local buyer grant per namespace; operations unique by complete workspace and operation ID",
    100     "admitted_effect": "Protected authorized inquiry preparation only; no stock effect, installed chat, signature or publication",
    101     "retained_identity": "Full operation and command digest plus original 32-byte transaction ID and positive revision",
    102     "internal_plaintext_max_bytes": 65536,
    103     "protected_envelope_max_bytes": 262144,
    104     "replay": "Current access and the original digest are verified before fresh planning, deadline or entropy; original correlation is retained",
    105     "unknown": "Original operation/digest and observed nullable transaction identity are retained; uncertain owner blocks business admission/query until safe close/reopen and exact original-row reconciliation",
    106     "known_failure": "No write was attempted, or actual rollback completed; commit/rollback uncertainty never becomes a known failure",
    107     "unavailable_history": "Reply parents and order expectations are refused until authenticated history is implemented",
    108     "approval": "Caller-provided approval descriptors are refused without a qualified protected consent origin",
    109     "predecessor_schema": "Preserve and refuse grant-only schema 1 and preparation-without-window schema 2; no inferred timestamp, implicit rewrite, deletion, re-enrollment or import.",
    110     "transaction_recheck": "The short transaction matches complete workspace/operation, participant/grant, command type/digest, original transaction, prepared phase/revision and exact retained protected bytes; matching ciphertext alone cannot hide changed indexed facts.",
    111     "protected_payload_schema": "radroots.workspace.operation.v2",
    112     "preparation_observation": "Retain the actual checked grant-authentication clock observation before protected command preparation; this is distinct from the earlier captured attachment observation.",
    113     "first_issuance_window": "Immutable exclusive deadline, at most 120 seconds after preparation and no later than captured authorization expiry. Transaction-time clock rollback or expiry blocks new preparation. Exact replay/reopen preserves the original window, including after expiry. Expiry never proves nonissuance."
    114   }
    115 }