@dxos/network-manager 2.33.9-dev.a6069cb4 → 2.33.9-dev.bba8fc00

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.
@@ -0,0 +1,27 @@
1
+
2
+ import debug from 'debug';
3
+
4
+
5
+
6
+ debug.enable('false');
7
+
8
+ import { mocha } from 'mocha';
9
+
10
+ async function run() {
11
+ const context = await window.browserMocha__getEnv();
12
+
13
+ window.browserMocha = { context };
14
+
15
+ mocha.reporter('spec');
16
+ mocha.setup('bdd');
17
+ mocha.checkLeaks();
18
+
19
+ require("../../src/network-manager.browser-test.ts");
20
+
21
+ window.browserMocha__initFinished()
22
+
23
+ mocha.run(window.browserMocha__testsDone);
24
+ }
25
+
26
+ run();
27
+
@@ -1,25 +1,64 @@
1
1
  import substitutions from "../../substitutions";
2
2
  import * as dxos_halo_keys from "./halo/keys";
3
3
  import * as google_protobuf from "../google/protobuf";
4
+ /**
5
+ * Defined in:
6
+ * {@link file://./../../../../../../common/protocols/src/proto/dxos/halo/signed.proto}
7
+ */
4
8
  export interface Message {
5
9
  payload: google_protobuf.Any;
6
10
  }
7
11
  /**
8
12
  * A generic container message used whenever messages are signed (e.g. PartyCredential)
13
+ *
14
+ * Defined in:
15
+ * {@link file://./../../../../../../common/protocols/src/proto/dxos/halo/signed.proto}
9
16
  */
10
17
  export interface SignedMessage {
18
+ /**
19
+ * The signed message contents.
20
+ */
11
21
  signed: SignedMessage.Signed;
22
+ /**
23
+ * An array of Signatures, one for each key that signed the message.
24
+ */
12
25
  signatures?: SignedMessage.Signature[];
13
26
  }
14
27
  export declare namespace SignedMessage {
28
+ /**
29
+ * Defined in:
30
+ * {@link file://./../../../../../../common/protocols/src/proto/dxos/halo/signed.proto}
31
+ */
15
32
  interface Signed {
33
+ /**
34
+ * RFC-3339 datetime string.
35
+ */
16
36
  created: string;
17
37
  nonce: Uint8Array;
38
+ /**
39
+ * The payload to be signed.
40
+ */
18
41
  payload: google_protobuf.Any;
19
42
  }
43
+ /**
44
+ * Defined in:
45
+ * {@link file://./../../../../../../common/protocols/src/proto/dxos/halo/signed.proto}
46
+ */
20
47
  interface Signature {
48
+ /**
49
+ * The publicKey of the keypair that made this signature.
50
+ */
21
51
  key: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
52
+ /**
53
+ * The bytes of the signature.
54
+ */
22
55
  signature: Uint8Array;
56
+ /**
57
+ * The certification chain of SignedMessages for this key.
58
+ *
59
+ * Options:
60
+ * - proto3_optional = true
61
+ */
23
62
  keyChain?: dxos_halo_keys.KeyChain;
24
63
  }
25
64
  }
@@ -1 +1 @@
1
- {"version":3,"file":"credentials.d.ts","sourceRoot":"","sources":["../../../../../src/proto/gen/dxos/credentials.ts"],"names":[],"mappings":"AACA,OAAO,aAAa,MAAM,qBAAqB,CAAC;AAChD,OAAO,KAAK,cAAc,MAAM,aAAa,CAAC;AAE9C,OAAO,KAAK,eAAe,MAAM,oBAAoB,CAAC;AACtD,MAAM,WAAW,OAAO;IACpB,OAAO,EAAE,eAAe,CAAC,GAAG,CAAC;CAChC;AACD;;GAEG;AACH,MAAM,WAAW,aAAa;IAC1B,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC;IAC7B,UAAU,CAAC,EAAE,aAAa,CAAC,SAAS,EAAE,CAAC;CAC1C;AACD,yBAAiB,aAAa,CAAC;IAC3B,UAAiB,MAAM;QACnB,OAAO,EAAE,MAAM,CAAC;QAChB,KAAK,EAAE,UAAU,CAAC;QAClB,OAAO,EAAE,eAAe,CAAC,GAAG,CAAC;KAChC;IACD,UAAiB,SAAS;QACtB,GAAG,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;QAC3E,SAAS,EAAE,UAAU,CAAC;QACtB,QAAQ,CAAC,EAAE,cAAc,CAAC,QAAQ,CAAC;KACtC;CACJ"}
1
+ {"version":3,"file":"credentials.d.ts","sourceRoot":"","sources":["../../../../../src/proto/gen/dxos/credentials.ts"],"names":[],"mappings":"AACA,OAAO,aAAa,MAAM,qBAAqB,CAAC;AAChD,OAAO,KAAK,cAAc,MAAM,aAAa,CAAC;AAE9C,OAAO,KAAK,eAAe,MAAM,oBAAoB,CAAC;AACtD;;;GAGG;AACH,MAAM,WAAW,OAAO;IACpB,OAAO,EAAE,eAAe,CAAC,GAAG,CAAC;CAChC;AACD;;;;;GAKG;AACH,MAAM,WAAW,aAAa;IAC1B;;OAEG;IACH,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC;IAC7B;;OAEG;IACH,UAAU,CAAC,EAAE,aAAa,CAAC,SAAS,EAAE,CAAC;CAC1C;AACD,yBAAiB,aAAa,CAAC;IAC3B;;;OAGG;IACH,UAAiB,MAAM;QACnB;;WAEG;QACH,OAAO,EAAE,MAAM,CAAC;QAChB,KAAK,EAAE,UAAU,CAAC;QAClB;;WAEG;QACH,OAAO,EAAE,eAAe,CAAC,GAAG,CAAC;KAChC;IACD;;;OAGG;IACH,UAAiB,SAAS;QACtB;;WAEG;QACH,GAAG,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;QAC3E;;WAEG;QACH,SAAS,EAAE,UAAU,CAAC;QACtB;;;;;WAKG;QACH,QAAQ,CAAC,EAAE,cAAc,CAAC,QAAQ,CAAC;KACtC;CACJ"}
@@ -1,5 +1,9 @@
1
1
  import substitutions from "../../../substitutions";
2
2
  import * as dxos_credentials from "../credentials";
3
+ /**
4
+ * Defined in:
5
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
6
+ */
3
7
  export declare enum KeyType {
4
8
  UNKNOWN = 0,
5
9
  IDENTITY = 1,
@@ -8,12 +12,24 @@ export declare enum KeyType {
8
12
  FEED = 4,
9
13
  DXNS_ADDRESS = 5
10
14
  }
15
+ /**
16
+ * Defined in:
17
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
18
+ */
11
19
  export interface PubKey {
12
- data?: Uint8Array;
20
+ data: Uint8Array;
13
21
  }
22
+ /**
23
+ * Defined in:
24
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
25
+ */
14
26
  export interface PrivKey {
15
- data?: Uint8Array;
27
+ data: Uint8Array;
16
28
  }
29
+ /**
30
+ * Defined in:
31
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
32
+ */
17
33
  export interface KeyRecord {
18
34
  /**
19
35
  * The `KeyType` type of the key. This is often unknown for keys from other sources.
@@ -25,33 +41,59 @@ export interface KeyRecord {
25
41
  publicKey: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
26
42
  /**
27
43
  * The secret key as a Buffer (this will never be visible outside the Keyring).
44
+ *
45
+ * Options:
46
+ * - proto3_optional = true
28
47
  */
29
48
  secretKey?: ReturnType<(typeof substitutions)["dxos.halo.keys.PrivKey"]["decode"]>;
30
49
  /**
31
50
  * Is this key from a Greeting "hint"?
51
+ *
52
+ * Options:
53
+ * - proto3_optional = true
32
54
  */
33
55
  hint?: boolean;
34
56
  /**
35
57
  * Determines if this is our key?
36
58
  * Usually true if `secretKey` is present; may be false for "inception keys" such as the Party key.
59
+ *
60
+ * Options:
61
+ * - proto3_optional = true
37
62
  */
38
63
  own?: boolean;
39
64
  /**
40
65
  * Is this key to be trusted?
66
+ *
67
+ * Options:
68
+ * - proto3_optional = true
41
69
  */
42
70
  trusted?: boolean;
43
71
  /**
44
72
  * An RFC-3339 date/time string for when the key was added to the Keyring.
73
+ *
74
+ * Options:
75
+ * - proto3_optional = true
45
76
  */
46
77
  added?: string;
47
78
  /**
48
79
  * An RFC-3339 date/time string for when the key was created.
80
+ *
81
+ * Options:
82
+ * - proto3_optional = true
49
83
  */
50
84
  created?: string;
51
85
  }
86
+ /**
87
+ * Defined in:
88
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
89
+ */
52
90
  export interface KeyRecordList {
53
91
  keys?: KeyRecord[];
54
92
  }
93
+ /**
94
+ * Defined in:
95
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
96
+ */
55
97
  export interface KeyChain {
56
98
  publicKey: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
57
99
  message: dxos_credentials.SignedMessage;
@@ -1 +1 @@
1
- {"version":3,"file":"keys.d.ts","sourceRoot":"","sources":["../../../../../../src/proto/gen/dxos/halo/keys.ts"],"names":[],"mappings":"AACA,OAAO,aAAa,MAAM,wBAAwB,CAAC;AACnD,OAAO,KAAK,gBAAgB,MAAM,gBAAgB,CAAC;AAGnD,oBAAY,OAAO;IACf,OAAO,IAAI;IACX,QAAQ,IAAI;IACZ,MAAM,IAAI;IACV,KAAK,IAAI;IACT,IAAI,IAAI;IACR,YAAY,IAAI;CACnB;AACD,MAAM,WAAW,MAAM;IACnB,IAAI,CAAC,EAAE,UAAU,CAAC;CACrB;AACD,MAAM,WAAW,OAAO;IACpB,IAAI,CAAC,EAAE,UAAU,CAAC;CACrB;AACD,MAAM,WAAW,SAAS;IACtB;;OAEG;IACH,IAAI,EAAE,OAAO,CAAC;IACd;;OAEG;IACH,SAAS,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;IACjF;;OAEG;IACH,SAAS,CAAC,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,wBAAwB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;IACnF;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;;;OAGG;IACH,GAAG,CAAC,EAAE,OAAO,CAAC;IACd;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC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AAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;;;OAKG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AACD;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC1B,IAAI,CAAC,EAAE,SAAS,EAAE,CAAC;CACtB;AACD;;;GAGG;AACH,MAAM,WAAW,QAAQ;IACrB,SAAS,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;IACjF,OAAO,EAAE,gBAAgB,CAAC,aAAa,CAAC;IACxC,OAAO,CAAC,EAAE,QAAQ,EAAE,CAAC;CACxB"}
@@ -1,6 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.KeyType = void 0;
4
+ /**
5
+ * Defined in:
6
+ * {@link file://./../../../../../../../common/protocols/src/proto/dxos/halo/keys.proto}
7
+ */
4
8
  var KeyType;
5
9
  (function (KeyType) {
6
10
  KeyType[KeyType["UNKNOWN"] = 0] = "UNKNOWN";
@@ -1 +1 @@
1
- {"version":3,"file":"keys.js","sourceRoot":"","sources":["../../../../../../src/proto/gen/dxos/halo/keys.ts"],"names":[],"mappings":";;;AAKA,IAAY,OAOX;AAPD,WAAY,OAAO;IACf,2CAAW,CAAA;IACX,6CAAY,CAAA;IACZ,yCAAU,CAAA;IACV,uCAAS,CAAA;IACT,qCAAQ,CAAA;IACR,qDAAgB,CAAA;AACpB,CAAC,EAPW,OAAO,GAAP,eAAO,KAAP,eAAO,QAOlB"}
1
+ {"version":3,"file":"keys.js","sourceRoot":"","sources":["../../../../../../src/proto/gen/dxos/halo/keys.ts"],"names":[],"mappings":";;;AAKA;;;GAGG;AACH,IAAY,OAOX;AAPD,WAAY,OAAO;IACf,2CAAW,CAAA;IACX,6CAAY,CAAA;IACZ,yCAAU,CAAA;IACV,uCAAS,CAAA;IACT,qCAAQ,CAAA;IACR,qDAAgB,CAAA;AACpB,CAAC,EAPW,OAAO,GAAP,eAAO,KAAP,eAAO,QAOlB"}
@@ -1,49 +1,79 @@
1
1
  import substitutions from "../../../substitutions";
2
+ /**
3
+ * Defined in:
4
+ * {@link file://./../../../defs/dxos/mesh/signal.proto}
5
+ */
2
6
  export interface Message {
3
7
  /**
4
8
  * Sender's public key.
5
9
  */
6
- id?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
10
+ id: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
7
11
  /**
8
12
  * Receiver`s public key.
9
13
  */
10
- remoteId?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
14
+ remoteId: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
11
15
  /**
12
16
  * Swarm identefier.
13
17
  */
14
- topic?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
18
+ topic: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
15
19
  /**
16
20
  * Unique connection identifier.
17
21
  */
18
- sessionId?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
22
+ sessionId: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
19
23
  /**
20
24
  * Message payload.
21
25
  */
22
- data?: MessageData;
26
+ data: MessageData;
23
27
  /**
24
28
  * Unique message identifier. Used for Acknolegment and matching Anwers to Offers.
29
+ *
30
+ * Options:
31
+ * - proto3_optional = true
25
32
  */
26
33
  messageId?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
27
34
  }
35
+ /**
36
+ * Defined in:
37
+ * {@link file://./../../../defs/dxos/mesh/signal.proto}
38
+ */
28
39
  export interface MessageData {
29
40
  offer?: Offer;
30
41
  answer?: Answer;
31
42
  signal?: Signal;
32
43
  ack?: Acknowledgement;
33
44
  }
45
+ /**
46
+ * Defined in:
47
+ * {@link file://./../../../defs/dxos/mesh/signal.proto}
48
+ */
34
49
  export interface Offer {
35
50
  }
51
+ /**
52
+ * Defined in:
53
+ * {@link file://./../../../defs/dxos/mesh/signal.proto}
54
+ */
36
55
  export interface Answer {
37
- accept?: boolean;
56
+ accept: boolean;
38
57
  /**
39
58
  * MessageId of the Offer being answered.
59
+ *
60
+ * Options:
61
+ * - proto3_optional = true
40
62
  */
41
63
  offerMessageId?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
42
64
  }
65
+ /**
66
+ * Defined in:
67
+ * {@link file://./../../../defs/dxos/mesh/signal.proto}
68
+ */
43
69
  export interface Signal {
44
- json?: string;
70
+ json: string;
45
71
  }
72
+ /**
73
+ * Defined in:
74
+ * {@link file://./../../../defs/dxos/mesh/signal.proto}
75
+ */
46
76
  export interface Acknowledgement {
47
- messageId?: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
77
+ messageId: ReturnType<(typeof substitutions)["dxos.halo.keys.PubKey"]["decode"]>;
48
78
  }
49
79
  //# sourceMappingURL=signal.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"signal.d.ts","sourceRoot":"","sources":["../../../../../../src/proto/gen/dxos/mesh/signal.ts"],"names":[],"mappings":"AACA,OAAO,aAAa,MAAM,wBAAwB,CAAC;AAInD,MAAM,WAAW,OAAO;IACpB;;OAEG;IACH,EAAE,CAAC,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC3E;;OAEG;IACH,QAAQ,CAAC,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;IACjF;;OAEG;IACH,KAAK,CAAC,EAAE,UAAU,CAAC,CAAC,OAAO,aAAa,CAAC,CAAC,uBAAuB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC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;
4
4
  }
5
5
  //# sourceMappingURL=protobuf.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"protobuf.d.ts","sourceRoot":"","sources":["../../../../../src/proto/gen/google/protobuf.ts"],"names":[],"mappings":"AAKA,MAAM,WAAW,GAAG;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,UAAU,CAAC;CACtB"}
1
+ {"version":3,"file":"protobuf.d.ts","sourceRoot":"","sources":["../../../../../src/proto/gen/google/protobuf.ts"],"names":[],"mappings":"AAKA,MAAM,WAAW,GAAG;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,UAAU,CAAC;CACrB"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/proto/gen/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,KAAK,gBAAgB,MAAM,oBAAoB,CAAC;AACvD,OAAO,KAAK,cAAc,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAK,gBAAgB,MAAM,oBAAoB,CAAC;AACvD,OAAO,KAAK,eAAe,MAAM,mBAAmB,CAAC;AAErD,MAAM,WAAW,KAAK;IAClB,0BAA0B,EAAE,gBAAgB,CAAC,OAAO,CAAC;IACrD,gCAAgC,EAAE,gBAAgB,CAAC,aAAa,CAAC;IACjE,0CAA0C,EAAE,gBAAgB,CAAC,aAAa,CAAC,SAAS,CAAC;IACrF,uCAAuC,EAAE,gBAAgB,CAAC,aAAa,CAAC,MAAM,CAAC;IAC/E,yBAAyB,EAAE,cAAc,CAAC,QAAQ,CAAC;IACnD,0BAA0B,EAAE,cAAc,CAAC,SAAS,CAAC;IACrD,8BAA8B,EAAE,cAAc,CAAC,aAAa,CAAC;IAC7D,wBAAwB,EAAE,cAAc,CAAC,OAAO,CAAC;IACjD,wBAAwB,EAAE,cAAc,CAAC,OAAO,CAAC;IACjD,uBAAuB,E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AAC,OAAO,CAAC;IACjD,uBAAuB,EAAE,cAAc,CAAC,MAAM,CAAC;IAC/C,kCAAkC,EAAE,gBAAgB,CAAC,eAAe,CAAC;IACrE,yBAAyB,EAAE,gBAAgB,CAAC,MAAM,CAAC;IACnD,0BAA0B,EAAE,gBAAgB,CAAC,OAAO,CAAC;IACrD,8BAA8B,EAAE,gBAAgB,CAAC,WAAW,CAAC;IAC7D,wBAAwB,EAAE,gBAAgB,CAAC,KAAK,CAAC;IACjD,yBAAyB,EAAE,gBAAgB,CAAC,MAAM,CAAC;IACnD,qBAAqB,EAAE,eAAe,CAAC,GAAG,CAAC;CAC9C;AACD,MAAM,WAAW,QAAQ;CACxB;AACD,eAAO,MAAM,UAAU,KAA6rL,CAAC;AACrtL,eAAO,MAAM,MAAM,yBAA8D,CAAC"}
@@ -6,6 +6,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.schema = exports.schemaJson = void 0;
7
7
  const codec_protobuf_1 = require("@dxos/codec-protobuf");
8
8
  const substitutions_1 = __importDefault(require("../substitutions"));
9
- exports.schemaJson = JSON.parse("{\"nested\":{\"dxos\":{\"nested\":{\"credentials\":{\"nested\":{\"Message\":{\"fields\":{\"payload\":{\"rule\":\"required\",\"type\":\"google.protobuf.Any\",\"id\":1,\"comment\":null}},\"comment\":null},\"SignedMessage\":{\"fields\":{\"signed\":{\"rule\":\"required\",\"type\":\"Signed\",\"id\":1,\"comment\":null},\"signatures\":{\"rule\":\"repeated\",\"type\":\"Signature\",\"id\":2,\"comment\":null}},\"nested\":{\"Signature\":{\"fields\":{\"key\":{\"rule\":\"required\",\"type\":\"PubKey\",\"id\":1,\"comment\":null},\"signature\":{\"rule\":\"required\",\"type\":\"bytes\",\"id\":2,\"comment\":null},\"keyChain\":{\"type\":\"KeyChain\",\"id\":3,\"comment\":null}},\"comment\":null},\"Signed\":{\"fields\":{\"created\":{\"rule\":\"required\",\"type\":\"string\",\"id\":1,\"comment\":null},\"nonce\":{\"rule\":\"required\",\"type\":\"bytes\",\"id\":2,\"comment\":null},\"payload\":{\"rule\":\"required\",\"type\":\"google.protobuf.Any\",\"id\":10,\"comment\":null}},\"comment\":null}},\"comment\":\"A generic container message used whenever messages are signed (e.g. PartyCredential)\"}}},\"halo\":{\"nested\":{\"keys\":{\"nested\":{\"KeyChain\":{\"fields\":{\"publicKey\":{\"rule\":\"required\",\"type\":\"PubKey\",\"id\":1,\"comment\":null},\"message\":{\"rule\":\"required\",\"type\":\"SignedMessage\",\"id\":2,\"comment\":null},\"parents\":{\"rule\":\"repeated\",\"type\":\"KeyChain\",\"id\":3,\"comment\":null}},\"comment\":null},\"KeyRecord\":{\"fields\":{\"type\":{\"rule\":\"required\",\"type\":\"KeyType\",\"id\":1,\"comment\":\"The `KeyType` type of the key. This is often unknown for keys from other sources.\"},\"publicKey\":{\"rule\":\"required\",\"type\":\"PubKey\",\"id\":2,\"comment\":\"The public key as a Buffer (required).\"},\"secretKey\":{\"type\":\"PrivKey\",\"id\":3,\"comment\":\"The secret key as a Buffer (this will never be visible outside the Keyring).\"},\"hint\":{\"type\":\"bool\",\"id\":4,\"comment\":\"Is this key from a Greeting \\\"hint\\\"?\"},\"own\":{\"type\":\"bool\",\"id\":5,\"comment\":\"Determines if this is our key?\\nUsually true if `secretKey` is present; may be false for \\\"inception keys\\\" such as the Party key.\"},\"trusted\":{\"type\":\"bool\",\"id\":6,\"comment\":\"Is this key to be trusted?\"},\"added\":{\"type\":\"string\",\"id\":7,\"comment\":\"An RFC-3339 date/time string for when the key was added to the Keyring.\"},\"created\":{\"type\":\"string\",\"id\":8,\"comment\":\"An RFC-3339 date/time string for when the key was created.\"}},\"comment\":null},\"KeyRecordList\":{\"fields\":{\"keys\":{\"rule\":\"repeated\",\"type\":\"KeyRecord\",\"id\":1,\"comment\":null}},\"comment\":null},\"KeyType\":{\"values\":{\"UNKNOWN\":0,\"IDENTITY\":1,\"DEVICE\":2,\"PARTY\":3,\"FEED\":4,\"DXNS_ADDRESS\":5},\"comment\":null,\"comments\":{\"UNKNOWN\":null,\"IDENTITY\":null,\"DEVICE\":null,\"PARTY\":null,\"FEED\":null,\"DXNS_ADDRESS\":null}},\"PrivKey\":{\"fields\":{\"data\":{\"type\":\"bytes\",\"id\":1,\"comment\":null}},\"comment\":null},\"PubKey\":{\"fields\":{\"data\":{\"type\":\"bytes\",\"id\":1,\"comment\":null}},\"comment\":null}}}}},\"mesh\":{\"nested\":{\"signal\":{\"nested\":{\"Acknowledgement\":{\"fields\":{\"messageId\":{\"type\":\"PubKey\",\"id\":1,\"comment\":null}},\"comment\":null},\"Answer\":{\"fields\":{\"accept\":{\"type\":\"bool\",\"id\":1,\"comment\":null},\"offerMessageId\":{\"type\":\"PubKey\",\"id\":2,\"comment\":\"MessageId of the Offer being answered.\"}},\"comment\":null},\"Message\":{\"fields\":{\"id\":{\"type\":\"PubKey\",\"id\":1,\"comment\":\"Sender's public key.\"},\"remoteId\":{\"type\":\"PubKey\",\"id\":2,\"comment\":\"Receiver`s public key.\"},\"topic\":{\"type\":\"PubKey\",\"id\":3,\"comment\":\"Swarm identefier.\"},\"sessionId\":{\"type\":\"PubKey\",\"id\":4,\"comment\":\"Unique connection identifier.\"},\"data\":{\"type\":\"MessageData\",\"id\":5,\"comment\":\"Message payload.\"},\"messageId\":{\"type\":\"PubKey\",\"id\":6,\"comment\":\"Unique message identifier. Used for Acknolegment and matching Anwers to Offers.\"}},\"comment\":null},\"MessageData\":{\"oneofs\":{\"payload\":{\"oneof\":[\"offer\",\"answer\",\"signal\",\"ack\"],\"comment\":null}},\"fields\":{\"offer\":{\"type\":\"Offer\",\"id\":1,\"comment\":null},\"answer\":{\"type\":\"Answer\",\"id\":2,\"comment\":null},\"signal\":{\"type\":\"Signal\",\"id\":3,\"comment\":null},\"ack\":{\"type\":\"Acknowledgement\",\"id\":4,\"comment\":null}},\"comment\":null},\"Offer\":{\"fields\":{},\"comment\":null},\"Signal\":{\"fields\":{\"json\":{\"type\":\"string\",\"id\":1,\"comment\":null}},\"comment\":null}}}}}}},\"google\":{\"nested\":{\"protobuf\":{\"nested\":{\"Any\":{\"fields\":{\"type_url\":{\"type\":\"string\",\"id\":1},\"value\":{\"type\":\"bytes\",\"id\":2}},\"comment\":null}}}}}}}");
9
+ exports.schemaJson = JSON.parse("{\"nested\":{\"dxos\":{\"nested\":{\"credentials\":{\"nested\":{\"Message\":{\"fields\":{\"payload\":{\"rule\":\"required\",\"type\":\"google.protobuf.Any\",\"id\":1,\"comment\":null}},\"comment\":null},\"SignedMessage\":{\"fields\":{\"signed\":{\"rule\":\"required\",\"type\":\"Signed\",\"id\":1,\"comment\":\"The signed message contents.\"},\"signatures\":{\"rule\":\"repeated\",\"type\":\"Signature\",\"id\":2,\"comment\":\"An array of Signatures, one for each key that signed the message.\"}},\"nested\":{\"Signature\":{\"oneofs\":{\"_keyChain\":{\"oneof\":[\"keyChain\"]}},\"fields\":{\"key\":{\"rule\":\"required\",\"type\":\"PubKey\",\"id\":1,\"comment\":\"The publicKey of the keypair that made this signature.\"},\"signature\":{\"rule\":\"required\",\"type\":\"bytes\",\"id\":2,\"comment\":\"The bytes of the signature.\"},\"keyChain\":{\"type\":\"KeyChain\",\"id\":3,\"options\":{\"proto3_optional\":true},\"comment\":\"The certification chain of SignedMessages for this key.\"}},\"comment\":null},\"Signed\":{\"fields\":{\"created\":{\"rule\":\"required\",\"type\":\"string\",\"id\":1,\"comment\":\"RFC-3339 datetime string.\"},\"nonce\":{\"rule\":\"required\",\"type\":\"bytes\",\"id\":2,\"comment\":null},\"payload\":{\"rule\":\"required\",\"type\":\"google.protobuf.Any\",\"id\":10,\"comment\":\"The payload to be signed.\"}},\"comment\":null}},\"comment\":\"A generic container message used whenever messages are signed (e.g. PartyCredential)\"}}},\"halo\":{\"nested\":{\"keys\":{\"nested\":{\"KeyChain\":{\"fields\":{\"publicKey\":{\"rule\":\"required\",\"type\":\"PubKey\",\"id\":1,\"comment\":null},\"message\":{\"rule\":\"required\",\"type\":\"SignedMessage\",\"id\":2,\"comment\":null},\"parents\":{\"rule\":\"repeated\",\"type\":\"KeyChain\",\"id\":3,\"comment\":null}},\"comment\":null},\"KeyRecord\":{\"oneofs\":{\"_secretKey\":{\"oneof\":[\"secretKey\"]},\"_hint\":{\"oneof\":[\"hint\"]},\"_own\":{\"oneof\":[\"own\"]},\"_trusted\":{\"oneof\":[\"trusted\"]},\"_added\":{\"oneof\":[\"added\"]},\"_created\":{\"oneof\":[\"created\"]}},\"fields\":{\"type\":{\"rule\":\"required\",\"type\":\"KeyType\",\"id\":1,\"comment\":\"The `KeyType` type of the key. This is often unknown for keys from other sources.\"},\"publicKey\":{\"rule\":\"required\",\"type\":\"PubKey\",\"id\":2,\"comment\":\"The public key as a Buffer (required).\"},\"secretKey\":{\"type\":\"PrivKey\",\"id\":3,\"options\":{\"proto3_optional\":true},\"comment\":\"The secret key as a Buffer (this will never be visible outside the Keyring).\"},\"hint\":{\"type\":\"bool\",\"id\":4,\"options\":{\"proto3_optional\":true},\"comment\":\"Is this key from a Greeting \\\"hint\\\"?\"},\"own\":{\"type\":\"bool\",\"id\":5,\"options\":{\"proto3_optional\":true},\"comment\":\"Determines if this is our key?\\nUsually true if `secretKey` is present; may be false for \\\"inception keys\\\" such as the Party key.\"},\"trusted\":{\"type\":\"bool\",\"id\":6,\"options\":{\"proto3_optional\":true},\"comment\":\"Is this key to be trusted?\"},\"added\":{\"type\":\"string\",\"id\":7,\"options\":{\"proto3_optional\":true},\"comment\":\"An RFC-3339 date/time string for when the key was added to the Keyring.\"},\"created\":{\"type\":\"string\",\"id\":8,\"options\":{\"proto3_optional\":true},\"comment\":\"An RFC-3339 date/time string for when the key was created.\"}},\"comment\":null},\"KeyRecordList\":{\"fields\":{\"keys\":{\"rule\":\"repeated\",\"type\":\"KeyRecord\",\"id\":1,\"comment\":null}},\"comment\":null},\"KeyType\":{\"values\":{\"UNKNOWN\":0,\"IDENTITY\":1,\"DEVICE\":2,\"PARTY\":3,\"FEED\":4,\"DXNS_ADDRESS\":5},\"comment\":null,\"comments\":{\"UNKNOWN\":null,\"IDENTITY\":null,\"DEVICE\":null,\"PARTY\":null,\"FEED\":null,\"DXNS_ADDRESS\":null}},\"PrivKey\":{\"fields\":{\"data\":{\"type\":\"bytes\",\"id\":1,\"comment\":null}},\"comment\":null},\"PubKey\":{\"fields\":{\"data\":{\"type\":\"bytes\",\"id\":1,\"comment\":null}},\"comment\":null}}}}},\"mesh\":{\"nested\":{\"signal\":{\"nested\":{\"Acknowledgement\":{\"fields\":{\"messageId\":{\"type\":\"PubKey\",\"id\":1,\"comment\":null}},\"comment\":null},\"Answer\":{\"oneofs\":{\"_offerMessageId\":{\"oneof\":[\"offerMessageId\"]}},\"fields\":{\"accept\":{\"type\":\"bool\",\"id\":1,\"comment\":null},\"offerMessageId\":{\"type\":\"PubKey\",\"id\":2,\"options\":{\"proto3_optional\":true},\"comment\":\"MessageId of the Offer being answered.\"}},\"comment\":null},\"Message\":{\"oneofs\":{\"_messageId\":{\"oneof\":[\"messageId\"]}},\"fields\":{\"id\":{\"type\":\"PubKey\",\"id\":1,\"comment\":\"Sender's public key.\"},\"remoteId\":{\"type\":\"PubKey\",\"id\":2,\"comment\":\"Receiver`s public key.\"},\"topic\":{\"type\":\"PubKey\",\"id\":3,\"comment\":\"Swarm identefier.\"},\"sessionId\":{\"type\":\"PubKey\",\"id\":4,\"comment\":\"Unique connection identifier.\"},\"data\":{\"type\":\"MessageData\",\"id\":5,\"comment\":\"Message payload.\"},\"messageId\":{\"type\":\"PubKey\",\"id\":6,\"options\":{\"proto3_optional\":true},\"comment\":\"Unique message identifier. Used for Acknolegment and matching Anwers to Offers.\"}},\"comment\":null},\"MessageData\":{\"oneofs\":{\"payload\":{\"oneof\":[\"offer\",\"answer\",\"signal\",\"ack\"],\"comment\":null}},\"fields\":{\"offer\":{\"type\":\"Offer\",\"id\":1,\"comment\":null},\"answer\":{\"type\":\"Answer\",\"id\":2,\"comment\":null},\"signal\":{\"type\":\"Signal\",\"id\":3,\"comment\":null},\"ack\":{\"type\":\"Acknowledgement\",\"id\":4,\"comment\":null}},\"comment\":null},\"Offer\":{\"fields\":{},\"comment\":null},\"Signal\":{\"fields\":{\"json\":{\"type\":\"string\",\"id\":1,\"comment\":null}},\"comment\":null}}}}}}},\"google\":{\"nested\":{\"protobuf\":{\"nested\":{\"Any\":{\"fields\":{\"type_url\":{\"type\":\"string\",\"id\":1},\"value\":{\"type\":\"bytes\",\"id\":2}},\"comment\":null}}}}}}}");
10
10
  exports.schema = codec_protobuf_1.Schema.fromJson(exports.schemaJson, substitutions_1.default);
11
11
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/proto/gen/index.ts"],"names":[],"mappings":";;;;;;AAAA,yDAA8C;AAK9C,qEAA6C;AAsBhC,QAAA,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,+pJAA+pJ,CAAC,CAAC;AACzrJ,QAAA,MAAM,GAAG,uBAAM,CAAC,QAAQ,CAAkB,kBAAU,EAAE,uBAAa,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/proto/gen/index.ts"],"names":[],"mappings":";;;;;;AAAA,yDAA8C;AAK9C,qEAA6C;AAsBhC,QAAA,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,8qLAA8qL,CAAC,CAAC;AACxsL,QAAA,MAAM,GAAG,uBAAM,CAAC,QAAQ,CAAkB,kBAAU,EAAE,uBAAa,CAAC,CAAC"}