space-data-module-sdk 0.8.15 → 0.8.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (116) hide show
  1. package/docs/_shell/consumer-assets.html +5 -0
  2. package/docs/browser-wasmedge-isomorphic.html +261 -0
  3. package/docs/byo-wasm-quickstart.html +226 -0
  4. package/docs/byo-wasm-quickstart.md +204 -0
  5. package/docs/conformance.html +156 -0
  6. package/docs/emception-shared-memory-verdict.md +209 -0
  7. package/docs/events-abi.html +313 -0
  8. package/docs/events-abi.md +530 -0
  9. package/docs/families/analytics.html +178 -0
  10. package/docs/families/analytics.md +104 -0
  11. package/docs/families/attitude.html +157 -0
  12. package/docs/families/attitude.md +36 -0
  13. package/docs/families/behavior.html +157 -0
  14. package/docs/families/behavior.md +36 -0
  15. package/docs/families/breakup.html +157 -0
  16. package/docs/families/breakup.md +36 -0
  17. package/docs/families/conjunction.html +186 -0
  18. package/docs/families/conjunction.md +121 -0
  19. package/docs/families/data-source.html +318 -0
  20. package/docs/families/effects.html +157 -0
  21. package/docs/families/effects.md +36 -0
  22. package/docs/families/environment.html +170 -0
  23. package/docs/families/environment.md +73 -0
  24. package/docs/families/estimation.html +190 -0
  25. package/docs/families/estimation.md +128 -0
  26. package/docs/families/gnc.html +157 -0
  27. package/docs/families/gnc.md +36 -0
  28. package/docs/families/maneuver.html +209 -0
  29. package/docs/families/maneuver.md +206 -0
  30. package/docs/families/obstruction.html +191 -0
  31. package/docs/families/obstruction.md +96 -0
  32. package/docs/families/propagator.html +333 -0
  33. package/docs/families/propulsion.html +157 -0
  34. package/docs/families/propulsion.md +36 -0
  35. package/docs/families/reentry.html +157 -0
  36. package/docs/families/reentry.md +36 -0
  37. package/docs/families/rf.html +193 -0
  38. package/docs/families/rf.md +136 -0
  39. package/docs/families/scheduler.html +157 -0
  40. package/docs/families/scheduler.md +36 -0
  41. package/docs/families/sensor.html +157 -0
  42. package/docs/families/sensor.md +36 -0
  43. package/docs/families/signature.html +157 -0
  44. package/docs/families/signature.md +36 -0
  45. package/docs/flatsql-host-contract.html +176 -0
  46. package/docs/flatsql-streaming-standard.html +375 -0
  47. package/docs/gpu-module-abi.html +233 -0
  48. package/docs/harness-family-matrix.md +135 -0
  49. package/docs/index.html +216 -85
  50. package/docs/isomorphic-pthreads.html +228 -0
  51. package/docs/isomorphic-pthreads.md +84 -0
  52. package/docs/isomorphic-sdn-runtime-plan.html +274 -0
  53. package/docs/language-runtime-matrix.html +182 -0
  54. package/docs/llms.txt +86 -0
  55. package/docs/module-bundle-runtime-plan.html +146 -0
  56. package/docs/module-publication-standard.html +503 -0
  57. package/docs/node-red-default-node-parity.html +201 -0
  58. package/docs/propagator-abi.md +45 -12
  59. package/docs/protect-and-sign.html +181 -0
  60. package/docs/protect-and-sign.md +120 -0
  61. package/docs/protocol-installation.html +296 -0
  62. package/docs/publication-submission.html +158 -0
  63. package/docs/publication-submission.md +78 -0
  64. package/docs/secrets-capability.html +206 -0
  65. package/docs/styles.css +860 -167
  66. package/docs/testing-harness.html +408 -0
  67. package/docs/tri-runtime-parity-gate.html +182 -0
  68. package/docs/tri-runtime-parity.html +203 -0
  69. package/include/orbpro/orbpro_event_runner.h +951 -0
  70. package/include/orbpro/orbpro_events_abi.h +565 -0
  71. package/include/orbpro/orbpro_propagator_abi.h +17 -0
  72. package/package.json +11 -4
  73. package/schemas/orbpro/Events.fbs +501 -0
  74. package/schemas/orbpro/Propagator.fbs +72 -9
  75. package/schemas/orbpro/reference-frame-crosswalk.json +108 -0
  76. package/schemas/orbpro/reference-frame.lock.json +98 -0
  77. package/src/browser.js +13 -0
  78. package/src/generated/orbpro/events-abi.js +206 -0
  79. package/src/generated/orbpro/events-abi.ts +319 -0
  80. package/src/generated/orbpro/propagator/reference-frame.js +17 -0
  81. package/src/generated/orbpro/propagator/reference-frame.ts +91 -1
  82. package/src/generated/orbpro/propagator-abi.js +17 -0
  83. package/src/generated/orbpro/propagator-abi.ts +17 -0
  84. package/src/generated/spacedatastandards/plg/CCT.d.ts +94 -0
  85. package/src/generated/spacedatastandards/plg/CCT.d.ts.map +1 -0
  86. package/src/generated/spacedatastandards/plg/CCT.js +208 -0
  87. package/src/generated/spacedatastandards/plg/CCT.ts +281 -0
  88. package/src/generated/spacedatastandards/plg/CCTCategory.d.ts +98 -0
  89. package/src/generated/spacedatastandards/plg/CCTCategory.d.ts.map +1 -0
  90. package/src/generated/spacedatastandards/plg/CCTCategory.js +177 -0
  91. package/src/generated/spacedatastandards/plg/CCTCategory.ts +269 -0
  92. package/src/generated/spacedatastandards/plg/CCTCategoryRollup.d.ts +54 -0
  93. package/src/generated/spacedatastandards/plg/CCTCategoryRollup.d.ts.map +1 -0
  94. package/src/generated/spacedatastandards/plg/CCTCategoryRollup.js +106 -0
  95. package/src/generated/spacedatastandards/plg/CCTCategoryRollup.ts +144 -0
  96. package/src/generated/spacedatastandards/plg/PLG.d.ts +46 -2
  97. package/src/generated/spacedatastandards/plg/PLG.d.ts.map +1 -1
  98. package/src/generated/spacedatastandards/plg/PLG.js +78 -5
  99. package/src/generated/spacedatastandards/plg/PLG.ts +90 -5
  100. package/src/generated/spacedatastandards/plg/capabilityClass.d.ts +181 -0
  101. package/src/generated/spacedatastandards/plg/capabilityClass.d.ts.map +1 -0
  102. package/src/generated/spacedatastandards/plg/capabilityClass.js +183 -0
  103. package/src/generated/spacedatastandards/plg/capabilityClass.ts +208 -0
  104. package/src/generated/spacedatastandards/plg/main.d.ts +4 -0
  105. package/src/generated/spacedatastandards/plg/main.d.ts.map +1 -1
  106. package/src/generated/spacedatastandards/plg/main.js +4 -0
  107. package/src/generated/spacedatastandards/plg/main.ts +4 -0
  108. package/src/generated/spacedatastandards/plg/pluginCategory.d.ts +40 -2
  109. package/src/generated/spacedatastandards/plg/pluginCategory.d.ts.map +1 -1
  110. package/src/generated/spacedatastandards/plg/pluginCategory.js +40 -2
  111. package/src/generated/spacedatastandards/plg/pluginCategory.ts +40 -2
  112. package/src/host/browserModuleHarness.js +8 -0
  113. package/src/host/wasiThreadHost.js +189 -14
  114. package/src/index.d.ts +18 -1
  115. package/src/transport/index.js +16 -0
  116. package/src/transport/records.js +1015 -3
@@ -0,0 +1,201 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
6
+ <meta name="description" content="This matrix defines the deployment intent for compiled hosted-runtime artifacts." />
7
+ <title>Node-RED node parity — Space Data Module SDK</title>
8
+ <link rel="stylesheet" href="./styles.css" />
9
+ <!-- SDN_CONSUMER_ASSETS_START -->
10
+ <link rel="stylesheet" href="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.c3f68d1cfd88478f10d836a5e829d1dfc6a10157972cf0f7d4d319d0636f2cc4.css" integrity="sha384-fICuhN4I9xqOK1F5vGGzl26opuO+xQIvTZXMSV76lWTBiQ6AfzztMGLLDw8yRT8i" crossorigin="anonymous">
11
+ <script defer src="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.f611e7e151a3b5c38384272f8894a4c6634f0a29bf925b0e02e0e27f8db0bfff.js" integrity="sha384-R+QqsKoWJIS7iWrtPmgJ49DVnb1hSGjZokupbLInJd1PLp8RwQhtF/hnaerc33ci" crossorigin="anonymous" data-sdn-wallet-public-client="v1"></script>
12
+ <script defer src="https://static.spacedatanetwork.org/assets/sdn-stack-nav/1.0.0/sdn-stack-nav.52fde607eee38ffa116188201f50258ed50bd18c9f06c1af9678f763147a8fe5.js" integrity="sha384-dgeojhJ8vTszHXIbv7O7nZcEzqD10oUYYJjBmPrV7+kLQEUlXLQD4ek5Q7HOFiO5" crossorigin="anonymous" data-nav-style-url="https://static.spacedatanetwork.org/assets/sdn-stack-nav/1.0.0/sdn-stack-nav.36a36359ce18322185e9ff179f88175bab67d5ad84a14d9c08a54f2ff27267e7.css" data-nav-style-integrity="sha384-c4M8Fg+kYaeOYYtJVr7jJsde24IhSWkWaRyAOHEZU9jozhRck089aw+mnHwxymds" data-wallet-client-url="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.f611e7e151a3b5c38384272f8894a4c6634f0a29bf925b0e02e0e27f8db0bfff.js" data-wallet-client-integrity="sha384-R+QqsKoWJIS7iWrtPmgJ49DVnb1hSGjZokupbLInJd1PLp8RwQhtF/hnaerc33ci" data-wallet-style-url="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.c3f68d1cfd88478f10d836a5e829d1dfc6a10157972cf0f7d4d319d0636f2cc4.css" data-wallet-style-integrity="sha384-fICuhN4I9xqOK1F5vGGzl26opuO+xQIvTZXMSV76lWTBiQ6AfzztMGLLDw8yRT8i" data-wallet-client-id="sdn-module-sdk-pages-v1" data-wallet-callback-uri="https://digitalarsenal.github.io/space-data-module-sdk/wallet-callback.html" data-wallet-registry-sha256="e1ce6fe903c9700484a8a87d96581c8cad97063dabf63030b4518a31a3bdaa93"></script>
13
+ <!-- SDN_CONSUMER_ASSETS_END -->
14
+ </head>
15
+ <body>
16
+ <a class="skip-link" href="#main">Skip to content</a>
17
+ <sdn-stack-nav active="module-sdk"></sdn-stack-nav>
18
+ <header class="site-header">
19
+ <a class="site-brand" href="./">Space Data Module SDK</a>
20
+ <nav class="header-links" aria-label="Site">
21
+ <a href="./byo-wasm-quickstart.html">Quickstart</a>
22
+ <a href="./conformance.html">Conformance</a>
23
+ <a href="https://github.com/DigitalArsenal/space-data-module-sdk">GitHub</a>
24
+ <a class="stack-button" href="#stack">Stack</a>
25
+ </nav>
26
+ </header>
27
+ <div class="shell">
28
+ <nav class="sidebar" id="sidebar" aria-label="Documentation">
29
+ <h2>Start here</h2><ul>
30
+ <li><a href="./index.html"><span>Harness family matrix</span></a></li>
31
+ <li><a href="./byo-wasm-quickstart.html"><span>BYO-wasm quickstart</span></a></li>
32
+ <li><a href="./conformance.html"><span>Conformance kit</span></a></li>
33
+ <li><a href="./protect-and-sign.html"><span>Protect and sign</span></a></li>
34
+ <li><a href="./publication-submission.html"><span>Publication and listing</span></a></li>
35
+ </ul>
36
+ <h2>Dynamics</h2><ul>
37
+ <li><a href="./families/propagator.html"><span>Propagator</span><span class="tag tag-shipped">shipped</span></a></li>
38
+ <li><a href="./families/maneuver.html"><span>Maneuver</span><span class="tag tag-experimental">experimental</span></a></li>
39
+ <li><a href="./families/propulsion.html"><span>Propulsion</span><span class="tag tag-planned">planned</span></a></li>
40
+ <li><a href="./families/attitude.html"><span>Attitude</span><span class="tag tag-planned">planned</span></a></li>
41
+ <li><a href="./families/gnc.html"><span>GNC</span><span class="tag tag-planned">planned</span></a></li>
42
+ </ul>
43
+ <h2>Environment and interaction</h2><ul>
44
+ <li><a href="./families/rf.html"><span>RF</span><span class="tag tag-designed">designed</span></a></li>
45
+ <li><a href="./families/sensor.html"><span>Sensor</span><span class="tag tag-planned">planned</span></a></li>
46
+ <li><a href="./families/signature.html"><span>Signature</span><span class="tag tag-planned">planned</span></a></li>
47
+ <li><a href="./families/environment.html"><span>Environment</span><span class="tag tag-planned">planned</span></a></li>
48
+ <li><a href="./families/obstruction.html"><span>Obstruction</span><span class="tag tag-designed">designed</span></a></li>
49
+ </ul>
50
+ <h2>Event physics</h2><ul>
51
+ <li><a href="./families/breakup.html"><span>Breakup</span><span class="tag tag-planned">planned</span></a></li>
52
+ <li><a href="./families/reentry.html"><span>Reentry</span><span class="tag tag-planned">planned</span></a></li>
53
+ <li><a href="./families/conjunction.html"><span>Conjunction</span><span class="tag tag-designed">designed</span></a></li>
54
+ <li><a href="./families/effects.html"><span>Effects</span><span class="tag tag-planned">planned</span></a></li>
55
+ </ul>
56
+ <h2>Estimation, data and logic</h2><ul>
57
+ <li><a href="./families/estimation.html"><span>Estimation</span><span class="tag tag-experimental">experimental</span></a></li>
58
+ <li><a href="./families/data-source.html"><span>Data source</span><span class="tag tag-shipped">shipped</span></a></li>
59
+ <li><a href="./families/analytics.html"><span>Analytics</span><span class="tag tag-experimental">experimental</span></a></li>
60
+ <li><a href="./families/scheduler.html"><span>Scheduler</span><span class="tag tag-planned">planned</span></a></li>
61
+ <li><a href="./families/behavior.html"><span>Behavior</span><span class="tag tag-planned">planned</span></a></li>
62
+ </ul>
63
+ <h2>Runtime contract</h2><ul>
64
+ <li><a href="./events-abi.html"><span>Event locator ABI</span></a></li>
65
+ <li><a href="./module-publication-standard.html"><span>Module publication standard</span></a></li>
66
+ <li><a href="./browser-wasmedge-isomorphic.html"><span>Browser / WasmEdge isomorphism</span></a></li>
67
+ <li><a href="./isomorphic-pthreads.html"><span>Isomorphic pthreads</span></a></li>
68
+ <li><a href="./tri-runtime-parity.html"><span>Tri-runtime parity</span></a></li>
69
+ <li><a href="./tri-runtime-parity-gate.html"><span>Tri-runtime parity gate</span></a></li>
70
+ <li><a href="./testing-harness.html"><span>Testing harness</span></a></li>
71
+ <li><a href="./language-runtime-matrix.html"><span>Language and runtime matrix</span></a></li>
72
+ </ul>
73
+ <h2>Host surfaces</h2><ul>
74
+ <li><a href="./flatsql-host-contract.html"><span>FlatSQL host contract</span></a></li>
75
+ <li><a href="./flatsql-streaming-standard.html"><span>FlatSQL streaming standard</span></a></li>
76
+ <li><a href="./secrets-capability.html"><span>Credential lanes</span></a></li>
77
+ <li><a href="./protocol-installation.html"><span>Protocol installation</span></a></li>
78
+ <li><a href="./gpu-module-abi.html"><span>GPU module ABI</span></a></li>
79
+ <li><a href="./module-bundle-runtime-plan.html"><span>Module bundle runtime</span></a></li>
80
+ <li><a href="./isomorphic-sdn-runtime-plan.html"><span>Isomorphic SDN runtime</span></a></li>
81
+ <li><a href="./node-red-default-node-parity.html" aria-current="page"><span>Node-RED node parity</span></a></li>
82
+ </ul>
83
+ </nav>
84
+ <main class="doc" id="main">
85
+ <h1>Node-RED node parity</h1>
86
+ <p>This matrix defines the deployment intent for compiled hosted-runtime artifacts.</p>
87
+ <p>Use three buckets:</p>
88
+ <ul>
89
+ <li><code>wasi</code>: strict standalone WASI with no wrapper requirement</li>
90
+ <li><code>wasmedge</code>: standard server-side deployment target for maximum WASI compatibility</li>
91
+ <li><code>wrapper/delegated</code>: browser targets or features that still need host mediation</li>
92
+ </ul>
93
+ <p>The practical reason for <code>wasmedge</code> is simple: standalone WASI still does not give us portable networking parity, while WasmEdge adds socket, DNS, and TLS extensions that make guest-owned network services realistic.</p>
94
+ <h2 id="wasi-target"><a class="anchor" href="#wasi-target" aria-hidden="true">#</a><code>wasi</code> Target</h2>
95
+ <p>These should run as plain standalone WASI programs with no wrapper layer:</p>
96
+ <ul>
97
+ <li><code>change</code></li>
98
+ <li><code>switch</code></li>
99
+ <li><code>range</code></li>
100
+ <li><code>template</code></li>
101
+ <li><code>json</code></li>
102
+ <li><code>csv</code></li>
103
+ <li><code>yaml</code></li>
104
+ <li><code>xml</code></li>
105
+ <li><code>html</code></li>
106
+ <li><code>split</code></li>
107
+ <li><code>join</code></li>
108
+ <li><code>batch</code></li>
109
+ <li><code>sort</code></li>
110
+ <li><code>rbe</code></li>
111
+ <li><code>link in</code></li>
112
+ <li><code>link out</code></li>
113
+ <li><code>link call</code></li>
114
+ <li><code>debug</code></li>
115
+ <li>deterministic flow routing and payload transforms</li>
116
+ <li><code>file</code> and <code>file in</code> when limited to WASI preopen/file access</li>
117
+ </ul>
118
+ <p>Notes:</p>
119
+ <ul>
120
+ <li><code>inject</code> only fits this bucket for direct/manual triggering, not scheduling.</li>
121
+ <li><code>file</code> parity here excludes file watching.</li>
122
+ </ul>
123
+ <h2 id="wasmedge-target"><a class="anchor" href="#wasmedge-target" aria-hidden="true">#</a><code>wasmedge</code> Target</h2>
124
+ <p>These should aim to run in guest logic on WasmEdge without an extra wrapper:</p>
125
+ <ul>
126
+ <li>outbound <code>http request</code></li>
127
+ <li>inbound <code>http in</code> plus <code>http response</code></li>
128
+ <li>guest-owned TCP client/server behavior</li>
129
+ <li>guest-owned UDP behavior</li>
130
+ <li>guest-owned TLS/HTTPS behavior</li>
131
+ <li>direct protocol services built on sockets</li>
132
+ <li>WebSocket logic implemented in guest libraries over sockets/TLS</li>
133
+ <li>MQTT logic implemented in guest libraries over sockets/TLS</li>
134
+ </ul>
135
+ <p>Notes:</p>
136
+ <ul>
137
+ <li><code>websocket</code> and <code>mqtt</code> are guest-library targets, not direct WasmEdge runtime APIs.</li>
138
+ <li>prefer guest-owned protocol stacks over host wrappers whenever WasmEdge sockets/TLS are sufficient.</li>
139
+ </ul>
140
+ <h2 id="wrapper-or-delegated-host-required"><a class="anchor" href="#wrapper-or-delegated-host-required" aria-hidden="true">#</a>Wrapper Or Delegated Host Required</h2>
141
+ <p>These still require wrappers, delegated services, or explicit runtime support outside the guest:</p>
142
+ <ul>
143
+ <li><code>watch</code></li>
144
+ <li><code>exec</code></li>
145
+ <li>cron-style <code>inject</code></li>
146
+ <li><code>delay</code> and <code>trigger</code> when they depend on wall-clock scheduling</li>
147
+ <li><code>complete</code></li>
148
+ <li><code>catch</code></li>
149
+ <li><code>status</code></li>
150
+ <li>browser-local inbound listeners</li>
151
+ <li>browser-local durable filesystem behavior beyond browser storage adapters</li>
152
+ <li>any feature that depends on OS process control or file watching</li>
153
+ </ul>
154
+ <h2 id="planning-rule"><a class="anchor" href="#planning-rule" aria-hidden="true">#</a>Planning Rule</h2>
155
+ <p>If a node can be implemented entirely inside guest code on top of standard WASI or WasmEdge extensions, it should not be modeled as a host capability. Host capabilities should be reserved for features that truly still need wrappers or delegated services.</p>
156
+
157
+ <p class="doc-footer">
158
+ Source of truth for this page:
159
+ <code>docs/node-red-default-node-parity.md</code>. Regenerate with
160
+ <code>npm run build:docs</code>.
161
+ </p>
162
+ </main>
163
+ <nav class="rail" aria-label="On this page"><h2>On this page</h2><ul><li><a class="depth-2" href="#wasi-target"><code>wasi</code> Target</a></li>
164
+ <li><a class="depth-2" href="#wasmedge-target"><code>wasmedge</code> Target</a></li>
165
+ <li><a class="depth-2" href="#wrapper-or-delegated-host-required">Wrapper Or Delegated Host Required</a></li>
166
+ <li><a class="depth-2" href="#planning-rule">Planning Rule</a></li></ul></nav>
167
+ </div>
168
+ <section id="stack" class="section" aria-labelledby="stack-title">
169
+ <div class="section-head">
170
+ <p class="eyebrow">SDN Stack</p>
171
+ <h2 id="stack-title">Connected sites</h2>
172
+ </div>
173
+ <div class="link-list">
174
+ <a href="https://spacedatastandards.org/">
175
+ <span>Standards</span>
176
+ <small>Canonical schemas, record contracts, and generated bindings.</small>
177
+ </a>
178
+ <a href="https://digitalarsenal.github.io/flatbuffers/">
179
+ <span>FlatBuffers</span>
180
+ <small>Binary encoding, schema tooling, and runtime documentation.</small>
181
+ </a>
182
+ <a href="https://digitalarsenal.github.io/flatsql/">
183
+ <span>FlatSQL</span>
184
+ <small>SQL-style queries over FlatBuffer-backed datasets and streams.</small>
185
+ </a>
186
+ <a href="https://spacedatanetwork.org/">
187
+ <span>SDN</span>
188
+ <small>Distributed publication, discovery, delivery, and marketplace infrastructure.</small>
189
+ </a>
190
+ <a href="https://digitalarsenal.github.io/space-data-module-sdk/" class="active">
191
+ <span>Module SDK</span>
192
+ <small>WASM module packaging, validation, and host compatibility tooling.</small>
193
+ </a>
194
+ </div>
195
+ </section>
196
+ <footer class="site-footer">
197
+ Space Data Module SDK — Apache-2.0. Every ABI page renders a Markdown
198
+ source in <code>docs/</code>; edit the Markdown, never the HTML.
199
+ </footer>
200
+ </body>
201
+ </html>
@@ -196,8 +196,22 @@ Ruling: finding §4.1 / §8.1; landed as W0.1.
196
196
 
197
197
  ## Frames
198
198
 
199
- `reference_frame` is `OrbProReferenceFrame`:
200
- `TEME=0 J2000=1 ICRF=2 ECEF=3 MCI=4 MCMF=5`.
199
+ `reference_frame` is `OrbProReferenceFrame`. Values **0-5 are frozen and are
200
+ never renumbered**; the GMAT axis roster is appended at 6+:
201
+
202
+ `TEME=0 J2000=1 ICRF=2 ECEF=3 MCI=4 MCMF=5 MJ2000EC=6 MOD=7 TOD=8 MOE=9 TOE=10
203
+ BODY_FIXED=11 BODY_INERTIAL=12 OBJECT_REFERENCED=13 LOCAL_ALIGNED_CONSTRAINED=14
204
+ EQUATOR=15 GSE=16 GSM=17 TOPOCENTRIC=18 BODY_SPIN_SUN=19 SPICE_DEFINED=20
205
+ MOD_FK5=21 TOD_FK5=22`
206
+
207
+ `ECEF`, `MCI` and `MCMF` are body-bound legacy instances of the generic pair at
208
+ 11/12 — ECEF is `BODY_FIXED` about the Earth, MCI is `BODY_INERTIAL` about Mars,
209
+ MCMF is `BODY_FIXED` about Mars. They are retained; the generic members are not
210
+ a second spelling of them.
211
+
212
+ `MOD_FK5` and `TOD_FK5` are the IAU-76/FK5 route, retained under a NAME rather
213
+ than left as an undocumented second answer. They differ from `MOD`/`TOD` at the
214
+ milliarcsecond level and are not interchangeable with them.
201
215
 
202
216
  **Plugins output ECEF.** The frame transform happens INSIDE the module. A
203
217
  plugin that emits an inertial frame and expects the host to rotate it is
@@ -205,21 +219,40 @@ relying on a host path that is still unimplemented — `PropagatorPlugin.toICRF`
205
219
  carries a live TEME≈ICRF approximation, and an ECEF input there is wrong by up
206
220
  to a full Earth rotation (`orbpro-toicrf-frame-transform-unimplemented`).
207
221
 
208
- **Never let a raw integer frame value cross a boundary unqualified.** Four
209
- incompatible `ReferenceFrame` vocabularies are live on this seam:
222
+ **Never let a raw integer frame value cross a boundary unqualified.** Five
223
+ incompatible `ReferenceFrame` vocabularies are live on this seam, plus an
224
+ axis-type roster that is not a `ReferenceFrame` at all:
210
225
 
211
226
  | Vocabulary | Values |
212
227
  |---|---|
213
- | `orbpro.propagator` (**this ABI**) | TEME=0 J2000=1 ICRF=2 ECEF=3 MCI=4 MCMF=5 |
228
+ | `orbpro.propagator` (**this ABI**) | TEME=0 J2000=1 ICRF=2 ECEF=3 MCI=4 MCMF=5, then the roster at 6+ |
214
229
  | `orbpro.plugins` (`PropagatorState.fbs`) | ECI=0 ECEF=1 TEME=2 ICRF=3 |
215
- | `Cesium.ReferenceFrame` | FIXED=0 INERTIAL=1 |
230
+ | OrbPro engine `ReferenceFrame.js` | FIXED=0 INERTIAL=1 TEME=2 VVLH=3 ENU=4 NED=5 NEU=6 RIC=7 LVLH=8 |
216
231
  | `ConjunctionCommon.fbs` | ECI=1 |
217
-
218
- `ECI==0`, `TEME==0` and `FIXED==0` all collide, and ECEF is 1 in the second
219
- but 3 here. The second vocabulary's values are frozen by compiled WASM
220
- artifacts already in the field, so collapsing them is a wire break, tracked as
221
- `sdk-reference-frame-enum-unification`. Until it lands, **translate by named
222
- token at every seam**.
232
+ | `foundation/frames` `AxisType` | an ORIENTATION rule, no origin — never numerically equated with a frame |
233
+
234
+ The engine row is the one this document got wrong for a long time: it said
235
+ "`Cesium.ReferenceFrame` FIXED=0 INERTIAL=1", and it was stale in the direction
236
+ that mattered it hid seven live members. Verified against OrbPro `417320c5c5`
237
+ on 2026-08-30.
238
+
239
+ `ECI==0`, `TEME==0` and `FIXED==0` all collide, and ECEF is 1 in `orbpro.plugins`
240
+ but 3 here. Those values are frozen by compiled WASM artifacts already in the
241
+ field, so collapsing them is a wire break, tracked as
242
+ `sdk-reference-frame-enum-unification` — which also owns the ABI-vs-engine
243
+ inversion at 0/1. Until it lands, **translate by named token at every seam**.
244
+
245
+ The crosswalk between all of them is DATA, in
246
+ `schemas/orbpro/reference-frame-crosswalk.json`, and
247
+ `npm run check:reference-frame` (wired into `npm test` as
248
+ `test/reference-frame-uniqueness.test.js`) holds four things at once: exactly
249
+ one definition crosses the ABI; its numbering is append-only against
250
+ `schemas/orbpro/reference-frame.lock.json`; every foreign vocabulary maps onto
251
+ it by NAMED TOKEN and totally, re-read from source when that repo is on disk and
252
+ skipped-with-a-note when it is not; and the three live RTN triads (RIC, RSW,
253
+ RTN, plus the LVLH/VVLH relabellings) collapse to the single
254
+ `OBJECT_REFERENCED` member with an axes spec rather than becoming members of
255
+ their own.
223
256
 
224
257
  Use the generated setter `orbpro_state_set_reference_frame()`, never a bare
225
258
  assignment: it clears the three padding bytes a consumer reading offset 56 as
@@ -0,0 +1,181 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
6
+ <meta name="description" content="Once a module passes conformance and the parity gate, it is protected" />
7
+ <title>Protect and sign — Space Data Module SDK</title>
8
+ <link rel="stylesheet" href="./styles.css" />
9
+ <!-- SDN_CONSUMER_ASSETS_START -->
10
+ <link rel="stylesheet" href="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.c3f68d1cfd88478f10d836a5e829d1dfc6a10157972cf0f7d4d319d0636f2cc4.css" integrity="sha384-fICuhN4I9xqOK1F5vGGzl26opuO+xQIvTZXMSV76lWTBiQ6AfzztMGLLDw8yRT8i" crossorigin="anonymous">
11
+ <script defer src="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.f611e7e151a3b5c38384272f8894a4c6634f0a29bf925b0e02e0e27f8db0bfff.js" integrity="sha384-R+QqsKoWJIS7iWrtPmgJ49DVnb1hSGjZokupbLInJd1PLp8RwQhtF/hnaerc33ci" crossorigin="anonymous" data-sdn-wallet-public-client="v1"></script>
12
+ <script defer src="https://static.spacedatanetwork.org/assets/sdn-stack-nav/1.0.0/sdn-stack-nav.52fde607eee38ffa116188201f50258ed50bd18c9f06c1af9678f763147a8fe5.js" integrity="sha384-dgeojhJ8vTszHXIbv7O7nZcEzqD10oUYYJjBmPrV7+kLQEUlXLQD4ek5Q7HOFiO5" crossorigin="anonymous" data-nav-style-url="https://static.spacedatanetwork.org/assets/sdn-stack-nav/1.0.0/sdn-stack-nav.36a36359ce18322185e9ff179f88175bab67d5ad84a14d9c08a54f2ff27267e7.css" data-nav-style-integrity="sha384-c4M8Fg+kYaeOYYtJVr7jJsde24IhSWkWaRyAOHEZU9jozhRck089aw+mnHwxymds" data-wallet-client-url="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.f611e7e151a3b5c38384272f8894a4c6634f0a29bf925b0e02e0e27f8db0bfff.js" data-wallet-client-integrity="sha384-R+QqsKoWJIS7iWrtPmgJ49DVnb1hSGjZokupbLInJd1PLp8RwQhtF/hnaerc33ci" data-wallet-style-url="https://static.spacedatanetwork.org/assets/hd-wallet-ui/2.0.28/sdn-wallet-public-client.c3f68d1cfd88478f10d836a5e829d1dfc6a10157972cf0f7d4d319d0636f2cc4.css" data-wallet-style-integrity="sha384-fICuhN4I9xqOK1F5vGGzl26opuO+xQIvTZXMSV76lWTBiQ6AfzztMGLLDw8yRT8i" data-wallet-client-id="sdn-module-sdk-pages-v1" data-wallet-callback-uri="https://digitalarsenal.github.io/space-data-module-sdk/wallet-callback.html" data-wallet-registry-sha256="e1ce6fe903c9700484a8a87d96581c8cad97063dabf63030b4518a31a3bdaa93"></script>
13
+ <!-- SDN_CONSUMER_ASSETS_END -->
14
+ </head>
15
+ <body>
16
+ <a class="skip-link" href="#main">Skip to content</a>
17
+ <sdn-stack-nav active="module-sdk"></sdn-stack-nav>
18
+ <header class="site-header">
19
+ <a class="site-brand" href="./">Space Data Module SDK</a>
20
+ <nav class="header-links" aria-label="Site">
21
+ <a href="./byo-wasm-quickstart.html">Quickstart</a>
22
+ <a href="./conformance.html">Conformance</a>
23
+ <a href="https://github.com/DigitalArsenal/space-data-module-sdk">GitHub</a>
24
+ <a class="stack-button" href="#stack">Stack</a>
25
+ </nav>
26
+ </header>
27
+ <div class="shell">
28
+ <nav class="sidebar" id="sidebar" aria-label="Documentation">
29
+ <h2>Start here</h2><ul>
30
+ <li><a href="./index.html"><span>Harness family matrix</span></a></li>
31
+ <li><a href="./byo-wasm-quickstart.html"><span>BYO-wasm quickstart</span></a></li>
32
+ <li><a href="./conformance.html"><span>Conformance kit</span></a></li>
33
+ <li><a href="./protect-and-sign.html" aria-current="page"><span>Protect and sign</span></a></li>
34
+ <li><a href="./publication-submission.html"><span>Publication and listing</span></a></li>
35
+ </ul>
36
+ <h2>Dynamics</h2><ul>
37
+ <li><a href="./families/propagator.html"><span>Propagator</span><span class="tag tag-shipped">shipped</span></a></li>
38
+ <li><a href="./families/maneuver.html"><span>Maneuver</span><span class="tag tag-experimental">experimental</span></a></li>
39
+ <li><a href="./families/propulsion.html"><span>Propulsion</span><span class="tag tag-planned">planned</span></a></li>
40
+ <li><a href="./families/attitude.html"><span>Attitude</span><span class="tag tag-planned">planned</span></a></li>
41
+ <li><a href="./families/gnc.html"><span>GNC</span><span class="tag tag-planned">planned</span></a></li>
42
+ </ul>
43
+ <h2>Environment and interaction</h2><ul>
44
+ <li><a href="./families/rf.html"><span>RF</span><span class="tag tag-designed">designed</span></a></li>
45
+ <li><a href="./families/sensor.html"><span>Sensor</span><span class="tag tag-planned">planned</span></a></li>
46
+ <li><a href="./families/signature.html"><span>Signature</span><span class="tag tag-planned">planned</span></a></li>
47
+ <li><a href="./families/environment.html"><span>Environment</span><span class="tag tag-planned">planned</span></a></li>
48
+ <li><a href="./families/obstruction.html"><span>Obstruction</span><span class="tag tag-designed">designed</span></a></li>
49
+ </ul>
50
+ <h2>Event physics</h2><ul>
51
+ <li><a href="./families/breakup.html"><span>Breakup</span><span class="tag tag-planned">planned</span></a></li>
52
+ <li><a href="./families/reentry.html"><span>Reentry</span><span class="tag tag-planned">planned</span></a></li>
53
+ <li><a href="./families/conjunction.html"><span>Conjunction</span><span class="tag tag-designed">designed</span></a></li>
54
+ <li><a href="./families/effects.html"><span>Effects</span><span class="tag tag-planned">planned</span></a></li>
55
+ </ul>
56
+ <h2>Estimation, data and logic</h2><ul>
57
+ <li><a href="./families/estimation.html"><span>Estimation</span><span class="tag tag-experimental">experimental</span></a></li>
58
+ <li><a href="./families/data-source.html"><span>Data source</span><span class="tag tag-shipped">shipped</span></a></li>
59
+ <li><a href="./families/analytics.html"><span>Analytics</span><span class="tag tag-experimental">experimental</span></a></li>
60
+ <li><a href="./families/scheduler.html"><span>Scheduler</span><span class="tag tag-planned">planned</span></a></li>
61
+ <li><a href="./families/behavior.html"><span>Behavior</span><span class="tag tag-planned">planned</span></a></li>
62
+ </ul>
63
+ <h2>Runtime contract</h2><ul>
64
+ <li><a href="./events-abi.html"><span>Event locator ABI</span></a></li>
65
+ <li><a href="./module-publication-standard.html"><span>Module publication standard</span></a></li>
66
+ <li><a href="./browser-wasmedge-isomorphic.html"><span>Browser / WasmEdge isomorphism</span></a></li>
67
+ <li><a href="./isomorphic-pthreads.html"><span>Isomorphic pthreads</span></a></li>
68
+ <li><a href="./tri-runtime-parity.html"><span>Tri-runtime parity</span></a></li>
69
+ <li><a href="./tri-runtime-parity-gate.html"><span>Tri-runtime parity gate</span></a></li>
70
+ <li><a href="./testing-harness.html"><span>Testing harness</span></a></li>
71
+ <li><a href="./language-runtime-matrix.html"><span>Language and runtime matrix</span></a></li>
72
+ </ul>
73
+ <h2>Host surfaces</h2><ul>
74
+ <li><a href="./flatsql-host-contract.html"><span>FlatSQL host contract</span></a></li>
75
+ <li><a href="./flatsql-streaming-standard.html"><span>FlatSQL streaming standard</span></a></li>
76
+ <li><a href="./secrets-capability.html"><span>Credential lanes</span></a></li>
77
+ <li><a href="./protocol-installation.html"><span>Protocol installation</span></a></li>
78
+ <li><a href="./gpu-module-abi.html"><span>GPU module ABI</span></a></li>
79
+ <li><a href="./module-bundle-runtime-plan.html"><span>Module bundle runtime</span></a></li>
80
+ <li><a href="./isomorphic-sdn-runtime-plan.html"><span>Isomorphic SDN runtime</span></a></li>
81
+ <li><a href="./node-red-default-node-parity.html"><span>Node-RED node parity</span></a></li>
82
+ </ul>
83
+ </nav>
84
+ <main class="doc" id="main">
85
+ <h1>Protect and sign</h1>
86
+ <p>Once a module passes conformance and the parity gate, it is protected (optionally encrypted, with its manifest attached), signed, and verified. All three verbs are implemented today in <code>space-data-module</code>.</p>
87
+ <h2 id="artifact-layout"><a class="anchor" href="#artifact-layout" aria-hidden="true">#</a>Artifact layout</h2>
88
+ <p>A protected, published artifact is a single file:</p>
89
+ <div class="codeblock"><pre><code>protected-payload-bytes || REC-flatbuffer-bytes || uint32le(REC length) || &quot;$REC&quot;</code></pre></div>
90
+ <p>The trailer is appended after the payload, so a consumer reads the last four bytes for the <code>$REC</code> magic, then the preceding little-endian <code>uint32</code> length, then the record. The record types themselves (<code>REC</code>, <code>MBL</code>, <code>PNM</code>, <code>ENC</code>) are Space Data Standards messages; this SDK consumes the generated classes, it does not define them. See the <a href="./module-publication-standard.html">module publication standard</a>.</p>
91
+ <h2 id="protect"><a class="anchor" href="#protect" aria-hidden="true">#</a>Protect</h2>
92
+ <p><code>protect</code> attaches the manifest to the artifact and, when a recipient key is supplied, encrypts the payload for that recipient.</p>
93
+ <div class="codeblock"><div class="codeblock-head">sh</div><pre><code>space-data-module protect \
94
+ --manifest ./manifest.json \
95
+ --wasm ./dist/module.wasm \
96
+ --json</code></pre></div>
97
+ <div class="codeblock"><div class="codeblock-head">sh</div><pre><code># encrypted for a specific recipient
98
+ space-data-module protect \
99
+ --manifest ./manifest.json \
100
+ --wasm ./dist/module.wasm \
101
+ --recipient-public-key &lt;hex&gt; \
102
+ --out ./dist/module.wasm.enc</code></pre></div>
103
+ <div class="codeblock"><div class="codeblock-head">sh</div><pre><code># single-file bundle
104
+ space-data-module protect \
105
+ --manifest ./manifest.json \
106
+ --wasm ./dist/module.wasm \
107
+ --single-file-bundle \
108
+ --out ./dist/module.bundle.wasm</code></pre></div>
109
+ <div class="table-wrap"><table><thead><tr><th>Flag</th><th>Required</th><th>Meaning</th></tr></thead><tbody><tr><td><code>--manifest &lt;path&gt;</code></td><td>yes</td><td>Module manifest JSON</td></tr><tr><td><code>--wasm &lt;path&gt;</code></td><td>yes</td><td>The compiled artifact</td></tr><tr><td><code>--recipient-public-key &lt;hex&gt;</code></td><td>no</td><td>Encrypt the payload for this recipient</td></tr><tr><td><code>--mnemonic &lt;words&gt;</code></td><td>no</td><td>Key material for the protecting identity</td></tr><tr><td><code>--single-file-bundle</code></td><td>no</td><td>Emit one self-contained bundle artifact</td></tr><tr><td><code>--out &lt;path&gt;</code></td><td>no</td><td>Output path; otherwise reported on stdout</td></tr><tr><td><code>--json</code></td><td>no</td><td>Machine-readable result</td></tr></tbody></table></div>
110
+ <p>Non-JSON output reports <code>artifactId</code>, <code>signingPublicKeyHex</code>, <code>encrypted</code>, <code>wasmBase64Length</code>, and <code>protectedArtifactBytes</code>.</p>
111
+ <h2 id="sign"><a class="anchor" href="#sign" aria-hidden="true">#</a>Sign</h2>
112
+ <div class="codeblock"><div class="codeblock-head">sh</div><pre><code>space-data-module sign \
113
+ --wasm ./dist/module.wasm \
114
+ --key ./keys/module-signing-keypair.json \
115
+ --out ./dist/module.signed.wasm</code></pre></div>
116
+ <div class="table-wrap"><table><thead><tr><th>Flag</th><th>Required</th><th>Meaning</th></tr></thead><tbody><tr><td><code>--wasm &lt;path&gt;</code></td><td>yes</td><td>Artifact to sign</td></tr><tr><td><code>--key &lt;path&gt;</code></td><td>yes</td><td>Keypair JSON; must contain <code>privateKeySeedHex</code></td></tr><tr><td><code>--out &lt;path&gt;</code></td><td>no</td><td>Output path; otherwise the input is signed in place</td></tr></tbody></table></div>
117
+ <p>The key file must carry <code>privateKeySeedHex</code> or the command refuses. Output reports <code>signed</code>, <code>keyId</code>, <code>publicKeyHex</code>, and <code>canonicalModuleHashHex</code> — the canonical hash is what a verifier recomputes, so it is stable across the appended trailer.</p>
118
+ <h2 id="verify"><a class="anchor" href="#verify" aria-hidden="true">#</a>Verify</h2>
119
+ <div class="codeblock"><div class="codeblock-head">sh</div><pre><code>space-data-module verify \
120
+ --wasm ./dist/module.wasm \
121
+ --trusted &lt;pubKeyHex&gt;[,&lt;pubKeyHex&gt;...] \
122
+ --require-signature</code></pre></div>
123
+ <div class="codeblock"><div class="codeblock-head">sh</div><pre><code>space-data-module verify \
124
+ --wasm ./dist/module.wasm \
125
+ --key ./keys/module-signing-keypair.json</code></pre></div>
126
+ <p><code>--trusted</code> takes a comma-separated list of trusted public keys; <code>--key</code> reads <code>publicKeyHex</code> out of a keypair JSON instead. Signature requirement defaults to true. Output reports <code>verified</code>, <code>signed</code>, <code>keyId</code>, <code>publicKeyHex</code>, and the process exits non-zero unless verification succeeded.</p>
127
+ <h2 id="key-custody"><a class="anchor" href="#key-custody" aria-hidden="true">#</a>Key custody</h2>
128
+ <p>Signing keys are HD-derived from a node's root identity by default; supplying an external key is an explicit opt-in. Never commit a private key or a mnemonic to a repository, and never paste one into a build log. The dev keypairs that appear in the SDK's own test fixtures are test material and are not valid for a published module.</p>
129
+ <h2 id="honest-gaps"><a class="anchor" href="#honest-gaps" aria-hidden="true">#</a>Honest gaps</h2>
130
+ <ul>
131
+ <li>There is no <code>license</code> CLI verb. A <code>src/licensing/</code> module exists in the tree and is used programmatically, but it is not wired to a <code>space-data-module</code> subcommand.</li>
132
+ <li><code>protect</code>, <code>sign</code> and <code>verify</code> are artifact-level primitives. There is no single end-to-end &quot;release this module&quot; command; see <a href="./publication-submission.html">Publication and listing</a>.</li>
133
+ </ul>
134
+
135
+ <p class="doc-footer">
136
+ Source of truth for this page:
137
+ <code>docs/protect-and-sign.md</code>. Regenerate with
138
+ <code>npm run build:docs</code>.
139
+ </p>
140
+ </main>
141
+ <nav class="rail" aria-label="On this page"><h2>On this page</h2><ul><li><a class="depth-2" href="#artifact-layout">Artifact layout</a></li>
142
+ <li><a class="depth-2" href="#protect">Protect</a></li>
143
+ <li><a class="depth-2" href="#sign">Sign</a></li>
144
+ <li><a class="depth-2" href="#verify">Verify</a></li>
145
+ <li><a class="depth-2" href="#key-custody">Key custody</a></li>
146
+ <li><a class="depth-2" href="#honest-gaps">Honest gaps</a></li></ul></nav>
147
+ </div>
148
+ <section id="stack" class="section" aria-labelledby="stack-title">
149
+ <div class="section-head">
150
+ <p class="eyebrow">SDN Stack</p>
151
+ <h2 id="stack-title">Connected sites</h2>
152
+ </div>
153
+ <div class="link-list">
154
+ <a href="https://spacedatastandards.org/">
155
+ <span>Standards</span>
156
+ <small>Canonical schemas, record contracts, and generated bindings.</small>
157
+ </a>
158
+ <a href="https://digitalarsenal.github.io/flatbuffers/">
159
+ <span>FlatBuffers</span>
160
+ <small>Binary encoding, schema tooling, and runtime documentation.</small>
161
+ </a>
162
+ <a href="https://digitalarsenal.github.io/flatsql/">
163
+ <span>FlatSQL</span>
164
+ <small>SQL-style queries over FlatBuffer-backed datasets and streams.</small>
165
+ </a>
166
+ <a href="https://spacedatanetwork.org/">
167
+ <span>SDN</span>
168
+ <small>Distributed publication, discovery, delivery, and marketplace infrastructure.</small>
169
+ </a>
170
+ <a href="https://digitalarsenal.github.io/space-data-module-sdk/" class="active">
171
+ <span>Module SDK</span>
172
+ <small>WASM module packaging, validation, and host compatibility tooling.</small>
173
+ </a>
174
+ </div>
175
+ </section>
176
+ <footer class="site-footer">
177
+ Space Data Module SDK — Apache-2.0. Every ABI page renders a Markdown
178
+ source in <code>docs/</code>; edit the Markdown, never the HTML.
179
+ </footer>
180
+ </body>
181
+ </html>
@@ -0,0 +1,120 @@
1
+ # Protect and sign
2
+
3
+ Once a module passes conformance and the parity gate, it is protected
4
+ (optionally encrypted, with its manifest attached), signed, and verified. All
5
+ three verbs are implemented today in `space-data-module`.
6
+
7
+ ## Artifact layout
8
+
9
+ A protected, published artifact is a single file:
10
+
11
+ ```
12
+ protected-payload-bytes || REC-flatbuffer-bytes || uint32le(REC length) || "$REC"
13
+ ```
14
+
15
+ The trailer is appended after the payload, so a consumer reads the last four
16
+ bytes for the `$REC` magic, then the preceding little-endian `uint32` length,
17
+ then the record. The record types themselves (`REC`, `MBL`, `PNM`, `ENC`) are
18
+ Space Data Standards messages; this SDK consumes the generated classes, it does
19
+ not define them. See the
20
+ [module publication standard](module-publication-standard.html).
21
+
22
+ ## Protect
23
+
24
+ `protect` attaches the manifest to the artifact and, when a recipient key is
25
+ supplied, encrypts the payload for that recipient.
26
+
27
+ ```sh
28
+ space-data-module protect \
29
+ --manifest ./manifest.json \
30
+ --wasm ./dist/module.wasm \
31
+ --json
32
+ ```
33
+
34
+ ```sh
35
+ # encrypted for a specific recipient
36
+ space-data-module protect \
37
+ --manifest ./manifest.json \
38
+ --wasm ./dist/module.wasm \
39
+ --recipient-public-key <hex> \
40
+ --out ./dist/module.wasm.enc
41
+ ```
42
+
43
+ ```sh
44
+ # single-file bundle
45
+ space-data-module protect \
46
+ --manifest ./manifest.json \
47
+ --wasm ./dist/module.wasm \
48
+ --single-file-bundle \
49
+ --out ./dist/module.bundle.wasm
50
+ ```
51
+
52
+ | Flag | Required | Meaning |
53
+ | --- | --- | --- |
54
+ | `--manifest <path>` | yes | Module manifest JSON |
55
+ | `--wasm <path>` | yes | The compiled artifact |
56
+ | `--recipient-public-key <hex>` | no | Encrypt the payload for this recipient |
57
+ | `--mnemonic <words>` | no | Key material for the protecting identity |
58
+ | `--single-file-bundle` | no | Emit one self-contained bundle artifact |
59
+ | `--out <path>` | no | Output path; otherwise reported on stdout |
60
+ | `--json` | no | Machine-readable result |
61
+
62
+ Non-JSON output reports `artifactId`, `signingPublicKeyHex`, `encrypted`,
63
+ `wasmBase64Length`, and `protectedArtifactBytes`.
64
+
65
+ ## Sign
66
+
67
+ ```sh
68
+ space-data-module sign \
69
+ --wasm ./dist/module.wasm \
70
+ --key ./keys/module-signing-keypair.json \
71
+ --out ./dist/module.signed.wasm
72
+ ```
73
+
74
+ | Flag | Required | Meaning |
75
+ | --- | --- | --- |
76
+ | `--wasm <path>` | yes | Artifact to sign |
77
+ | `--key <path>` | yes | Keypair JSON; must contain `privateKeySeedHex` |
78
+ | `--out <path>` | no | Output path; otherwise the input is signed in place |
79
+
80
+ The key file must carry `privateKeySeedHex` or the command refuses. Output
81
+ reports `signed`, `keyId`, `publicKeyHex`, and `canonicalModuleHashHex` — the
82
+ canonical hash is what a verifier recomputes, so it is stable across the
83
+ appended trailer.
84
+
85
+ ## Verify
86
+
87
+ ```sh
88
+ space-data-module verify \
89
+ --wasm ./dist/module.wasm \
90
+ --trusted <pubKeyHex>[,<pubKeyHex>...] \
91
+ --require-signature
92
+ ```
93
+
94
+ ```sh
95
+ space-data-module verify \
96
+ --wasm ./dist/module.wasm \
97
+ --key ./keys/module-signing-keypair.json
98
+ ```
99
+
100
+ `--trusted` takes a comma-separated list of trusted public keys; `--key` reads
101
+ `publicKeyHex` out of a keypair JSON instead. Signature requirement defaults to
102
+ true. Output reports `verified`, `signed`, `keyId`, `publicKeyHex`, and the
103
+ process exits non-zero unless verification succeeded.
104
+
105
+ ## Key custody
106
+
107
+ Signing keys are HD-derived from a node's root identity by default; supplying an
108
+ external key is an explicit opt-in. Never commit a private key or a mnemonic to
109
+ a repository, and never paste one into a build log. The dev keypairs that appear
110
+ in the SDK's own test fixtures are test material and are not valid for a
111
+ published module.
112
+
113
+ ## Honest gaps
114
+
115
+ - There is no `license` CLI verb. A `src/licensing/` module exists in the tree
116
+ and is used programmatically, but it is not wired to a `space-data-module`
117
+ subcommand.
118
+ - `protect`, `sign` and `verify` are artifact-level primitives. There is no
119
+ single end-to-end "release this module" command; see
120
+ [Publication and listing](publication-submission.html).