@bandeira-tech/b3nd-save 0.8.1
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/LICENSE +21 -0
- package/esm/_dnt.shims.d.ts +2 -0
- package/esm/_dnt.shims.d.ts.map +1 -0
- package/esm/_dnt.shims.js +57 -0
- package/esm/byte-entity-shim.d.ts +47 -0
- package/esm/byte-entity-shim.d.ts.map +1 -0
- package/esm/byte-entity-shim.js +138 -0
- package/esm/clients/mod.d.ts +15 -0
- package/esm/clients/mod.d.ts.map +1 -0
- package/esm/clients/mod.js +14 -0
- package/esm/clients/save-client.d.ts +87 -0
- package/esm/clients/save-client.d.ts.map +1 -0
- package/esm/clients/save-client.js +174 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/mod.d.ts +40 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/mod.js +31 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/client-console/client.d.ts +30 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/client-console/client.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/client-console/client.js +70 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encoding/encoding.d.ts +16 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encoding/encoding.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encoding/encoding.js +50 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encrypt/mod.d.ts +235 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encrypt/mod.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encrypt/mod.js +619 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/functional-client/functional-client.d.ts +43 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/functional-client/functional-client.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/functional-client/functional-client.js +54 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/match-pattern/match-pattern.d.ts +47 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/match-pattern/match-pattern.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/match-pattern/match-pattern.js +134 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/decorators.d.ts +20 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/decorators.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/decorators.js +34 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/network.d.ts +46 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/network.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/network.js +131 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/peer.d.ts +27 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/peer.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/peer.js +25 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/flood.d.ts +59 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/flood.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/flood.js +188 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/path-vector.d.ts +35 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/path-vector.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/path-vector.js +57 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/tell-and-read.d.ts +117 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/tell-and-read.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/policies/tell-and-read.js +125 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/types.d.ts +112 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/network/types.js +21 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/observe-emitter/observe-emitter.d.ts +35 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/observe-emitter/observe-emitter.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/observe-emitter/observe-emitter.js +106 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/connection.d.ts +88 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/connection.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/connection.js +86 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/events.d.ts +83 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/events.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/events.js +115 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/hooks.d.ts +164 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/hooks.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/hooks.js +67 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/identity.d.ts +99 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/identity.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/identity.js +190 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/operation-handle.d.ts +185 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/operation-handle.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/operation-handle.js +103 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/reactions.d.ts +58 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/reactions.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/reactions.js +64 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/rig.d.ts +295 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/rig.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/rig.js +898 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/types.d.ts +167 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/rig/types.js +5 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/types/types.d.ts +278 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/types/types.d.ts.map +1 -0
- package/esm/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/types/types.js +89 -0
- package/esm/dispatch.d.ts +35 -0
- package/esm/dispatch.d.ts.map +1 -0
- package/esm/dispatch.js +40 -0
- package/esm/elasticsearch/mod.d.ts +31 -0
- package/esm/elasticsearch/mod.d.ts.map +1 -0
- package/esm/elasticsearch/mod.js +8 -0
- package/esm/elasticsearch/store.d.ts +44 -0
- package/esm/elasticsearch/store.d.ts.map +1 -0
- package/esm/elasticsearch/store.js +213 -0
- package/esm/entity-store.d.ts +106 -0
- package/esm/entity-store.d.ts.map +1 -0
- package/esm/entity-store.js +46 -0
- package/esm/entity.d.ts +125 -0
- package/esm/entity.d.ts.map +1 -0
- package/esm/entity.js +66 -0
- package/esm/errors.d.ts +23 -0
- package/esm/errors.d.ts.map +1 -0
- package/esm/errors.js +25 -0
- package/esm/fs/mod.d.ts +28 -0
- package/esm/fs/mod.d.ts.map +1 -0
- package/esm/fs/mod.js +13 -0
- package/esm/fs/store.d.ts +45 -0
- package/esm/fs/store.d.ts.map +1 -0
- package/esm/fs/store.js +194 -0
- package/esm/indexeddb/mod.d.ts +9 -0
- package/esm/indexeddb/mod.d.ts.map +1 -0
- package/esm/indexeddb/mod.js +8 -0
- package/esm/indexeddb/store.d.ts +47 -0
- package/esm/indexeddb/store.d.ts.map +1 -0
- package/esm/indexeddb/store.js +299 -0
- package/esm/ipfs/mod.d.ts +24 -0
- package/esm/ipfs/mod.d.ts.map +1 -0
- package/esm/ipfs/mod.js +13 -0
- package/esm/ipfs/store.d.ts +42 -0
- package/esm/ipfs/store.d.ts.map +1 -0
- package/esm/ipfs/store.js +197 -0
- package/esm/localstorage/mod.d.ts +9 -0
- package/esm/localstorage/mod.d.ts.map +1 -0
- package/esm/localstorage/mod.js +8 -0
- package/esm/localstorage/store.d.ts +45 -0
- package/esm/localstorage/store.d.ts.map +1 -0
- package/esm/localstorage/store.js +147 -0
- package/esm/memory/mod.d.ts +12 -0
- package/esm/memory/mod.d.ts.map +1 -0
- package/esm/memory/mod.js +11 -0
- package/esm/memory/store.d.ts +73 -0
- package/esm/memory/store.d.ts.map +1 -0
- package/esm/memory/store.js +300 -0
- package/esm/mod.d.ts +36 -0
- package/esm/mod.d.ts.map +1 -0
- package/esm/mod.js +31 -0
- package/esm/mongo/mod.d.ts +35 -0
- package/esm/mongo/mod.d.ts.map +1 -0
- package/esm/mongo/mod.js +8 -0
- package/esm/mongo/store.d.ts +42 -0
- package/esm/mongo/store.d.ts.map +1 -0
- package/esm/mongo/store.js +185 -0
- package/esm/package.json +3 -0
- package/esm/payload.d.ts +24 -0
- package/esm/payload.d.ts.map +1 -0
- package/esm/payload.js +30 -0
- package/esm/postgres/columns.d.ts +33 -0
- package/esm/postgres/columns.d.ts.map +1 -0
- package/esm/postgres/columns.js +51 -0
- package/esm/postgres/mod.d.ts +19 -0
- package/esm/postgres/mod.d.ts.map +1 -0
- package/esm/postgres/mod.js +9 -0
- package/esm/postgres/store.d.ts +75 -0
- package/esm/postgres/store.d.ts.map +1 -0
- package/esm/postgres/store.js +364 -0
- package/esm/read.d.ts +40 -0
- package/esm/read.d.ts.map +1 -0
- package/esm/read.js +67 -0
- package/esm/s3/mod.d.ts +23 -0
- package/esm/s3/mod.d.ts.map +1 -0
- package/esm/s3/mod.js +13 -0
- package/esm/s3/store.d.ts +46 -0
- package/esm/s3/store.d.ts.map +1 -0
- package/esm/s3/store.js +183 -0
- package/esm/sqlite/mod.d.ts +18 -0
- package/esm/sqlite/mod.d.ts.map +1 -0
- package/esm/sqlite/mod.js +8 -0
- package/esm/sqlite/schema.d.ts +10 -0
- package/esm/sqlite/schema.d.ts.map +1 -0
- package/esm/sqlite/schema.js +26 -0
- package/esm/sqlite/store.d.ts +42 -0
- package/esm/sqlite/store.d.ts.map +1 -0
- package/esm/sqlite/store.js +184 -0
- package/esm/types.d.ts +101 -0
- package/esm/types.d.ts.map +1 -0
- package/esm/types.js +21 -0
- package/esm/url.d.ts +108 -0
- package/esm/url.d.ts.map +1 -0
- package/esm/url.js +151 -0
- package/package.json +93 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ConsoleClient — a write-only debug/audit client.
|
|
3
|
+
*
|
|
4
|
+
* Logs receive (write) operations to stdout (or a custom logger).
|
|
5
|
+
* Read always returns empty results — this client is for inspection, not retrieval.
|
|
6
|
+
*
|
|
7
|
+
* This is a transport-style client with no underlying store — it's a sink,
|
|
8
|
+
* not storage.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```typescript
|
|
12
|
+
* import { ConsoleClient } from "@bandeira-tech/b3nd-core/client-console";
|
|
13
|
+
*
|
|
14
|
+
* const client = new ConsoleClient("debug");
|
|
15
|
+
*
|
|
16
|
+
* await client.receive([["mutable://app/config", { theme: "dark" }]]);
|
|
17
|
+
* // Console output: [debug] RECEIVE mutable://app/config data={"theme":"dark"}
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
import type { Output, ProtocolInterfaceNode, ReceiveResult, StatusResult } from "../types/types.js";
|
|
21
|
+
export declare class ConsoleClient implements ProtocolInterfaceNode {
|
|
22
|
+
private readonly label;
|
|
23
|
+
private readonly log;
|
|
24
|
+
constructor(label?: string, logger?: (msg: string) => void);
|
|
25
|
+
receive(msgs: Output[]): Promise<ReceiveResult[]>;
|
|
26
|
+
read<T = unknown>(_urls: string[]): Promise<Output<T>[]>;
|
|
27
|
+
observe(_urls: string[], _signal?: AbortSignal): AsyncIterable<readonly string[]>;
|
|
28
|
+
status(): Promise<StatusResult>;
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../../../src/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/client-console/client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EACV,MAAM,EACN,qBAAqB,EACrB,aAAa,EACb,YAAY,EACb,MAAM,mBAAmB,CAAC;AAc3B,qBAAa,aAAc,YAAW,qBAAqB;IACzD,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAC,GAAG,CAA4B;gBAEpC,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI;IAK1D,OAAO,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,aAAa,EAAE,CAAC;IAcjD,IAAI,CAAC,CAAC,GAAG,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;IAKxD,OAAO,CACL,KAAK,EAAE,MAAM,EAAE,EACf,OAAO,CAAC,EAAE,WAAW,GACpB,aAAa,CAAC,SAAS,MAAM,EAAE,CAAC;IAcnC,MAAM,IAAI,OAAO,CAAC,YAAY,CAAC;CAMhC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ConsoleClient — a write-only debug/audit client.
|
|
3
|
+
*
|
|
4
|
+
* Logs receive (write) operations to stdout (or a custom logger).
|
|
5
|
+
* Read always returns empty results — this client is for inspection, not retrieval.
|
|
6
|
+
*
|
|
7
|
+
* This is a transport-style client with no underlying store — it's a sink,
|
|
8
|
+
* not storage.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```typescript
|
|
12
|
+
* import { ConsoleClient } from "@bandeira-tech/b3nd-core/client-console";
|
|
13
|
+
*
|
|
14
|
+
* const client = new ConsoleClient("debug");
|
|
15
|
+
*
|
|
16
|
+
* await client.receive([["mutable://app/config", { theme: "dark" }]]);
|
|
17
|
+
* // Console output: [debug] RECEIVE mutable://app/config data={"theme":"dark"}
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* Safely serialize data for console output.
|
|
22
|
+
* Falls back to a placeholder if JSON.stringify throws (circular refs, BigInt, etc.).
|
|
23
|
+
*/
|
|
24
|
+
function safeStringify(data) {
|
|
25
|
+
try {
|
|
26
|
+
return JSON.stringify(data);
|
|
27
|
+
}
|
|
28
|
+
catch {
|
|
29
|
+
return "[unserializable]";
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
export class ConsoleClient {
|
|
33
|
+
label;
|
|
34
|
+
log;
|
|
35
|
+
constructor(label, logger) {
|
|
36
|
+
this.label = label ?? "b3nd";
|
|
37
|
+
this.log = logger ?? console.log;
|
|
38
|
+
}
|
|
39
|
+
receive(msgs) {
|
|
40
|
+
const results = [];
|
|
41
|
+
for (const [uri, payload] of msgs) {
|
|
42
|
+
const payloadStr = safeStringify(payload);
|
|
43
|
+
this.log(`[${this.label}] RECEIVE ${uri} payload=${payloadStr}`);
|
|
44
|
+
results.push({ accepted: true });
|
|
45
|
+
}
|
|
46
|
+
return Promise.resolve(results);
|
|
47
|
+
}
|
|
48
|
+
read(_urls) {
|
|
49
|
+
// ConsoleClient is write-only — every read produces no Output.
|
|
50
|
+
return Promise.resolve([]);
|
|
51
|
+
}
|
|
52
|
+
observe(_urls, _signal) {
|
|
53
|
+
return {
|
|
54
|
+
[Symbol.asyncIterator]() {
|
|
55
|
+
return {
|
|
56
|
+
next: () => Promise.resolve({
|
|
57
|
+
value: undefined,
|
|
58
|
+
done: true,
|
|
59
|
+
}),
|
|
60
|
+
};
|
|
61
|
+
},
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
status() {
|
|
65
|
+
return Promise.resolve({
|
|
66
|
+
status: "healthy",
|
|
67
|
+
message: "ConsoleClient is operational",
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module
|
|
3
|
+
* Encoding primitives — pure `bytes ↔ string` conversions.
|
|
4
|
+
*
|
|
5
|
+
* Framework-level infrastructure used by crypto primitives (identity,
|
|
6
|
+
* encrypt) and any other consumer that needs a stable byte/string
|
|
7
|
+
* representation. Knows nothing about JSON, markers, or content.
|
|
8
|
+
*/
|
|
9
|
+
export declare function encodeHex(bytes: Uint8Array): string;
|
|
10
|
+
/** Decode hex (any case) to bytes. Throws on odd-length input. */
|
|
11
|
+
export declare function decodeHex(hex: string): Uint8Array<ArrayBuffer>;
|
|
12
|
+
/** Encode bytes to base64 (Node Buffer-backed when available, btoa otherwise). */
|
|
13
|
+
export declare function encodeBase64(bytes: Uint8Array): string;
|
|
14
|
+
/** Decode base64 to bytes. */
|
|
15
|
+
export declare function decodeBase64(b64: string): Uint8Array;
|
|
16
|
+
//# sourceMappingURL=encoding.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"encoding.d.ts","sourceRoot":"","sources":["../../../../../../../../src/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encoding/encoding.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,wBAAgB,SAAS,CAAC,KAAK,EAAE,UAAU,GAAG,MAAM,CAEnD;AAED,kEAAkE;AAClE,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAC,WAAW,CAAC,CAU9D;AAED,kFAAkF;AAClF,wBAAgB,YAAY,CAAC,KAAK,EAAE,UAAU,GAAG,MAAM,CAMtD;AAED,8BAA8B;AAC9B,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CASpD"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module
|
|
3
|
+
* Encoding primitives — pure `bytes ↔ string` conversions.
|
|
4
|
+
*
|
|
5
|
+
* Framework-level infrastructure used by crypto primitives (identity,
|
|
6
|
+
* encrypt) and any other consumer that needs a stable byte/string
|
|
7
|
+
* representation. Knows nothing about JSON, markers, or content.
|
|
8
|
+
*/
|
|
9
|
+
/** Encode bytes to lowercase hex. */
|
|
10
|
+
import * as dntShim from "../../../../../../../_dnt.shims.js";
|
|
11
|
+
export function encodeHex(bytes) {
|
|
12
|
+
return Array.from(bytes).map((b) => b.toString(16).padStart(2, "0")).join("");
|
|
13
|
+
}
|
|
14
|
+
/** Decode hex (any case) to bytes. Throws on odd-length input. */
|
|
15
|
+
export function decodeHex(hex) {
|
|
16
|
+
if (hex.length % 2 !== 0) {
|
|
17
|
+
throw new Error("Invalid hex input");
|
|
18
|
+
}
|
|
19
|
+
const buffer = new ArrayBuffer(hex.length / 2);
|
|
20
|
+
const bytes = new Uint8Array(buffer);
|
|
21
|
+
for (let i = 0; i < hex.length; i += 2) {
|
|
22
|
+
bytes[i / 2] = parseInt(hex.slice(i, i + 2), 16);
|
|
23
|
+
}
|
|
24
|
+
return bytes;
|
|
25
|
+
}
|
|
26
|
+
/** Encode bytes to base64 (Node Buffer-backed when available, btoa otherwise). */
|
|
27
|
+
export function encodeBase64(bytes) {
|
|
28
|
+
const buf = nodeBuffer();
|
|
29
|
+
if (buf)
|
|
30
|
+
return buf.from(bytes).toString("base64");
|
|
31
|
+
let binary = "";
|
|
32
|
+
bytes.forEach((b) => (binary += String.fromCharCode(b)));
|
|
33
|
+
return btoa(binary);
|
|
34
|
+
}
|
|
35
|
+
/** Decode base64 to bytes. */
|
|
36
|
+
export function decodeBase64(b64) {
|
|
37
|
+
const buf = nodeBuffer();
|
|
38
|
+
if (buf)
|
|
39
|
+
return new Uint8Array(buf.from(b64, "base64"));
|
|
40
|
+
const binary = atob(b64);
|
|
41
|
+
const bytes = new Uint8Array(binary.length);
|
|
42
|
+
for (let i = 0; i < binary.length; i++) {
|
|
43
|
+
bytes[i] = binary.charCodeAt(i);
|
|
44
|
+
}
|
|
45
|
+
return bytes;
|
|
46
|
+
}
|
|
47
|
+
function nodeBuffer() {
|
|
48
|
+
return (typeof dntShim.dntGlobalThis !== "undefined" &&
|
|
49
|
+
dntShim.dntGlobalThis.Buffer) || undefined;
|
|
50
|
+
}
|
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
export interface KeyPair {
|
|
2
|
+
publicKey: CryptoKey;
|
|
3
|
+
privateKey: CryptoKey;
|
|
4
|
+
publicKeyHex: string;
|
|
5
|
+
privateKeyHex: string;
|
|
6
|
+
}
|
|
7
|
+
export interface EncryptionKeyPair {
|
|
8
|
+
publicKey: CryptoKey;
|
|
9
|
+
privateKey: CryptoKey;
|
|
10
|
+
publicKeyHex: string;
|
|
11
|
+
}
|
|
12
|
+
export interface EncryptedPayload {
|
|
13
|
+
data: string;
|
|
14
|
+
nonce: string;
|
|
15
|
+
ephemeralPublicKey?: string;
|
|
16
|
+
}
|
|
17
|
+
export interface AuthenticatedMessage<T = unknown> {
|
|
18
|
+
auth: Array<{
|
|
19
|
+
pubkey: string;
|
|
20
|
+
signature: string;
|
|
21
|
+
}>;
|
|
22
|
+
payload: T;
|
|
23
|
+
}
|
|
24
|
+
export interface SignedEncryptedMessage {
|
|
25
|
+
auth: Array<{
|
|
26
|
+
pubkey: string;
|
|
27
|
+
signature: string;
|
|
28
|
+
}>;
|
|
29
|
+
payload: EncryptedPayload;
|
|
30
|
+
}
|
|
31
|
+
export interface SignedSymmetricMessage {
|
|
32
|
+
auth: Array<{
|
|
33
|
+
pubkey: string;
|
|
34
|
+
signature: string;
|
|
35
|
+
}>;
|
|
36
|
+
payload: EncryptedPayload;
|
|
37
|
+
}
|
|
38
|
+
export declare class IdentityKey {
|
|
39
|
+
private readonly privateKey;
|
|
40
|
+
readonly publicKeyHex: string;
|
|
41
|
+
private constructor();
|
|
42
|
+
static generate(): Promise<{
|
|
43
|
+
key: IdentityKey;
|
|
44
|
+
privateKeyPem: string;
|
|
45
|
+
publicKeyHex: string;
|
|
46
|
+
}>;
|
|
47
|
+
static fromPem(pem: string, publicKeyHex: string): Promise<IdentityKey>;
|
|
48
|
+
static fromHex(params: {
|
|
49
|
+
privateKeyHex: string;
|
|
50
|
+
publicKeyHex: string;
|
|
51
|
+
}): Promise<IdentityKey>;
|
|
52
|
+
sign(payload: unknown): Promise<string>;
|
|
53
|
+
}
|
|
54
|
+
export declare class PublicEncryptionKey {
|
|
55
|
+
readonly publicKeyHex: string;
|
|
56
|
+
readonly publicKey: CryptoKey | null;
|
|
57
|
+
constructor(publicKeyHex: string, publicKey: CryptoKey | null);
|
|
58
|
+
static fromHex(publicKeyHex: string): Promise<PublicEncryptionKey>;
|
|
59
|
+
static generatePair(): Promise<{
|
|
60
|
+
publicKey: PublicEncryptionKey;
|
|
61
|
+
privateKeyHex: string;
|
|
62
|
+
}>;
|
|
63
|
+
encrypt(data: Uint8Array): Promise<EncryptedPayload>;
|
|
64
|
+
toHex(): string;
|
|
65
|
+
}
|
|
66
|
+
export declare class SecretEncryptionKey {
|
|
67
|
+
readonly keyHex: string;
|
|
68
|
+
private constructor();
|
|
69
|
+
static fromSecret(params: {
|
|
70
|
+
secret: string;
|
|
71
|
+
salt: string;
|
|
72
|
+
iterations?: number;
|
|
73
|
+
}): Promise<SecretEncryptionKey>;
|
|
74
|
+
static fromHex(keyHex: string): SecretEncryptionKey;
|
|
75
|
+
encrypt(data: Uint8Array): Promise<EncryptedPayload>;
|
|
76
|
+
decrypt(payload: EncryptedPayload): Promise<Uint8Array>;
|
|
77
|
+
}
|
|
78
|
+
export declare class PrivateEncryptionKey {
|
|
79
|
+
readonly privateKey: CryptoKey;
|
|
80
|
+
readonly privateKeyHex: string;
|
|
81
|
+
readonly publicKeyHex: string;
|
|
82
|
+
constructor(privateKey: CryptoKey, privateKeyHex: string, publicKeyHex: string);
|
|
83
|
+
static fromHex(params: {
|
|
84
|
+
privateKeyHex: string;
|
|
85
|
+
publicKeyHex: string;
|
|
86
|
+
}): Promise<PrivateEncryptionKey>;
|
|
87
|
+
static generatePair(): Promise<{
|
|
88
|
+
privateKey: PrivateEncryptionKey;
|
|
89
|
+
publicKey: PublicEncryptionKey;
|
|
90
|
+
}>;
|
|
91
|
+
toPublic(): PublicEncryptionKey;
|
|
92
|
+
decrypt(payload: EncryptedPayload): Promise<Uint8Array>;
|
|
93
|
+
toHex(): string;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Convert a PEM-encoded private key to a CryptoKey
|
|
97
|
+
*/
|
|
98
|
+
export declare function pemToCryptoKey(pem: string, algorithm: "Ed25519" | "X25519", extractable?: boolean): Promise<CryptoKey>;
|
|
99
|
+
/**
|
|
100
|
+
* Generate an Ed25519 keypair for signing
|
|
101
|
+
*/
|
|
102
|
+
export declare function generateSigningKeyPair(): Promise<KeyPair>;
|
|
103
|
+
/**
|
|
104
|
+
* Generate an X25519 keypair for encryption (ECDH)
|
|
105
|
+
*/
|
|
106
|
+
export declare function generateEncryptionKeyPair(): Promise<EncryptionKeyPair>;
|
|
107
|
+
/**
|
|
108
|
+
* Sign a payload with an Ed25519 private key
|
|
109
|
+
*/
|
|
110
|
+
export declare function sign<T>(privateKey: CryptoKey, payload: T): Promise<string>;
|
|
111
|
+
/**
|
|
112
|
+
* Sign a payload with an Ed25519 private key from hex
|
|
113
|
+
*/
|
|
114
|
+
export declare function signWithHex<T>(privateKeyHex: string, payload: T): Promise<string>;
|
|
115
|
+
/**
|
|
116
|
+
* Verify a signature using Ed25519 public key
|
|
117
|
+
*/
|
|
118
|
+
export declare function verify<T>(publicKeyHex: string, signatureHex: string, payload: T): Promise<boolean>;
|
|
119
|
+
/**
|
|
120
|
+
* Encrypt data using X25519 ECDH + HKDF + AES-GCM
|
|
121
|
+
* Uses ephemeral keypair for forward secrecy.
|
|
122
|
+
* HKDF provides domain separation per NIST SP 800-56C / RFC 5869.
|
|
123
|
+
*/
|
|
124
|
+
export declare function encrypt(data: Uint8Array, recipientPublicKeyHex: string): Promise<EncryptedPayload>;
|
|
125
|
+
/**
|
|
126
|
+
* Decrypt data using X25519 ECDH + HKDF + AES-GCM
|
|
127
|
+
*/
|
|
128
|
+
export declare function decrypt(encryptedPayload: EncryptedPayload, recipientPrivateKey: CryptoKey, recipientPublicKeyHex?: string): Promise<Uint8Array>;
|
|
129
|
+
/**
|
|
130
|
+
* Decrypt data using private key from hex
|
|
131
|
+
*/
|
|
132
|
+
export declare function decryptWithHex(encryptedPayload: EncryptedPayload, recipientPrivateKeyHex: string): Promise<Uint8Array>;
|
|
133
|
+
/**
|
|
134
|
+
* Create an authenticated message (signed but not encrypted)
|
|
135
|
+
*/
|
|
136
|
+
export declare function createAuthenticatedMessage<T>(payload: T, signers: Array<{
|
|
137
|
+
privateKey: CryptoKey;
|
|
138
|
+
publicKeyHex: string;
|
|
139
|
+
}>): Promise<AuthenticatedMessage<T>>;
|
|
140
|
+
/**
|
|
141
|
+
* Create an authenticated message with hex-encoded keys (convenience wrapper)
|
|
142
|
+
*/
|
|
143
|
+
export declare function createAuthenticatedMessageWithHex<T>(payload: T, pubkeyHex: string, privateKeyHex: string): Promise<AuthenticatedMessage<T>>;
|
|
144
|
+
/**
|
|
145
|
+
* Derive an encryption key from seed and salt using PBKDF2
|
|
146
|
+
* Returns hex-encoded key suitable for encrypt/decrypt functions
|
|
147
|
+
*/
|
|
148
|
+
export declare function deriveKeyFromSeed(seed: string, salt: string, iterations?: number): Promise<string>;
|
|
149
|
+
export declare function generateNonce(length?: number): Uint8Array;
|
|
150
|
+
export declare function generateRandomData(size: number): Uint8Array;
|
|
151
|
+
export declare function exportPrivateKeyPem(privateKey: CryptoKey, label: string): Promise<string>;
|
|
152
|
+
export declare function signPayload(params: {
|
|
153
|
+
payload: unknown;
|
|
154
|
+
identity: IdentityKey;
|
|
155
|
+
}): Promise<Array<{
|
|
156
|
+
pubkey: string;
|
|
157
|
+
signature: string;
|
|
158
|
+
}>>;
|
|
159
|
+
export declare function verifyPayload(params: {
|
|
160
|
+
payload: unknown;
|
|
161
|
+
auth: Array<{
|
|
162
|
+
pubkey: string;
|
|
163
|
+
signature: string;
|
|
164
|
+
}>;
|
|
165
|
+
}): Promise<{
|
|
166
|
+
verified: boolean;
|
|
167
|
+
signers: string[];
|
|
168
|
+
}>;
|
|
169
|
+
export declare function createSignedEncryptedMessage(params: {
|
|
170
|
+
data: Uint8Array;
|
|
171
|
+
identity: IdentityKey;
|
|
172
|
+
encryptionKey: SecretEncryptionKey | PublicEncryptionKey;
|
|
173
|
+
}): Promise<SignedEncryptedMessage>;
|
|
174
|
+
export declare function createSignedEncryptedMessage(data: Uint8Array, signers: Array<{
|
|
175
|
+
privateKey: CryptoKey;
|
|
176
|
+
publicKeyHex: string;
|
|
177
|
+
}>, recipientPublicKeyHex: string): Promise<SignedEncryptedMessage>;
|
|
178
|
+
export declare function verifyAndDecryptMessage(params: {
|
|
179
|
+
message: SignedEncryptedMessage;
|
|
180
|
+
encryptionKey: SecretEncryptionKey | PrivateEncryptionKey;
|
|
181
|
+
}): Promise<{
|
|
182
|
+
data: Uint8Array;
|
|
183
|
+
verified: boolean;
|
|
184
|
+
signers: string[];
|
|
185
|
+
}>;
|
|
186
|
+
/**
|
|
187
|
+
* Encrypt data using a symmetric key (AES-GCM) provided as hex
|
|
188
|
+
*/
|
|
189
|
+
export declare function encryptSymmetric(data: Uint8Array, keyHex: string): Promise<EncryptedPayload>;
|
|
190
|
+
/**
|
|
191
|
+
* Decrypt data using a symmetric key (AES-GCM) provided as hex
|
|
192
|
+
*/
|
|
193
|
+
export declare function decryptSymmetric(payload: EncryptedPayload, keyHex: string): Promise<Uint8Array>;
|
|
194
|
+
/**
|
|
195
|
+
* Create a signed symmetric message (signs encrypted payload)
|
|
196
|
+
*/
|
|
197
|
+
export declare function createSignedSymmetricMessage(data: Uint8Array, signers: Array<{
|
|
198
|
+
privateKey: CryptoKey;
|
|
199
|
+
publicKeyHex: string;
|
|
200
|
+
}>, keyHex: string): Promise<SignedSymmetricMessage>;
|
|
201
|
+
/**
|
|
202
|
+
* Compute HMAC-SHA256 of data with a key
|
|
203
|
+
* Returns hex-encoded 32-byte result
|
|
204
|
+
*/
|
|
205
|
+
export declare function hmac(key: string, data: string): Promise<string>;
|
|
206
|
+
/**
|
|
207
|
+
* Derive a deterministic Ed25519 signing keypair from a seed string.
|
|
208
|
+
* Uses HKDF to expand the seed into key material suitable for Ed25519.
|
|
209
|
+
*
|
|
210
|
+
* The same seed always produces the same keypair.
|
|
211
|
+
*/
|
|
212
|
+
export declare function deriveSigningKeyPairFromSeed(seed: string): Promise<KeyPair>;
|
|
213
|
+
/**
|
|
214
|
+
* Derive a deterministic X25519 encryption keypair from a seed string.
|
|
215
|
+
* Uses HKDF to expand the seed into key material suitable for X25519.
|
|
216
|
+
*
|
|
217
|
+
* The same seed always produces the same keypair.
|
|
218
|
+
*/
|
|
219
|
+
export declare function deriveEncryptionKeyPairFromSeed(seed: string): Promise<EncryptionKeyPair>;
|
|
220
|
+
/**
|
|
221
|
+
* Extract the Ed25519 public key hex from an Ed25519 private CryptoKey.
|
|
222
|
+
* Useful for deriving a node ID from a PEM-imported private key.
|
|
223
|
+
*/
|
|
224
|
+
export declare function extractPublicKeyHex(privateKey: CryptoKey): Promise<string>;
|
|
225
|
+
/**
|
|
226
|
+
* Generate a PKCE code verifier (RFC 7636)
|
|
227
|
+
* 32 random bytes, base64url-encoded (43 characters)
|
|
228
|
+
*/
|
|
229
|
+
export declare function generateCodeVerifier(): string;
|
|
230
|
+
/**
|
|
231
|
+
* Generate a PKCE code challenge from a verifier (RFC 7636, S256 method)
|
|
232
|
+
* SHA-256 hash of verifier, base64url-encoded (43 characters)
|
|
233
|
+
*/
|
|
234
|
+
export declare function generateCodeChallenge(verifier: string): Promise<string>;
|
|
235
|
+
//# sourceMappingURL=mod.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../../../../../../../src/deps/jsr.io/@bandeira-tech/b3nd-core/0.22.0/src/encrypt/mod.ts"],"names":[],"mappings":"AAaA,MAAM,WAAW,OAAO;IACtB,SAAS,EAAE,SAAS,CAAC;IACrB,U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