@k9o/kibo 1.2.0 → 1.3.0

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.
package/CHANGELOG.md ADDED
@@ -0,0 +1,23 @@
1
+ # Changelog
2
+
3
+ ## 1.3.0 — 2026-10-26
4
+
5
+ ### Changed
6
+
7
+ - `vault.secrets.get(name)` looks the secret up by exact name through the list route and returns its metadata.
8
+ - `region` is optional on every named-secret method.
9
+ - `vault.secrets.revealChallenge` takes an optional `reason`.
10
+ - `KIBO_WASM_ERROR` now says whether the core is missing or present but failed to load.
11
+ - README: `encrypt` and `decrypt` are standalone exports, not methods on the client. The vault is `client.kibo.vault`.
12
+
13
+ ### Removed
14
+
15
+ - Nothing.
16
+
17
+ ### Added
18
+
19
+ - Nothing. `setZkWasm(core)` remains the way to supply your own core.
20
+
21
+ ## 1.0.0
22
+
23
+ First public release.
package/README.md CHANGED
@@ -2,7 +2,8 @@
2
2
 
3
3
  Kibo is the Kilimanjaro vault SDK. Store and reveal secrets, keep wrapped data keys, and encrypt on the client with keys held in your own KMS.
4
4
 
5
- Kilimanjaro is an AI-native platform on a Governed Database. Its products are Keep (AI Security and Governance), Pulse (Data Intelligence), Gate (Customer Identity and Access Management) and Kibo (Keys and Secrets Management).
5
+ Kilimanjaro is the AI-native foundation for building critical applications. Its products are Keep (AI Security and Governance),
6
+ Pulse (Data Intelligence), Gate (Customer Identity and Access Management) and Kibo (Keys and Secrets Management).
6
7
 
7
8
  ## Contents
8
9
 
@@ -14,6 +15,11 @@ Kilimanjaro is an AI-native platform on a Governed Database. Its products are Ke
14
15
  - [Encrypt and decrypt](#encrypt-and-decrypt)
15
16
  - [Handle errors](#handle-errors)
16
17
  - [Appendix](#appendix)
18
+ - [Client options](#client-options)
19
+ - [Methods](#methods)
20
+ - [Encrypt and decrypt fields](#encrypt-and-decrypt-fields)
21
+ - [Error codes](#error-codes)
22
+ - [Related packages](#related-packages)
17
23
 
18
24
  ## Links
19
25
 
@@ -21,11 +27,6 @@ Kilimanjaro is an AI-native platform on a Governed Database. Its products are Ke
21
27
  - Documentation / Developer Hub: <https://docs.kilimanjaro.dev>
22
28
  - Platform API: <https://api.k9o.io>
23
29
  - Platform Console: <https://console.k9o.io>
24
- - [Client options](#client-options)
25
- - [Methods](#methods)
26
- - [Encrypt and decrypt fields](#encrypt-and-decrypt-fields)
27
- - [Error codes](#error-codes)
28
- - [Related packages](#related-packages)
29
30
 
30
31
  ## Install
31
32
 
@@ -36,8 +37,9 @@ npm install @k9o/kibo @k9o/core
36
37
  Bun works too: `bun add @k9o/kibo @k9o/core`.
37
38
 
38
39
  - Needs a runtime with global `fetch`: Node 18+, Bun 1.1+, or a modern browser.
39
- - Needs `@k9o/core`, which provides the client. The vault is available as `client.kibo`.
40
- - `encrypt` and `decrypt` also need the Kibo core (WebAssembly). See [encrypt and decrypt](#encrypt-and-decrypt).
40
+ - Needs `@k9o/core`, which provides the client. The vault is `client.kibo.vault`.
41
+ - `encrypt` and `decrypt` are standalone exports of `@k9o/kibo`, not methods on the client.
42
+ - They use the Kibo core (WebAssembly), which the package ships. See [encrypt and decrypt](#encrypt-and-decrypt).
41
43
 
42
44
  ## Quick start
43
45
 
@@ -55,13 +57,12 @@ const client = createClient({
55
57
 
56
58
  For a custom host, pass the full organization host as `baseUrl` and `projectSlug`, and leave out `orgSlug`. See [client options](#client-options).
57
59
 
58
- Create a secret. `region` is required for every secret method except `list`.
60
+ Create a secret. `region` is optional on every secret method. Pass it to pin a region, such as `region: "de01"`.
59
61
 
60
62
  ```ts
61
63
  const created = await client.kibo.vault.secrets.create({
62
64
  name: "tasks/webhook-signing-key",
63
65
  value: "whsec_example",
64
- region: "de01",
65
66
  });
66
67
  const secret = created.data;
67
68
 
@@ -87,16 +88,30 @@ for (const item of secrets) {
87
88
  tasks/webhook-signing-key 1
88
89
  ```
89
90
 
91
+ Read one secret's metadata by its exact name. This does not reveal the value.
92
+
93
+ ```ts
94
+ const found = await client.kibo.vault.secrets.get("tasks/webhook-signing-key");
95
+
96
+ console.log(found.data.name, found.data.version);
97
+ ```
98
+
99
+ ```text
100
+ tasks/webhook-signing-key 1
101
+ ```
102
+
90
103
  Every method resolves to `{ data, meta }`. See [methods](#methods) for the full list.
91
104
 
92
105
  ## Reveal a secret
93
106
 
94
107
  Revealing takes two calls: ask for a single-use challenge, then present it.
108
+ A plain read of a secret is a reveal, so it is refused without the challenge.
95
109
 
96
110
  ```ts
97
- const challenge = await client.kibo.vault.secrets.revealChallenge("tasks/webhook-signing-key", { region: "de01" });
111
+ const challenge = await client.kibo.vault.secrets.revealChallenge("tasks/webhook-signing-key", {
112
+ reason: "rotate the webhook endpoint",
113
+ });
98
114
  const revealed = await client.kibo.vault.secrets.reveal("tasks/webhook-signing-key", {
99
- region: "de01",
100
115
  challenge: challenge.data.challenge,
101
116
  });
102
117
 
@@ -129,22 +144,23 @@ aws-kms
129
144
 
130
145
  ## Encrypt and decrypt
131
146
 
132
- `encrypt` and `decrypt` run on your machine against your own KMS. They wrap the Kibo core, a WebAssembly module.
133
- This package has no cryptography of its own.
147
+ `encrypt` and `decrypt` run on your machine against your own KMS. They make no call to the platform.
148
+ They wrap the Kibo core, a WebAssembly module. This package has no cryptography of its own.
134
149
 
135
- - The core is loaded from `wasm/kibo_kms_rest_ffi.js` inside the package.
136
- - Or load it yourself and pass it to `setZkWasm`.
137
- - Without the core, both calls fail with `KIBO_WASM_ERROR`. See [handle errors](#handle-errors).
150
+ - The package ships the core under `wasm/` and loads it on first use.
151
+ - To use your own build, load it and pass it to `setZkWasm(core)`.
152
+ - A missing or unloadable core fails with `KIBO_WASM_ERROR`. The message says which. See [handle errors](#handle-errors).
138
153
  - The vault methods above work without the core.
139
154
 
140
155
  ```ts
141
156
  import { encrypt, decrypt } from "@k9o/kibo";
157
+ import type { KiboEncryptInput } from "@k9o/kibo";
142
158
 
143
159
  const kmsToken = process.env.KMS_FEDERATED_TOKEN ?? "";
144
160
  const context = [{ key: "collection", value: "tasks" }];
145
161
  const title = new TextEncoder().encode("Write the README");
146
162
 
147
- const sealed = await encrypt({
163
+ const input: KiboEncryptInput = {
148
164
  provider: "aws-kms",
149
165
  posture: "byok",
150
166
  kms_cred: { secret: kmsToken, expires_at_unix_secs: 1_800_000_000 },
@@ -153,7 +169,9 @@ const sealed = await encrypt({
153
169
  attestation_tier: "software",
154
170
  encryption_context: context,
155
171
  plaintext: title,
156
- });
172
+ };
173
+
174
+ const sealed = await encrypt(input);
157
175
 
158
176
  const opened = await decrypt({
159
177
  kms_cred: { secret: kmsToken, expires_at_unix_secs: 1_800_000_000 },
@@ -177,7 +195,7 @@ Write the README
177
195
 
178
196
  ## Handle errors
179
197
 
180
- Every failure is a `KError` from `@k9o/core`. Check `code`.
198
+ Every failure is a `KError` from `@k9o/core`. Check `code`. The `input` is the one from the previous section.
181
199
 
182
200
  ```ts
183
201
  import { KError } from "@k9o/core";
@@ -187,15 +205,17 @@ try {
187
205
  await encrypt(input);
188
206
  } catch (error) {
189
207
  if (error instanceof KError && error.code === "KIBO_WASM_ERROR") {
190
- console.log(error.message);
208
+ console.log(error.code);
191
209
  }
192
210
  }
193
211
  ```
194
212
 
195
213
  ```text
196
- the Kibo zero-knowledge core (wasm) is not bundled in this build of @k9o/kibo; encrypt and decrypt are unavailable
214
+ KIBO_WASM_ERROR
197
215
  ```
198
216
 
217
+ The `message` says whether the core is missing or is present but failed to load.
218
+
199
219
  See [error codes](#error-codes).
200
220
 
201
221
  ## Appendix
@@ -218,14 +238,14 @@ All are under `client.kibo.vault`.
218
238
  | Method | What it does |
219
239
  |---|---|
220
240
  | `secrets.list({ prefix?, cursor?, limit? })` | List secret metadata |
221
- | `secrets.get(name, { region })` | Read one secret's metadata |
222
- | `secrets.create({ name, value, region, visibility?, metadata? })` | Seal a new secret |
223
- | `secrets.revealChallenge(name, { region })` | Mint a single-use reveal challenge |
224
- | `secrets.reveal(name, { region, challenge })` | Return the plaintext value |
225
- | `secrets.update(name, { region, value, metadata? })` | Set a new value and bump the version |
226
- | `secrets.rotate(name, { region })` | Re-wrap the secret under a fresh key |
227
- | `secrets.move(name, { region, newPath })` | Rename the secret's path |
228
- | `secrets.delete(name, { region })` | Retire the secret |
241
+ | `secrets.get(name)` | Find one secret by exact name through the list route; returns its metadata |
242
+ | `secrets.create({ name, value, region?, visibility?, metadata? })` | Seal a new secret |
243
+ | `secrets.revealChallenge(name, { region?, reason? })` | Mint a single-use reveal challenge |
244
+ | `secrets.reveal(name, { challenge, region? })` | Return the plaintext value |
245
+ | `secrets.update(name, { value, region?, metadata? })` | Set a new value and bump the version |
246
+ | `secrets.rotate(name, { region? })` | Re-wrap the secret under a fresh key |
247
+ | `secrets.move(name, { newPath, region? })` | Rename the secret's path |
248
+ | `secrets.delete(name, { region? })` | Retire the secret |
229
249
  | `zkDeks.store({ envelope, provider, keyVersionRef })` | Store a wrapped data key envelope |
230
250
  | `zkDeks.fetch(id)` | Fetch a stored envelope by its handle |
231
251
 
@@ -235,7 +255,7 @@ Exported from `@k9o/kibo` directly:
235
255
  |---|---|
236
256
  | `encrypt(input)` | Encrypt bytes with your KMS; returns `{ envelope }` |
237
257
  | `decrypt(input)` | Decrypt an envelope; returns `{ plaintext }` |
238
- | `setZkWasm(core)` | Supply the Kibo core yourself |
258
+ | `setZkWasm(core)` | Supply your own Kibo core instead of the shipped one |
239
259
  | `createKiboClient(config)` | Build a vault client from a core HTTP config |
240
260
 
241
261
  `visibility` is `{ kind: "private" }` (default) or `{ kind: "shared", principals?, roles? }`.
@@ -261,7 +281,7 @@ Exported from `@k9o/kibo` directly:
261
281
 
262
282
  | Code | When |
263
283
  |---|---|
264
- | `KIBO_WASM_ERROR` | The Kibo core is not bundled in your build and was not supplied |
284
+ | `KIBO_WASM_ERROR` | The Kibo core is missing, or is present but failed to load; the message says which |
265
285
  | `KIBO_WASM_DECODE_ERROR` | The core returned something other than bytes |
266
286
  | `K9O_CRYPTO_POSTURE_FLOOR_VIOLATION` | `posture` is below the floor in `posture_policy`; `context` has `dimension`, `requested`, `declared` |
267
287
  | `UPSTREAM_KMS_ERROR` | Your own KMS failed the call |
@@ -273,7 +293,7 @@ Other codes from the core are passed through unchanged.
273
293
 
274
294
  | Package | Purpose |
275
295
  |---|---|
276
- | `@k9o/core` | The platform SDK; composes this package as `client.kibo` |
296
+ | `@k9o/core` | The platform SDK; exposes the vault as `client.kibo.vault` |
277
297
  | `@k9o/kibo-react-native` | Client-side encryption for React Native |
278
298
  | `@k9o/cli` | `k9o vault-secret` works with the same secrets |
279
299
 
package/dist/index.d.ts CHANGED
@@ -4,18 +4,17 @@ import { StoreZkDekInput, ZkDekHandle, ZkDekRecord, ListSecretsInput, ListSecret
4
4
  export { AttestationTier, SecretVisibility } from './types.js';
5
5
 
6
6
  /**
7
- * `client.kibo.vault.*` — the Kibo vault surface.
7
+ * `client.kibo.vault.*` - the Kibo vault surface.
8
8
  *
9
- * `vault.zkDeks.{store,fetch}` — member-plane,
10
- * project-scoped storage of the opaque customer-wrapped DEK envelope. Zero
11
- * crypto SDK-side: this is a plain authenticated REST round-trip carrying an
12
- * opaque blob (the wrapping happens in the ZK core, piece C). The encryption
13
- * surface (`kibo.encrypt`/`decrypt`) is provided by the ZK core binding when it is
14
- * bundled.
9
+ * `vault.zkDeks.{store,fetch}` store and fetch the opaque customer-wrapped DEK envelope, project-scoped. There is
10
+ * no cryptography in this client: it is a plain authenticated REST round-trip carrying an opaque blob (the
11
+ * wrapping happens in the standalone `encrypt`/`decrypt`, which never call the platform).
12
+ * `vault.secrets.*` is the typed secrets family.
15
13
  */
16
14
 
15
+ /** @internal */
17
16
  declare function makeVaultNamespace(config: HttpClientConfig): {
18
- /** ZK-DEK opaque store/fetch (F.5). */
17
+ /** Opaque store/fetch of a customer-wrapped DEK envelope. */
19
18
  zkDeks: {
20
19
  /**
21
20
  * Store an opaque customer-wrapped DEK envelope.
@@ -31,78 +30,65 @@ declare function makeVaultNamespace(config: HttpClientConfig): {
31
30
  fetch(id: string): Promise<Envelope<ZkDekRecord>>;
32
31
  };
33
32
  /**
34
- * typed secrets surface (`services/gateway/src/routes/vault-secrets.ts`) — the full family:
35
- * list/get/create/revealChallenge/reveal/update/rotate/move/delete. Every operation on a NAMED
36
- * secret (everything except `list`) requires `region` — live-verified against staging, not
37
- * documented in the route's OpenAPI schema. `list` is the one exception (verified it does NOT
38
- * need `region`).
33
+ * Typed secrets surface (`/@<projectSlug>/vault/secrets`): list / get / create / revealChallenge / reveal /
34
+ * update / rotate / move / delete.
39
35
  *
40
- * Response shapes for `update`/`rotate`/`move` are typed to what the gateway ACTUALLY returns
41
- * (live-verified), not the OpenAPI's documented (and inaccurate for these three) `SecretSummary` —
42
- * see the 🔴 notes on `UpdateSecretResult`/`RotateSecretResult`/`MoveSecretResult` in `types.ts`.
36
+ * `region`: the gateway sets the residency region of every vault call itself and discards a caller-supplied
37
+ * `region` query parameter, so it is optional on every method. When given, it is still sent (older gateways
38
+ * required it).
39
+ *
40
+ * Response shapes for `update`/`rotate`/`move` are typed to what the gateway returns, not the OpenAPI's
41
+ * `SecretSummary` (see `UpdateSecretResult`/`RotateSecretResult`/`MoveSecretResult` in `types.ts`).
43
42
  */
44
43
  secrets: {
45
- /** List secrets (metadata only — never lists ciphertext). `GET /@<projectSlug>/vault/secrets`.
46
- * The one secrets operation that does NOT need `region` (live-verified). */
47
- list(input?: ListSecretsInput): Promise<Envelope<ListSecretsResult>>;
44
+ /** List secrets (metadata only, never ciphertext). `GET /@<projectSlug>/vault/secrets`. */
45
+ list: (input?: ListSecretsInput) => Promise<Envelope<ListSecretsResult>>;
48
46
  /**
49
- * Read a secret's metadata (never its value — use `revealChallenge`+`reveal` for that).
50
- * `GET /@<projectSlug>/vault/secrets/<name>?region=<region>`.
47
+ * Read one secret's metadata (never its value; use `revealChallenge` + `reveal` for that).
51
48
  *
52
- * 🔴 KNOWN LIVE BUG (staging, 2026-09-05): this call currently fails with
53
- * `K9O_REVEAL_CHALLENGE_REQUIRED` on every attempt — the gateway/kibo does not honor the
54
- * documented "no `X-K9O-Reveal-Challenge` header ⇒ return metadata" behavior; it demands a
55
- * challenge unconditionally. Implemented per the documented contract (this is a backend defect,
56
- * not a client workaround); `list({prefix: exactName})` is the current working alternative for a
57
- * single secret's metadata until the gateway/kibo side is fixed.
49
+ * Vault answers a `GET /@<projectSlug>/vault/secrets/<name>` only as a reveal: with no
50
+ * `X-K9O-Reveal-Challenge` header it refuses with 401 `K9O_REVEAL_CHALLENGE_REQUIRED`, whatever the caller's
51
+ * rights. There is no plain metadata read on that route, so `get` reads the metadata the route that exists
52
+ * for it returns: it lists by the exact name as prefix and picks the exact match. It throws `K9O_NOT_FOUND`
53
+ * (status 404) when no secret has that name.
58
54
  */
59
- get(name: string, opts: {
60
- region: string;
55
+ get(name: string, _opts?: {
56
+ region?: string;
61
57
  }): Promise<Envelope<SecretSummary>>;
62
58
  /**
63
59
  * Create a secret under the caller's own auth.
64
- * `POST /@<projectSlug>/vault/secrets/<name>?region=<region>` → the `sec_<base62>` summary.
65
- *
66
- * 🔴 `region` is REQUIRED on the query string, live-verified against staging — the vault-forward
67
- * proxy fail-closes with `K9O_INVALID_FIELD_VALUE` ("this request requires an authoritative
68
- * region") without it. Distinct from any `region` carried inside `input.value`'s envelope (e.g.
69
- * the BYOS aws_sigv4 STS-signing region): this one scopes the vault WRITE itself, mirroring the
70
- * gateway's `gatewayRegion()` residency guard (region-guard.ts) that closed a 2026-08 wrong-region
71
- * incident for the audit path — the request-shape unit tests never caught this because they don't
72
- * exercise a real gateway.
60
+ * `POST /@<projectSlug>/vault/secrets/<name>` -> the `sec_<base62>` summary.
73
61
  */
74
62
  create(input: CreateSecretInput): Promise<Envelope<SecretSummary>>;
75
- /** Mint a single-use reveal challenge — present it as `X-K9O-Reveal-Challenge` on the
76
- * immediately-following `reveal()` call. `POST .../<name>?op=reveal-challenge&region=<region>`. */
77
- revealChallenge(name: string, opts: {
78
- region: string;
63
+ /** Mint a single-use reveal challenge; pass it to the immediately-following `reveal()`.
64
+ * `POST .../<name>?op=reveal-challenge`. The optional `reason` is accepted by the gateway and not forwarded. */
65
+ revealChallenge(name: string, opts?: {
66
+ region?: string;
67
+ reason?: string;
79
68
  }): Promise<Envelope<RevealChallenge>>;
80
69
  /** Reveal a secret's plaintext value using a single-use challenge from `revealChallenge()`.
81
- * `GET .../<name>?region=<region>` with `X-K9O-Reveal-Challenge`. Decodes the wire's base64
82
- * `value` back to plaintext (live-verified: the reveal response's `value` is base64, symmetric
83
- * with `create`'s encode). */
70
+ * `GET .../<name>` with `X-K9O-Reveal-Challenge`. Decodes the wire's base64 `value` back to plaintext
71
+ * (symmetric with `create`'s encode). */
84
72
  reveal(name: string, opts: {
85
- region: string;
73
+ region?: string;
86
74
  challenge: string;
87
75
  }): Promise<Envelope<RevealSecretResult>>;
88
- /** Update a secret's value (bumps version) — owner-only. `PUT .../<name>?region=<region>`.
89
- * 🔴 Returns only `{id, name, version}` live (see `UpdateSecretResult`), not the full summary
90
- * the OpenAPI schema documents — call `get()` after if you need the rest. */
76
+ /** Update a secret's value (bumps version), owner-only. `PUT .../<name>`.
77
+ * Returns only `{id, name, version}` (see `UpdateSecretResult`); call `get()` after for the rest. */
91
78
  update(name: string, input: UpdateSecretInput): Promise<Envelope<UpdateSecretResult>>;
92
- /** Rotate a secret's wrapping key (re-wraps under a fresh `kid`; content unchanged) — owner-only.
93
- * `POST .../<name>?op=rotate&region=<region>`. */
94
- rotate(name: string, opts: {
95
- region: string;
79
+ /** Rotate a secret's wrapping key (re-wraps under a fresh `kid`; content unchanged), owner-only.
80
+ * `POST .../<name>?op=rotate`. */
81
+ rotate(name: string, opts?: {
82
+ region?: string;
96
83
  }): Promise<Envelope<RotateSecretResult>>;
97
- /** Move (rename) a secret's hierarchical path — owner-only.
98
- * `POST .../<name>?op=move&region=<region>`. */
84
+ /** Move (rename) a secret's hierarchical path, owner-only. `POST .../<name>?op=move`. */
99
85
  move(name: string, opts: {
100
- region: string;
86
+ region?: string;
101
87
  newPath: string;
102
88
  }): Promise<Envelope<MoveSecretResult>>;
103
- /** Retire a secret — owner-only. `DELETE .../<name>?region=<region>` → `204 No Content`. */
104
- delete(name: string, opts: {
105
- region: string;
89
+ /** Retire a secret, owner-only. `DELETE .../<name>`. */
90
+ delete(name: string, opts?: {
91
+ region?: string;
106
92
  }): Promise<Envelope<void>>;
107
93
  };
108
94
  };
@@ -118,7 +104,7 @@ declare function makeVaultNamespace(config: HttpClientConfig): {
118
104
 
119
105
  /** Shape of the per-instance client returned by `createKiboClient`. */
120
106
  type KiboClient = {
121
- /** Vault surface — `client.kibo.vault.zkDeks.{store,fetch}` (F.5). */
107
+ /** Vault surface: `vault.secrets.*` and `vault.zkDeks.{store,fetch}`. */
122
108
  vault: ReturnType<typeof makeVaultNamespace>;
123
109
  };
124
110
  /** Construct a Kibo client bound to the supplied (core) HTTP config. */
@@ -126,7 +112,7 @@ declare function createKiboClient(config: HttpClientConfig): KiboClient;
126
112
 
127
113
  /**
128
114
  * TS contract for the ZK encrypt/decrypt FFI surface — mirrors the Rust
129
- * `kibo-kms-rest-ffi::types` (the bound core, piece C) field-for-field.
115
+ * `kibo-kms-rest-ffi::types` (the bound core) field-for-field.
130
116
  *
131
117
  * These types cross the wasm boundary as plain JS objects (serde-wasm-bindgen),
132
118
  * so the field names + enum wire-tokens must match the Rust serde exactly:
@@ -156,7 +142,7 @@ interface KiboAllowedOracleModes {
156
142
  brokered: boolean;
157
143
  direct: boolean;
158
144
  }
159
- /** Project-declared crypto-posture floor. Omit fields for the
145
+ /** Project-declared crypto-posture floor . Omit fields for the
160
146
  * most-permissive default (`platform_managed` floor + both oracle modes). */
161
147
  interface KiboPosturePolicy {
162
148
  min_custody_posture?: KiboMinPosture;
@@ -225,7 +211,7 @@ interface KiboDecryptOutput {
225
211
 
226
212
  /**
227
213
  * ZK encrypt/decrypt — the thin TS wrapper over the bound crypto core
228
- * (`kibo-kms-rest-ffi`, piece C) compiled to wasm. ZERO crypto here: every
214
+ * (`kibo-kms-rest-ffi`) compiled to wasm. ZERO crypto here: every
229
215
  * wrap/unwrap, envelope framing, posture-floor enforcement, and KMS round-trip
230
216
  * lives in the audited Rust core. This layer only marshals the typed input
231
217
  * across the wasm boundary and maps the core's error string → `KError`.
@@ -234,9 +220,9 @@ interface KiboDecryptOutput {
234
220
  * objects via serde-wasm-bindgen, and rejecting with the `ZkFfiError` display
235
221
  * string (`"<K9O_CODE>: <message>"`, optionally with a posture-violation tail).
236
222
  *
237
- * Composes into `@k9o/core` as `client.kibo.encrypt`/`decrypt`; the F.5
238
- * `vault.zkDeks.{store,fetch}` surface (envelope persistence) is separate +
239
- * decoupled (the core never sees the store).
223
+ * These are standalone exports (`import { encrypt, decrypt } from "@k9o/kibo"`), not methods of the client: they run
224
+ * locally against the customer's own KMS and make no platform call. The `vault.zkDeks.{store,fetch}` surface
225
+ * (envelope persistence) is separate and decoupled (the core never sees the store).
240
226
  */
241
227
 
242
228
  /** The minimal surface the bound ZK-core wasm exposes. */
@@ -252,7 +238,7 @@ interface ZkWasm {
252
238
  declare function setZkWasm(mod: ZkWasm): void;
253
239
  /**
254
240
  * Encrypt `input.plaintext` via the customer KMS, client-side. Returns the
255
- * opaque ZKFE envelope — store it via `vault.zkDeks.store` (F.5) or keep it
241
+ * opaque ZKFE envelope — store it via `vault.zkDeks.store` or keep it
256
242
  * yourself; it is meaningless to the platform.
257
243
  */
258
244
  declare function encrypt(input: KiboEncryptInput): Promise<KiboEncryptOutput>;
@@ -263,4 +249,4 @@ declare function encrypt(input: KiboEncryptInput): Promise<KiboEncryptOutput>;
263
249
  */
264
250
  declare function decrypt(input: KiboDecryptInput): Promise<KiboDecryptOutput>;
265
251
 
266
- export { CreateSecretInput, type KiboAllowedOracleModes, type KiboAttestationTier, type KiboClient, type KiboCredential, type KiboDecryptInput, type KiboDecryptOutput, type KiboEncryptInput, type KiboEncryptOutput, type KiboKeyRef, type KiboKvPair, type KiboMinPosture, type KiboOracleMode, type KiboPosture, type KiboPosturePolicy, type KiboProviderConfig, type KiboStrategy, KmsProvider, ListSecretsInput, ListSecretsResult, MoveSecretResult, RevealChallenge, RevealSecretResult, RotateSecretResult, SecretSummary, StoreZkDekInput, UpdateSecretInput, UpdateSecretResult, ZkDekHandle, ZkDekRecord, type ZkWasm, createKiboClient, decrypt, encrypt, makeVaultNamespace, setZkWasm };
252
+ export { CreateSecretInput, type KiboAllowedOracleModes, type KiboAttestationTier, type KiboClient, type KiboCredential, type KiboDecryptInput, type KiboDecryptOutput, type KiboEncryptInput, type KiboEncryptOutput, type KiboKeyRef, type KiboKvPair, type KiboMinPosture, type KiboOracleMode, type KiboPosture, type KiboPosturePolicy, type KiboProviderConfig, type KiboStrategy, KmsProvider, ListSecretsInput, ListSecretsResult, MoveSecretResult, RevealChallenge, RevealSecretResult, RotateSecretResult, SecretSummary, StoreZkDekInput, UpdateSecretInput, UpdateSecretResult, ZkDekHandle, ZkDekRecord, type ZkWasm, createKiboClient, decrypt, encrypt, setZkWasm };