@remnawave/xtls-sdk 0.6.2 → 0.7.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.
Files changed (33) hide show
  1. package/build/src/common/utils/decode-user/constants/account-types.d.ts.map +1 -1
  2. package/build/src/common/utils/decode-user/constants/account-types.js +1 -0
  3. package/build/src/xray-protos/app/proxyman/config.d.ts +0 -37
  4. package/build/src/xray-protos/app/proxyman/config.d.ts.map +1 -1
  5. package/build/src/xray-protos/app/proxyman/config.js +8 -276
  6. package/build/src/xray-protos/common/protocol/server_spec.d.ts +1 -1
  7. package/build/src/xray-protos/common/protocol/server_spec.d.ts.map +1 -1
  8. package/build/src/xray-protos/common/protocol/server_spec.js +8 -8
  9. package/build/src/xray-protos/proxy/http/config.d.ts +1 -1
  10. package/build/src/xray-protos/proxy/http/config.d.ts.map +1 -1
  11. package/build/src/xray-protos/proxy/http/config.js +10 -8
  12. package/build/src/xray-protos/proxy/shadowsocks/config.d.ts +1 -1
  13. package/build/src/xray-protos/proxy/shadowsocks/config.d.ts.map +1 -1
  14. package/build/src/xray-protos/proxy/shadowsocks/config.js +10 -8
  15. package/build/src/xray-protos/proxy/socks/config.d.ts +1 -1
  16. package/build/src/xray-protos/proxy/socks/config.d.ts.map +1 -1
  17. package/build/src/xray-protos/proxy/socks/config.js +10 -8
  18. package/build/src/xray-protos/proxy/trojan/config.d.ts +1 -1
  19. package/build/src/xray-protos/proxy/trojan/config.d.ts.map +1 -1
  20. package/build/src/xray-protos/proxy/trojan/config.js +10 -8
  21. package/build/src/xray-protos/proxy/vless/account.d.ts +6 -0
  22. package/build/src/xray-protos/proxy/vless/account.d.ts.map +1 -1
  23. package/build/src/xray-protos/proxy/vless/account.js +81 -2
  24. package/build/src/xray-protos/proxy/vless/outbound/config.d.ts +1 -1
  25. package/build/src/xray-protos/proxy/vless/outbound/config.d.ts.map +1 -1
  26. package/build/src/xray-protos/proxy/vless/outbound/config.js +13 -11
  27. package/build/src/xray-protos/proxy/vmess/inbound/config.d.ts +0 -2
  28. package/build/src/xray-protos/proxy/vmess/inbound/config.d.ts.map +1 -1
  29. package/build/src/xray-protos/proxy/vmess/inbound/config.js +1 -18
  30. package/build/src/xray-protos/proxy/vmess/outbound/config.d.ts +1 -1
  31. package/build/src/xray-protos/proxy/vmess/outbound/config.d.ts.map +1 -1
  32. package/build/src/xray-protos/proxy/vmess/outbound/config.js +13 -10
  33. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"account-types.d.ts","sourceRoot":"","sources":["../../../../../../src/common/utils/decode-user/constants/account-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,6CAA6C,CAAC;AACvF,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,6CAA6C,CAAC;AACtF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,kDAAkD,CAAC;AACjG,OAAO,EAAE,OAAO,IAAI,sBAAsB,EAAE,MAAM,uDAAuD,CAAC;AAC1G,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,4CAA4C,CAAC;AACrF,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,2CAA2C,CAAC;AAEnF,eAAO,MAAM,aAAa;;;;uCAII,aAAa,KAAG,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC;;;;;uCAO5C,YAAY,KAAG,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC;;;;;uCAY1C,kBAAkB,KAAG,IAAI,CAAC,kBAAkB,EAAE,OAAO,CAAC;;;;;uCAStD,sBAAsB,KAAG,IAAI,CAAC,sBAAsB,EAAE,OAAO,CAAC;;;;;uCAO9D,YAAY,KAAG,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC;;;;;uCAQ1C,WAAW,KAAG,IAAI,CAAC,WAAW,EAAE,OAAO,CAAC;;CAK5D,CAAC"}
1
+ {"version":3,"file":"account-types.d.ts","sourceRoot":"","sources":["../../../../../../src/common/utils/decode-user/constants/account-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,6CAA6C,CAAC;AACvF,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,6CAA6C,CAAC;AACtF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,kDAAkD,CAAC;AACjG,OAAO,EAAE,OAAO,IAAI,sBAAsB,EAAE,MAAM,uDAAuD,CAAC;AAC1G,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,4CAA4C,CAAC;AACrF,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,2CAA2C,CAAC;AAEnF,eAAO,MAAM,aAAa;;;;uCAII,aAAa,KAAG,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC;;;;;uCAO5C,YAAY,KAAG,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC;;;;;uCAa1C,kBAAkB,KAAG,IAAI,CAAC,kBAAkB,EAAE,OAAO,CAAC;;;;;uCAStD,sBAAsB,KAAG,IAAI,CAAC,sBAAsB,EAAE,OAAO,CAAC;;;;;uCAO9D,YAAY,KAAG,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC;;;;;uCAQ1C,WAAW,KAAG,IAAI,CAAC,WAAW,EAAE,OAAO,CAAC;;CAK5D,CAAC"}
@@ -25,6 +25,7 @@ exports.ACCOUNT_TYPES = {
25
25
  xorMode: acc.xorMode,
26
26
  seconds: acc.seconds,
27
27
  padding: acc.padding,
28
+ reverse: acc.reverse,
28
29
  }),
29
30
  },
30
31
  [config_2.Account.$type]: {
@@ -7,39 +7,6 @@ export declare const protobufPackage = "xray.app.proxyman";
7
7
  export interface InboundConfig {
8
8
  $type: "xray.app.proxyman.InboundConfig";
9
9
  }
10
- export interface AllocationStrategy {
11
- $type: "xray.app.proxyman.AllocationStrategy";
12
- type: AllocationStrategy_Type;
13
- /**
14
- * Number of handlers (ports) running in parallel.
15
- * Default value is 3 if unset.
16
- */
17
- concurrency: AllocationStrategy_AllocationStrategyConcurrency | undefined;
18
- /**
19
- * Number of minutes before a handler is regenerated.
20
- * Default value is 5 if unset.
21
- */
22
- refresh: AllocationStrategy_AllocationStrategyRefresh | undefined;
23
- }
24
- export declare enum AllocationStrategy_Type {
25
- /** Always - Always allocate all connection handlers. */
26
- Always = 0,
27
- /** Random - Randomly allocate specific range of handlers. */
28
- Random = 1,
29
- /** External - External. Not supported yet. */
30
- External = 2,
31
- UNRECOGNIZED = -1
32
- }
33
- export declare function allocationStrategy_TypeFromJSON(object: any): AllocationStrategy_Type;
34
- export declare function allocationStrategy_TypeToJSON(object: AllocationStrategy_Type): string;
35
- export interface AllocationStrategy_AllocationStrategyConcurrency {
36
- $type: "xray.app.proxyman.AllocationStrategy.AllocationStrategyConcurrency";
37
- value: number;
38
- }
39
- export interface AllocationStrategy_AllocationStrategyRefresh {
40
- $type: "xray.app.proxyman.AllocationStrategy.AllocationStrategyRefresh";
41
- value: number;
42
- }
43
10
  export interface SniffingConfig {
44
11
  $type: "xray.app.proxyman.SniffingConfig";
45
12
  /** Whether or not to enable content sniffing on an inbound connection. */
@@ -64,7 +31,6 @@ export interface ReceiverConfig {
64
31
  portList: PortList | undefined;
65
32
  /** Listen specifies the IP address that the Receiver should listen on. */
66
33
  listen: IPOrDomain | undefined;
67
- allocationStrategy: AllocationStrategy | undefined;
68
34
  streamSettings: StreamConfig | undefined;
69
35
  receiveOriginalDestination: boolean;
70
36
  sniffingSettings: SniffingConfig | undefined;
@@ -100,9 +66,6 @@ export interface MultiplexingConfig {
100
66
  xudpProxyUDP443: string;
101
67
  }
102
68
  export declare const InboundConfig: MessageFns<InboundConfig, "xray.app.proxyman.InboundConfig">;
103
- export declare const AllocationStrategy: MessageFns<AllocationStrategy, "xray.app.proxyman.AllocationStrategy">;
104
- export declare const AllocationStrategy_AllocationStrategyConcurrency: MessageFns<AllocationStrategy_AllocationStrategyConcurrency, "xray.app.proxyman.AllocationStrategy.AllocationStrategyConcurrency">;
105
- export declare const AllocationStrategy_AllocationStrategyRefresh: MessageFns<AllocationStrategy_AllocationStrategyRefresh, "xray.app.proxyman.AllocationStrategy.AllocationStrategyRefresh">;
106
69
  export declare const SniffingConfig: MessageFns<SniffingConfig, "xray.app.proxyman.SniffingConfig">;
107
70
  export declare const ReceiverConfig: MessageFns<ReceiverConfig, "xray.app.proxyman.ReceiverConfig">;
108
71
  export declare const InboundHandlerConfig: MessageFns<InboundHandlerConfig, "xray.app.proxyman.InboundHandlerConfig">;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/app/proxyman/config.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACrE,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AACjE,OAAO,EACL,cAAc,EAGd,WAAW,EACX,YAAY,EACb,MAAM,iCAAiC,CAAC;AAGzC,eAAO,MAAM,eAAe,sBAAsB,CAAC;AAEnD,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,iCAAiC,CAAC;CAC1C;AAED,MAAM,WAAW,kBAAkB;IACjC,KAAK,EAAE,sCAAsC,CAAC;IAC9C,IAAI,EAAE,uBAAuB,CAAC;IAC9B;;;OAGG;IACH,WAAW,EACP,gDAAgD,GAChD,SAAS,CAAC;IACd;;;OAGG;IACH,OAAO,EAAE,4CAA4C,GAAG,SAAS,CAAC;CACnE;AAED,oBAAY,uBAAuB;IACjC,wDAAwD;IACxD,MAAM,IAAI;IACV,6DAA6D;IAC7D,MAAM,IAAI;IACV,8CAA8C;IAC9C,QAAQ,IAAI;IACZ,YAAY,KAAK;CAClB;AAED,wBAAgB,+BAA+B,CAAC,MAAM,EAAE,GAAG,GAAG,uB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pF,MAAM,MAAM,WAAW,CAAC,CAAC,IAAI,CAAC,SAAS,OAAO,GAAG,CAAC,GAC9C,CAAC,SAAS,UAAU,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,UAAU,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,GACtE,CAAC,SAAS,aAAa,CAAC,MAAM,CAAC,CAAC,GAAG,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,GAChE,CAAC,SAAS,EAAE,GAAG;KAAG,CAAC,IAAI,OAAO,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CAAE,GACvE,OAAO,CAAC,CAAC,CAAC,CAAC;AAMf,MAAM,WAAW,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM;IAC7C,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAClB,MAAM,CAAC,OAAO,EAAE,CAAC,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,YAAY,CAAC;IACxD,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC;IAC7D,QAAQ,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -5,9 +5,7 @@
5
5
  // protoc v5.29.3
6
6
  // source: app/proxyman/config.proto
7
7
  Object.defineProperty(exports, "__esModule", { value: true });
8
- exports.MultiplexingConfig = exports.SenderConfig = exports.OutboundConfig = exports.InboundHandlerConfig = exports.ReceiverConfig = exports.SniffingConfig = exports.AllocationStrategy_AllocationStrategyRefresh = exports.AllocationStrategy_AllocationStrategyConcurrency = exports.AllocationStrategy = exports.InboundConfig = exports.AllocationStrategy_Type = exports.protobufPackage = void 0;
9
- exports.allocationStrategy_TypeFromJSON = allocationStrategy_TypeFromJSON;
10
- exports.allocationStrategy_TypeToJSON = allocationStrategy_TypeToJSON;
8
+ exports.MultiplexingConfig = exports.SenderConfig = exports.OutboundConfig = exports.InboundHandlerConfig = exports.ReceiverConfig = exports.SniffingConfig = exports.InboundConfig = exports.protobufPackage = void 0;
11
9
  /* eslint-disable */
12
10
  const wire_1 = require("@bufbuild/protobuf/wire");
13
11
  const address_1 = require("../../common/net/address");
@@ -16,46 +14,6 @@ const typed_message_1 = require("../../common/serial/typed_message");
16
14
  const config_1 = require("../../transport/internet/config");
17
15
  const typeRegistry_1 = require("../../typeRegistry");
18
16
  exports.protobufPackage = "xray.app.proxyman";
19
- var AllocationStrategy_Type;
20
- (function (AllocationStrategy_Type) {
21
- /** Always - Always allocate all connection handlers. */
22
- AllocationStrategy_Type[AllocationStrategy_Type["Always"] = 0] = "Always";
23
- /** Random - Randomly allocate specific range of handlers. */
24
- AllocationStrategy_Type[AllocationStrategy_Type["Random"] = 1] = "Random";
25
- /** External - External. Not supported yet. */
26
- AllocationStrategy_Type[AllocationStrategy_Type["External"] = 2] = "External";
27
- AllocationStrategy_Type[AllocationStrategy_Type["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
28
- })(AllocationStrategy_Type || (exports.AllocationStrategy_Type = AllocationStrategy_Type = {}));
29
- function allocationStrategy_TypeFromJSON(object) {
30
- switch (object) {
31
- case 0:
32
- case "Always":
33
- return AllocationStrategy_Type.Always;
34
- case 1:
35
- case "Random":
36
- return AllocationStrategy_Type.Random;
37
- case 2:
38
- case "External":
39
- return AllocationStrategy_Type.External;
40
- case -1:
41
- case "UNRECOGNIZED":
42
- default:
43
- return AllocationStrategy_Type.UNRECOGNIZED;
44
- }
45
- }
46
- function allocationStrategy_TypeToJSON(object) {
47
- switch (object) {
48
- case AllocationStrategy_Type.Always:
49
- return "Always";
50
- case AllocationStrategy_Type.Random:
51
- return "Random";
52
- case AllocationStrategy_Type.External:
53
- return "External";
54
- case AllocationStrategy_Type.UNRECOGNIZED:
55
- default:
56
- return "UNRECOGNIZED";
57
- }
58
- }
59
17
  function createBaseInboundConfig() {
60
18
  return { $type: "xray.app.proxyman.InboundConfig" };
61
19
  }
@@ -95,212 +53,6 @@ exports.InboundConfig = {
95
53
  },
96
54
  };
97
55
  typeRegistry_1.messageTypeRegistry.set(exports.InboundConfig.$type, exports.InboundConfig);
98
- function createBaseAllocationStrategy() {
99
- return { $type: "xray.app.proxyman.AllocationStrategy", type: 0, concurrency: undefined, refresh: undefined };
100
- }
101
- exports.AllocationStrategy = {
102
- $type: "xray.app.proxyman.AllocationStrategy",
103
- encode(message, writer = new wire_1.BinaryWriter()) {
104
- if (message.type !== 0) {
105
- writer.uint32(8).int32(message.type);
106
- }
107
- if (message.concurrency !== undefined) {
108
- exports.AllocationStrategy_AllocationStrategyConcurrency.encode(message.concurrency, writer.uint32(18).fork()).join();
109
- }
110
- if (message.refresh !== undefined) {
111
- exports.AllocationStrategy_AllocationStrategyRefresh.encode(message.refresh, writer.uint32(26).fork()).join();
112
- }
113
- return writer;
114
- },
115
- decode(input, length) {
116
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
117
- let end = length === undefined ? reader.len : reader.pos + length;
118
- const message = createBaseAllocationStrategy();
119
- while (reader.pos < end) {
120
- const tag = reader.uint32();
121
- switch (tag >>> 3) {
122
- case 1: {
123
- if (tag !== 8) {
124
- break;
125
- }
126
- message.type = reader.int32();
127
- continue;
128
- }
129
- case 2: {
130
- if (tag !== 18) {
131
- break;
132
- }
133
- message.concurrency = exports.AllocationStrategy_AllocationStrategyConcurrency.decode(reader, reader.uint32());
134
- continue;
135
- }
136
- case 3: {
137
- if (tag !== 26) {
138
- break;
139
- }
140
- message.refresh = exports.AllocationStrategy_AllocationStrategyRefresh.decode(reader, reader.uint32());
141
- continue;
142
- }
143
- }
144
- if ((tag & 7) === 4 || tag === 0) {
145
- break;
146
- }
147
- reader.skip(tag & 7);
148
- }
149
- return message;
150
- },
151
- fromJSON(object) {
152
- return {
153
- $type: exports.AllocationStrategy.$type,
154
- type: isSet(object.type) ? allocationStrategy_TypeFromJSON(object.type) : 0,
155
- concurrency: isSet(object.concurrency)
156
- ? exports.AllocationStrategy_AllocationStrategyConcurrency.fromJSON(object.concurrency)
157
- : undefined,
158
- refresh: isSet(object.refresh)
159
- ? exports.AllocationStrategy_AllocationStrategyRefresh.fromJSON(object.refresh)
160
- : undefined,
161
- };
162
- },
163
- toJSON(message) {
164
- const obj = {};
165
- if (message.type !== 0) {
166
- obj.type = allocationStrategy_TypeToJSON(message.type);
167
- }
168
- if (message.concurrency !== undefined) {
169
- obj.concurrency = exports.AllocationStrategy_AllocationStrategyConcurrency.toJSON(message.concurrency);
170
- }
171
- if (message.refresh !== undefined) {
172
- obj.refresh = exports.AllocationStrategy_AllocationStrategyRefresh.toJSON(message.refresh);
173
- }
174
- return obj;
175
- },
176
- create(base) {
177
- return exports.AllocationStrategy.fromPartial(base ?? {});
178
- },
179
- fromPartial(object) {
180
- const message = createBaseAllocationStrategy();
181
- message.type = object.type ?? 0;
182
- message.concurrency = (object.concurrency !== undefined && object.concurrency !== null)
183
- ? exports.AllocationStrategy_AllocationStrategyConcurrency.fromPartial(object.concurrency)
184
- : undefined;
185
- message.refresh = (object.refresh !== undefined && object.refresh !== null)
186
- ? exports.AllocationStrategy_AllocationStrategyRefresh.fromPartial(object.refresh)
187
- : undefined;
188
- return message;
189
- },
190
- };
191
- typeRegistry_1.messageTypeRegistry.set(exports.AllocationStrategy.$type, exports.AllocationStrategy);
192
- function createBaseAllocationStrategy_AllocationStrategyConcurrency() {
193
- return { $type: "xray.app.proxyman.AllocationStrategy.AllocationStrategyConcurrency", value: 0 };
194
- }
195
- exports.AllocationStrategy_AllocationStrategyConcurrency = {
196
- $type: "xray.app.proxyman.AllocationStrategy.AllocationStrategyConcurrency",
197
- encode(message, writer = new wire_1.BinaryWriter()) {
198
- if (message.value !== 0) {
199
- writer.uint32(8).uint32(message.value);
200
- }
201
- return writer;
202
- },
203
- decode(input, length) {
204
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
205
- let end = length === undefined ? reader.len : reader.pos + length;
206
- const message = createBaseAllocationStrategy_AllocationStrategyConcurrency();
207
- while (reader.pos < end) {
208
- const tag = reader.uint32();
209
- switch (tag >>> 3) {
210
- case 1: {
211
- if (tag !== 8) {
212
- break;
213
- }
214
- message.value = reader.uint32();
215
- continue;
216
- }
217
- }
218
- if ((tag & 7) === 4 || tag === 0) {
219
- break;
220
- }
221
- reader.skip(tag & 7);
222
- }
223
- return message;
224
- },
225
- fromJSON(object) {
226
- return {
227
- $type: exports.AllocationStrategy_AllocationStrategyConcurrency.$type,
228
- value: isSet(object.value) ? globalThis.Number(object.value) : 0,
229
- };
230
- },
231
- toJSON(message) {
232
- const obj = {};
233
- if (message.value !== 0) {
234
- obj.value = Math.round(message.value);
235
- }
236
- return obj;
237
- },
238
- create(base) {
239
- return exports.AllocationStrategy_AllocationStrategyConcurrency.fromPartial(base ?? {});
240
- },
241
- fromPartial(object) {
242
- const message = createBaseAllocationStrategy_AllocationStrategyConcurrency();
243
- message.value = object.value ?? 0;
244
- return message;
245
- },
246
- };
247
- typeRegistry_1.messageTypeRegistry.set(exports.AllocationStrategy_AllocationStrategyConcurrency.$type, exports.AllocationStrategy_AllocationStrategyConcurrency);
248
- function createBaseAllocationStrategy_AllocationStrategyRefresh() {
249
- return { $type: "xray.app.proxyman.AllocationStrategy.AllocationStrategyRefresh", value: 0 };
250
- }
251
- exports.AllocationStrategy_AllocationStrategyRefresh = {
252
- $type: "xray.app.proxyman.AllocationStrategy.AllocationStrategyRefresh",
253
- encode(message, writer = new wire_1.BinaryWriter()) {
254
- if (message.value !== 0) {
255
- writer.uint32(8).uint32(message.value);
256
- }
257
- return writer;
258
- },
259
- decode(input, length) {
260
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
261
- let end = length === undefined ? reader.len : reader.pos + length;
262
- const message = createBaseAllocationStrategy_AllocationStrategyRefresh();
263
- while (reader.pos < end) {
264
- const tag = reader.uint32();
265
- switch (tag >>> 3) {
266
- case 1: {
267
- if (tag !== 8) {
268
- break;
269
- }
270
- message.value = reader.uint32();
271
- continue;
272
- }
273
- }
274
- if ((tag & 7) === 4 || tag === 0) {
275
- break;
276
- }
277
- reader.skip(tag & 7);
278
- }
279
- return message;
280
- },
281
- fromJSON(object) {
282
- return {
283
- $type: exports.AllocationStrategy_AllocationStrategyRefresh.$type,
284
- value: isSet(object.value) ? globalThis.Number(object.value) : 0,
285
- };
286
- },
287
- toJSON(message) {
288
- const obj = {};
289
- if (message.value !== 0) {
290
- obj.value = Math.round(message.value);
291
- }
292
- return obj;
293
- },
294
- create(base) {
295
- return exports.AllocationStrategy_AllocationStrategyRefresh.fromPartial(base ?? {});
296
- },
297
- fromPartial(object) {
298
- const message = createBaseAllocationStrategy_AllocationStrategyRefresh();
299
- message.value = object.value ?? 0;
300
- return message;
301
- },
302
- };
303
- typeRegistry_1.messageTypeRegistry.set(exports.AllocationStrategy_AllocationStrategyRefresh.$type, exports.AllocationStrategy_AllocationStrategyRefresh);
304
56
  function createBaseSniffingConfig() {
305
57
  return {
306
58
  $type: "xray.app.proxyman.SniffingConfig",
@@ -433,7 +185,6 @@ function createBaseReceiverConfig() {
433
185
  $type: "xray.app.proxyman.ReceiverConfig",
434
186
  portList: undefined,
435
187
  listen: undefined,
436
- allocationStrategy: undefined,
437
188
  streamSettings: undefined,
438
189
  receiveOriginalDestination: false,
439
190
  sniffingSettings: undefined,
@@ -448,17 +199,14 @@ exports.ReceiverConfig = {
448
199
  if (message.listen !== undefined) {
449
200
  address_1.IPOrDomain.encode(message.listen, writer.uint32(18).fork()).join();
450
201
  }
451
- if (message.allocationStrategy !== undefined) {
452
- exports.AllocationStrategy.encode(message.allocationStrategy, writer.uint32(26).fork()).join();
453
- }
454
202
  if (message.streamSettings !== undefined) {
455
- config_1.StreamConfig.encode(message.streamSettings, writer.uint32(34).fork()).join();
203
+ config_1.StreamConfig.encode(message.streamSettings, writer.uint32(26).fork()).join();
456
204
  }
457
205
  if (message.receiveOriginalDestination !== false) {
458
- writer.uint32(40).bool(message.receiveOriginalDestination);
206
+ writer.uint32(32).bool(message.receiveOriginalDestination);
459
207
  }
460
208
  if (message.sniffingSettings !== undefined) {
461
- exports.SniffingConfig.encode(message.sniffingSettings, writer.uint32(58).fork()).join();
209
+ exports.SniffingConfig.encode(message.sniffingSettings, writer.uint32(50).fork()).join();
462
210
  }
463
211
  return writer;
464
212
  },
@@ -487,25 +235,18 @@ exports.ReceiverConfig = {
487
235
  if (tag !== 26) {
488
236
  break;
489
237
  }
490
- message.allocationStrategy = exports.AllocationStrategy.decode(reader, reader.uint32());
491
- continue;
492
- }
493
- case 4: {
494
- if (tag !== 34) {
495
- break;
496
- }
497
238
  message.streamSettings = config_1.StreamConfig.decode(reader, reader.uint32());
498
239
  continue;
499
240
  }
500
- case 5: {
501
- if (tag !== 40) {
241
+ case 4: {
242
+ if (tag !== 32) {
502
243
  break;
503
244
  }
504
245
  message.receiveOriginalDestination = reader.bool();
505
246
  continue;
506
247
  }
507
- case 7: {
508
- if (tag !== 58) {
248
+ case 6: {
249
+ if (tag !== 50) {
509
250
  break;
510
251
  }
511
252
  message.sniffingSettings = exports.SniffingConfig.decode(reader, reader.uint32());
@@ -524,9 +265,6 @@ exports.ReceiverConfig = {
524
265
  $type: exports.ReceiverConfig.$type,
525
266
  portList: isSet(object.portList) ? port_1.PortList.fromJSON(object.portList) : undefined,
526
267
  listen: isSet(object.listen) ? address_1.IPOrDomain.fromJSON(object.listen) : undefined,
527
- allocationStrategy: isSet(object.allocationStrategy)
528
- ? exports.AllocationStrategy.fromJSON(object.allocationStrategy)
529
- : undefined,
530
268
  streamSettings: isSet(object.streamSettings) ? config_1.StreamConfig.fromJSON(object.streamSettings) : undefined,
531
269
  receiveOriginalDestination: isSet(object.receiveOriginalDestination)
532
270
  ? globalThis.Boolean(object.receiveOriginalDestination)
@@ -542,9 +280,6 @@ exports.ReceiverConfig = {
542
280
  if (message.listen !== undefined) {
543
281
  obj.listen = address_1.IPOrDomain.toJSON(message.listen);
544
282
  }
545
- if (message.allocationStrategy !== undefined) {
546
- obj.allocationStrategy = exports.AllocationStrategy.toJSON(message.allocationStrategy);
547
- }
548
283
  if (message.streamSettings !== undefined) {
549
284
  obj.streamSettings = config_1.StreamConfig.toJSON(message.streamSettings);
550
285
  }
@@ -567,9 +302,6 @@ exports.ReceiverConfig = {
567
302
  message.listen = (object.listen !== undefined && object.listen !== null)
568
303
  ? address_1.IPOrDomain.fromPartial(object.listen)
569
304
  : undefined;
570
- message.allocationStrategy = (object.allocationStrategy !== undefined && object.allocationStrategy !== null)
571
- ? exports.AllocationStrategy.fromPartial(object.allocationStrategy)
572
- : undefined;
573
305
  message.streamSettings = (object.streamSettings !== undefined && object.streamSettings !== null)
574
306
  ? config_1.StreamConfig.fromPartial(object.streamSettings)
575
307
  : undefined;
@@ -6,7 +6,7 @@ export interface ServerEndpoint {
6
6
  $type: "xray.common.protocol.ServerEndpoint";
7
7
  address: IPOrDomain | undefined;
8
8
  port: number;
9
- user: User[];
9
+ user: User | undefined;
10
10
  }
11
11
  export declare const ServerEndpoint: MessageFns<ServerEndpoint, "xray.common.protocol.ServerEndpoint">;
12
12
  type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"server_spec.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/common/protocol/server_spec.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAErE,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAC5C,OAAO,EAAE,IAAI,EAAE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CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CAAE,GACvE,OAAO,CAAC,CAAC,CAAC,CAAC;AAMf,MAAM,WAAW,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM;IAC7C,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAClB,MAAM,CAAC,OAAO,EAAE,CAAC,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,YAAY,CAAC;IACxD,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC;IAC7D,QAAQ,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -13,7 +13,7 @@ const address_1 = require("../net/address");
13
13
  const user_1 = require("./user");
14
14
  exports.protobufPackage = "xray.common.protocol";
15
15
  function createBaseServerEndpoint() {
16
- return { $type: "xray.common.protocol.ServerEndpoint", address: undefined, port: 0, user: [] };
16
+ return { $type: "xray.common.protocol.ServerEndpoint", address: undefined, port: 0, user: undefined };
17
17
  }
18
18
  exports.ServerEndpoint = {
19
19
  $type: "xray.common.protocol.ServerEndpoint",
@@ -24,8 +24,8 @@ exports.ServerEndpoint = {
24
24
  if (message.port !== 0) {
25
25
  writer.uint32(16).uint32(message.port);
26
26
  }
27
- for (const v of message.user) {
28
- user_1.User.encode(v, writer.uint32(26).fork()).join();
27
+ if (message.user !== undefined) {
28
+ user_1.User.encode(message.user, writer.uint32(26).fork()).join();
29
29
  }
30
30
  return writer;
31
31
  },
@@ -54,7 +54,7 @@ exports.ServerEndpoint = {
54
54
  if (tag !== 26) {
55
55
  break;
56
56
  }
57
- message.user.push(user_1.User.decode(reader, reader.uint32()));
57
+ message.user = user_1.User.decode(reader, reader.uint32());
58
58
  continue;
59
59
  }
60
60
  }
@@ -70,7 +70,7 @@ exports.ServerEndpoint = {
70
70
  $type: exports.ServerEndpoint.$type,
71
71
  address: isSet(object.address) ? address_1.IPOrDomain.fromJSON(object.address) : undefined,
72
72
  port: isSet(object.port) ? globalThis.Number(object.port) : 0,
73
- user: globalThis.Array.isArray(object?.user) ? object.user.map((e) => user_1.User.fromJSON(e)) : [],
73
+ user: isSet(object.user) ? user_1.User.fromJSON(object.user) : undefined,
74
74
  };
75
75
  },
76
76
  toJSON(message) {
@@ -81,8 +81,8 @@ exports.ServerEndpoint = {
81
81
  if (message.port !== 0) {
82
82
  obj.port = Math.round(message.port);
83
83
  }
84
- if (message.user?.length) {
85
- obj.user = message.user.map((e) => user_1.User.toJSON(e));
84
+ if (message.user !== undefined) {
85
+ obj.user = user_1.User.toJSON(message.user);
86
86
  }
87
87
  return obj;
88
88
  },
@@ -95,7 +95,7 @@ exports.ServerEndpoint = {
95
95
  ? address_1.IPOrDomain.fromPartial(object.address)
96
96
  : undefined;
97
97
  message.port = object.port ?? 0;
98
- message.user = object.user?.map((e) => user_1.User.fromPartial(e)) || [];
98
+ message.user = (object.user !== undefined && object.user !== null) ? user_1.User.fromPartial(object.user) : undefined;
99
99
  return message;
100
100
  },
101
101
  };
@@ -29,7 +29,7 @@ export interface Header {
29
29
  export interface ClientConfig {
30
30
  $type: "xray.proxy.http.ClientConfig";
31
31
  /** Sever is a list of HTTP server addresses. */
32
- server: ServerEndpoint[];
32
+ server: ServerEndpoint | undefined;
33
33
  header: Header[];
34
34
  }
35
35
  export declare const Account: MessageFns<Account, "xray.proxy.http.Account">;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/proxy/http/config.ts"],"names":[],"mappings":"A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WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -330,13 +330,13 @@ exports.Header = {
330
330
  };
331
331
  typeRegistry_1.messageTypeRegistry.set(exports.Header.$type, exports.Header);
332
332
  function createBaseClientConfig() {
333
- return { $type: "xray.proxy.http.ClientConfig", server: [], header: [] };
333
+ return { $type: "xray.proxy.http.ClientConfig", server: undefined, header: [] };
334
334
  }
335
335
  exports.ClientConfig = {
336
336
  $type: "xray.proxy.http.ClientConfig",
337
337
  encode(message, writer = new wire_1.BinaryWriter()) {
338
- for (const v of message.server) {
339
- server_spec_1.ServerEndpoint.encode(v, writer.uint32(10).fork()).join();
338
+ if (message.server !== undefined) {
339
+ server_spec_1.ServerEndpoint.encode(message.server, writer.uint32(10).fork()).join();
340
340
  }
341
341
  for (const v of message.header) {
342
342
  exports.Header.encode(v, writer.uint32(18).fork()).join();
@@ -354,7 +354,7 @@ exports.ClientConfig = {
354
354
  if (tag !== 10) {
355
355
  break;
356
356
  }
357
- message.server.push(server_spec_1.ServerEndpoint.decode(reader, reader.uint32()));
357
+ message.server = server_spec_1.ServerEndpoint.decode(reader, reader.uint32());
358
358
  continue;
359
359
  }
360
360
  case 2: {
@@ -375,14 +375,14 @@ exports.ClientConfig = {
375
375
  fromJSON(object) {
376
376
  return {
377
377
  $type: exports.ClientConfig.$type,
378
- server: globalThis.Array.isArray(object?.server) ? object.server.map((e) => server_spec_1.ServerEndpoint.fromJSON(e)) : [],
378
+ server: isSet(object.server) ? server_spec_1.ServerEndpoint.fromJSON(object.server) : undefined,
379
379
  header: globalThis.Array.isArray(object?.header) ? object.header.map((e) => exports.Header.fromJSON(e)) : [],
380
380
  };
381
381
  },
382
382
  toJSON(message) {
383
383
  const obj = {};
384
- if (message.server?.length) {
385
- obj.server = message.server.map((e) => server_spec_1.ServerEndpoint.toJSON(e));
384
+ if (message.server !== undefined) {
385
+ obj.server = server_spec_1.ServerEndpoint.toJSON(message.server);
386
386
  }
387
387
  if (message.header?.length) {
388
388
  obj.header = message.header.map((e) => exports.Header.toJSON(e));
@@ -394,7 +394,9 @@ exports.ClientConfig = {
394
394
  },
395
395
  fromPartial(object) {
396
396
  const message = createBaseClientConfig();
397
- message.server = object.server?.map((e) => server_spec_1.ServerEndpoint.fromPartial(e)) || [];
397
+ message.server = (object.server !== undefined && object.server !== null)
398
+ ? server_spec_1.ServerEndpoint.fromPartial(object.server)
399
+ : undefined;
398
400
  message.header = object.header?.map((e) => exports.Header.fromPartial(e)) || [];
399
401
  return message;
400
402
  },
@@ -27,7 +27,7 @@ export interface ServerConfig {
27
27
  }
28
28
  export interface ClientConfig {
29
29
  $type: "xray.proxy.shadowsocks.ClientConfig";
30
- server: ServerEndpoint[];
30
+ server: ServerEndpoint | undefined;
31
31
  }
32
32
  export declare const Account: MessageFns<Account, "xray.proxy.shadowsocks.Account">;
33
33
  export declare const ServerConfig: MessageFns<ServerConfig, "xray.proxy.shadowsocks.ServerConfig">;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/proxy/shadowsocks/config.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACrE,OAAO,EAAE,OAAO,EAAkC,MAAM,0BAA0B,CAAC;AACnF,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,EAAE,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAGlD,eAAO,MAAM,eAAe,2BAA2B,CAAC;AAExD,oBAAY,UAAU;IACpB,OAAO,IAAI;IACX,WAAW,IAAI;IACf,WAAW,IAAI;IACf,iBAAiB,IAAI;IACrB,kBAAkB,IAAI;IACtB,IAAI,IAAI;IACR,YAAY,KAAK;CAClB;AAED,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,GAAG,GAAG,UAAU,CAyB1D;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,UAAU,GAAG,MAAM,CAkB3D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,KAAK,EAAE,CAAC,CAAC;IAClB,MAAM,CAAC,OAAO,EAAE,CAAC,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,YAAY,CAAC;IACxD,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC;IAC7D,QAAQ,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -237,13 +237,13 @@ exports.ServerConfig = {
237
237
  };
238
238
  typeRegistry_1.messageTypeRegistry.set(exports.ServerConfig.$type, exports.ServerConfig);
239
239
  function createBaseClientConfig() {
240
- return { $type: "xray.proxy.shadowsocks.ClientConfig", server: [] };
240
+ return { $type: "xray.proxy.shadowsocks.ClientConfig", server: undefined };
241
241
  }
242
242
  exports.ClientConfig = {
243
243
  $type: "xray.proxy.shadowsocks.ClientConfig",
244
244
  encode(message, writer = new wire_1.BinaryWriter()) {
245
- for (const v of message.server) {
246
- server_spec_1.ServerEndpoint.encode(v, writer.uint32(10).fork()).join();
245
+ if (message.server !== undefined) {
246
+ server_spec_1.ServerEndpoint.encode(message.server, writer.uint32(10).fork()).join();
247
247
  }
248
248
  return writer;
249
249
  },
@@ -258,7 +258,7 @@ exports.ClientConfig = {
258
258
  if (tag !== 10) {
259
259
  break;
260
260
  }
261
- message.server.push(server_spec_1.ServerEndpoint.decode(reader, reader.uint32()));
261
+ message.server = server_spec_1.ServerEndpoint.decode(reader, reader.uint32());
262
262
  continue;
263
263
  }
264
264
  }
@@ -272,13 +272,13 @@ exports.ClientConfig = {
272
272
  fromJSON(object) {
273
273
  return {
274
274
  $type: exports.ClientConfig.$type,
275
- server: globalThis.Array.isArray(object?.server) ? object.server.map((e) => server_spec_1.ServerEndpoint.fromJSON(e)) : [],
275
+ server: isSet(object.server) ? server_spec_1.ServerEndpoint.fromJSON(object.server) : undefined,
276
276
  };
277
277
  },
278
278
  toJSON(message) {
279
279
  const obj = {};
280
- if (message.server?.length) {
281
- obj.server = message.server.map((e) => server_spec_1.ServerEndpoint.toJSON(e));
280
+ if (message.server !== undefined) {
281
+ obj.server = server_spec_1.ServerEndpoint.toJSON(message.server);
282
282
  }
283
283
  return obj;
284
284
  },
@@ -287,7 +287,9 @@ exports.ClientConfig = {
287
287
  },
288
288
  fromPartial(object) {
289
289
  const message = createBaseClientConfig();
290
- message.server = object.server?.map((e) => server_spec_1.ServerEndpoint.fromPartial(e)) || [];
290
+ message.server = (object.server !== undefined && object.server !== null)
291
+ ? server_spec_1.ServerEndpoint.fromPartial(object.server)
292
+ : undefined;
291
293
  return message;
292
294
  },
293
295
  };
@@ -38,7 +38,7 @@ export interface ServerConfig_AccountsEntry {
38
38
  export interface ClientConfig {
39
39
  $type: "xray.proxy.socks.ClientConfig";
40
40
  /** Sever is a list of Socks server addresses. */
41
- server: ServerEndpoint[];
41
+ server: ServerEndpoint | undefined;
42
42
  }
43
43
  export declare const Account: MessageFns<Account, "xray.proxy.socks.Account">;
44
44
  export declare const ServerConfig: MessageFns<ServerConfig, "xray.proxy.socks.ServerConfig">;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/proxy/socks/config.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACrE,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAGnE,eAAO,MAAM,eAAe,qBAAqB,CAAC;AAElD,0DAA0D;AAC1D,oBAAY,QAAQ;IAClB,yDAAyD;IACzD,OA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AAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -339,13 +339,13 @@ exports.ServerConfig_AccountsEntry = {
339
339
  };
340
340
  typeRegistry_1.messageTypeRegistry.set(exports.ServerConfig_AccountsEntry.$type, exports.ServerConfig_AccountsEntry);
341
341
  function createBaseClientConfig() {
342
- return { $type: "xray.proxy.socks.ClientConfig", server: [] };
342
+ return { $type: "xray.proxy.socks.ClientConfig", server: undefined };
343
343
  }
344
344
  exports.ClientConfig = {
345
345
  $type: "xray.proxy.socks.ClientConfig",
346
346
  encode(message, writer = new wire_1.BinaryWriter()) {
347
- for (const v of message.server) {
348
- server_spec_1.ServerEndpoint.encode(v, writer.uint32(10).fork()).join();
347
+ if (message.server !== undefined) {
348
+ server_spec_1.ServerEndpoint.encode(message.server, writer.uint32(10).fork()).join();
349
349
  }
350
350
  return writer;
351
351
  },
@@ -360,7 +360,7 @@ exports.ClientConfig = {
360
360
  if (tag !== 10) {
361
361
  break;
362
362
  }
363
- message.server.push(server_spec_1.ServerEndpoint.decode(reader, reader.uint32()));
363
+ message.server = server_spec_1.ServerEndpoint.decode(reader, reader.uint32());
364
364
  continue;
365
365
  }
366
366
  }
@@ -374,13 +374,13 @@ exports.ClientConfig = {
374
374
  fromJSON(object) {
375
375
  return {
376
376
  $type: exports.ClientConfig.$type,
377
- server: globalThis.Array.isArray(object?.server) ? object.server.map((e) => server_spec_1.ServerEndpoint.fromJSON(e)) : [],
377
+ server: isSet(object.server) ? server_spec_1.ServerEndpoint.fromJSON(object.server) : undefined,
378
378
  };
379
379
  },
380
380
  toJSON(message) {
381
381
  const obj = {};
382
- if (message.server?.length) {
383
- obj.server = message.server.map((e) => server_spec_1.ServerEndpoint.toJSON(e));
382
+ if (message.server !== undefined) {
383
+ obj.server = server_spec_1.ServerEndpoint.toJSON(message.server);
384
384
  }
385
385
  return obj;
386
386
  },
@@ -389,7 +389,9 @@ exports.ClientConfig = {
389
389
  },
390
390
  fromPartial(object) {
391
391
  const message = createBaseClientConfig();
392
- message.server = object.server?.map((e) => server_spec_1.ServerEndpoint.fromPartial(e)) || [];
392
+ message.server = (object.server !== undefined && object.server !== null)
393
+ ? server_spec_1.ServerEndpoint.fromPartial(object.server)
394
+ : undefined;
393
395
  return message;
394
396
  },
395
397
  };
@@ -17,7 +17,7 @@ export interface Fallback {
17
17
  }
18
18
  export interface ClientConfig {
19
19
  $type: "xray.proxy.trojan.ClientConfig";
20
- server: ServerEndpoint[];
20
+ server: ServerEndpoint | undefined;
21
21
  }
22
22
  export interface ServerConfig {
23
23
  $type: "xray.proxy.trojan.ServerConfig";
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/proxy/trojan/config.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,EAAE,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAGlD,eAAO,MAAM,eAAe,sBAAsB,CAAC;AAEnD,MAAM,WAAW,OAAO;IACtB,KAAK,EAAE,2BAA2B,CAAC;IACnC,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,QAAQ;IACvB,KAAK,EAAE,4BAA4B,CAAC;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,gCAAgC,CAAC;IACxC,MAAM,EAAE,cAAc,EAAE,CAAC;CAC1B;AAED,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,gCAAgC,CAAC;IACxC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AC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -197,13 +197,13 @@ exports.Fallback = {
197
197
  };
198
198
  typeRegistry_1.messageTypeRegistry.set(exports.Fallback.$type, exports.Fallback);
199
199
  function createBaseClientConfig() {
200
- return { $type: "xray.proxy.trojan.ClientConfig", server: [] };
200
+ return { $type: "xray.proxy.trojan.ClientConfig", server: undefined };
201
201
  }
202
202
  exports.ClientConfig = {
203
203
  $type: "xray.proxy.trojan.ClientConfig",
204
204
  encode(message, writer = new wire_1.BinaryWriter()) {
205
- for (const v of message.server) {
206
- server_spec_1.ServerEndpoint.encode(v, writer.uint32(10).fork()).join();
205
+ if (message.server !== undefined) {
206
+ server_spec_1.ServerEndpoint.encode(message.server, writer.uint32(10).fork()).join();
207
207
  }
208
208
  return writer;
209
209
  },
@@ -218,7 +218,7 @@ exports.ClientConfig = {
218
218
  if (tag !== 10) {
219
219
  break;
220
220
  }
221
- message.server.push(server_spec_1.ServerEndpoint.decode(reader, reader.uint32()));
221
+ message.server = server_spec_1.ServerEndpoint.decode(reader, reader.uint32());
222
222
  continue;
223
223
  }
224
224
  }
@@ -232,13 +232,13 @@ exports.ClientConfig = {
232
232
  fromJSON(object) {
233
233
  return {
234
234
  $type: exports.ClientConfig.$type,
235
- server: globalThis.Array.isArray(object?.server) ? object.server.map((e) => server_spec_1.ServerEndpoint.fromJSON(e)) : [],
235
+ server: isSet(object.server) ? server_spec_1.ServerEndpoint.fromJSON(object.server) : undefined,
236
236
  };
237
237
  },
238
238
  toJSON(message) {
239
239
  const obj = {};
240
- if (message.server?.length) {
241
- obj.server = message.server.map((e) => server_spec_1.ServerEndpoint.toJSON(e));
240
+ if (message.server !== undefined) {
241
+ obj.server = server_spec_1.ServerEndpoint.toJSON(message.server);
242
242
  }
243
243
  return obj;
244
244
  },
@@ -247,7 +247,9 @@ exports.ClientConfig = {
247
247
  },
248
248
  fromPartial(object) {
249
249
  const message = createBaseClientConfig();
250
- message.server = object.server?.map((e) => server_spec_1.ServerEndpoint.fromPartial(e)) || [];
250
+ message.server = (object.server !== undefined && object.server !== null)
251
+ ? server_spec_1.ServerEndpoint.fromPartial(object.server)
252
+ : undefined;
251
253
  return message;
252
254
  },
253
255
  };
@@ -1,5 +1,9 @@
1
1
  import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
2
2
  export declare const protobufPackage = "xray.proxy.vless";
3
+ export interface Reverse {
4
+ $type: "xray.proxy.vless.Reverse";
5
+ tag: string;
6
+ }
3
7
  export interface Account {
4
8
  $type: "xray.proxy.vless.Account";
5
9
  /** ID of the account, in the form of a UUID, e.g., "66ad4540-b58c-4ad2-9926-ea63445a9b57". */
@@ -10,7 +14,9 @@ export interface Account {
10
14
  xorMode: number;
11
15
  seconds: number;
12
16
  padding: string;
17
+ reverse: Reverse | undefined;
13
18
  }
19
+ export declare const Reverse: MessageFns<Reverse, "xray.proxy.vless.Reverse">;
14
20
  export declare const Account: MessageFns<Account, "xray.proxy.vless.Account">;
15
21
  type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
16
22
  export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
@@ -1 +1 @@
1
- {"version":3,"file":"account.d.ts","sourceRoot":"","sources":["../../../../../src/xray-protos/proxy/vless/account.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAGrE,eAAO,MAAM,eAAe,qBAAqB,CAAC;AAElD,MAAM,WAAW,OAAO;IACtB,KAAK,EAAE,0BAA0B,CAAC;IAClC,8FAA8F;IAC9F,EAAE,EAAE,MAAM,CAAC;IACX,gDAAgD;IAChD,IAA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CAAC,GAAG,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,GAChE,CAAC,SAAS,EAAE,GAAG;KAAG,CAAC,IAAI,OAAO,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CAAE,GACvE,OAAO,CAAC,CAAC,CAAC,CAAC;AAMf,MAAM,WAAW,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM;IAC7C,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAClB,MAAM,CAAC,OAAO,EAAE,CAAC,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,YAAY,CAAC;IACxD,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC;IAC7D,QAAQ,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -5,13 +5,75 @@
5
5
  // protoc v5.29.3
6
6
  // source: proxy/vless/account.proto
7
7
  Object.defineProperty(exports, "__esModule", { value: true });
8
- exports.Account = exports.protobufPackage = void 0;
8
+ exports.Account = exports.Reverse = exports.protobufPackage = void 0;
9
9
  /* eslint-disable */
10
10
  const wire_1 = require("@bufbuild/protobuf/wire");
11
11
  const typeRegistry_1 = require("../../typeRegistry");
12
12
  exports.protobufPackage = "xray.proxy.vless";
13
+ function createBaseReverse() {
14
+ return { $type: "xray.proxy.vless.Reverse", tag: "" };
15
+ }
16
+ exports.Reverse = {
17
+ $type: "xray.proxy.vless.Reverse",
18
+ encode(message, writer = new wire_1.BinaryWriter()) {
19
+ if (message.tag !== "") {
20
+ writer.uint32(10).string(message.tag);
21
+ }
22
+ return writer;
23
+ },
24
+ decode(input, length) {
25
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
26
+ let end = length === undefined ? reader.len : reader.pos + length;
27
+ const message = createBaseReverse();
28
+ while (reader.pos < end) {
29
+ const tag = reader.uint32();
30
+ switch (tag >>> 3) {
31
+ case 1: {
32
+ if (tag !== 10) {
33
+ break;
34
+ }
35
+ message.tag = reader.string();
36
+ continue;
37
+ }
38
+ }
39
+ if ((tag & 7) === 4 || tag === 0) {
40
+ break;
41
+ }
42
+ reader.skip(tag & 7);
43
+ }
44
+ return message;
45
+ },
46
+ fromJSON(object) {
47
+ return { $type: exports.Reverse.$type, tag: isSet(object.tag) ? globalThis.String(object.tag) : "" };
48
+ },
49
+ toJSON(message) {
50
+ const obj = {};
51
+ if (message.tag !== "") {
52
+ obj.tag = message.tag;
53
+ }
54
+ return obj;
55
+ },
56
+ create(base) {
57
+ return exports.Reverse.fromPartial(base ?? {});
58
+ },
59
+ fromPartial(object) {
60
+ const message = createBaseReverse();
61
+ message.tag = object.tag ?? "";
62
+ return message;
63
+ },
64
+ };
65
+ typeRegistry_1.messageTypeRegistry.set(exports.Reverse.$type, exports.Reverse);
13
66
  function createBaseAccount() {
14
- return { $type: "xray.proxy.vless.Account", id: "", flow: "", encryption: "", xorMode: 0, seconds: 0, padding: "" };
67
+ return {
68
+ $type: "xray.proxy.vless.Account",
69
+ id: "",
70
+ flow: "",
71
+ encryption: "",
72
+ xorMode: 0,
73
+ seconds: 0,
74
+ padding: "",
75
+ reverse: undefined,
76
+ };
15
77
  }
16
78
  exports.Account = {
17
79
  $type: "xray.proxy.vless.Account",
@@ -34,6 +96,9 @@ exports.Account = {
34
96
  if (message.padding !== "") {
35
97
  writer.uint32(50).string(message.padding);
36
98
  }
99
+ if (message.reverse !== undefined) {
100
+ exports.Reverse.encode(message.reverse, writer.uint32(58).fork()).join();
101
+ }
37
102
  return writer;
38
103
  },
39
104
  decode(input, length) {
@@ -85,6 +150,13 @@ exports.Account = {
85
150
  message.padding = reader.string();
86
151
  continue;
87
152
  }
153
+ case 7: {
154
+ if (tag !== 58) {
155
+ break;
156
+ }
157
+ message.reverse = exports.Reverse.decode(reader, reader.uint32());
158
+ continue;
159
+ }
88
160
  }
89
161
  if ((tag & 7) === 4 || tag === 0) {
90
162
  break;
@@ -102,6 +174,7 @@ exports.Account = {
102
174
  xorMode: isSet(object.xorMode) ? globalThis.Number(object.xorMode) : 0,
103
175
  seconds: isSet(object.seconds) ? globalThis.Number(object.seconds) : 0,
104
176
  padding: isSet(object.padding) ? globalThis.String(object.padding) : "",
177
+ reverse: isSet(object.reverse) ? exports.Reverse.fromJSON(object.reverse) : undefined,
105
178
  };
106
179
  },
107
180
  toJSON(message) {
@@ -124,6 +197,9 @@ exports.Account = {
124
197
  if (message.padding !== "") {
125
198
  obj.padding = message.padding;
126
199
  }
200
+ if (message.reverse !== undefined) {
201
+ obj.reverse = exports.Reverse.toJSON(message.reverse);
202
+ }
127
203
  return obj;
128
204
  },
129
205
  create(base) {
@@ -137,6 +213,9 @@ exports.Account = {
137
213
  message.xorMode = object.xorMode ?? 0;
138
214
  message.seconds = object.seconds ?? 0;
139
215
  message.padding = object.padding ?? "";
216
+ message.reverse = (object.reverse !== undefined && object.reverse !== null)
217
+ ? exports.Reverse.fromPartial(object.reverse)
218
+ : undefined;
140
219
  return message;
141
220
  },
142
221
  };
@@ -3,7 +3,7 @@ import { ServerEndpoint } from "../../../common/protocol/server_spec";
3
3
  export declare const protobufPackage = "xray.proxy.vless.outbound";
4
4
  export interface Config {
5
5
  $type: "xray.proxy.vless.outbound.Config";
6
- vnext: ServerEndpoint[];
6
+ vnext: ServerEndpoint | undefined;
7
7
  }
8
8
  export declare const Config: MessageFns<Config, "xray.proxy.vless.outbound.Config">;
9
9
  type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
@@ -1 +1 @@
1
- {"version":3,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E,OAAO,CAAC,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CAAE,GACvE,OAAO,CAAC,CAAC,CAAC,CAAC;AAMf,MAAM,WAAW,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM;IAC7C,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAClB,MAAM,CAAC,OAAO,EAAE,CAAC,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,YAAY,CAAC;IACxD,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC;IAC7D,QAAQ,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -12,13 +12,13 @@ const server_spec_1 = require("../../../common/protocol/server_spec");
12
12
  const typeRegistry_1 = require("../../../typeRegistry");
13
13
  exports.protobufPackage = "xray.proxy.vless.outbound";
14
14
  function createBaseConfig() {
15
- return { $type: "xray.proxy.vless.outbound.Config", vnext: [] };
15
+ return { $type: "xray.proxy.vless.outbound.Config", vnext: undefined };
16
16
  }
17
17
  exports.Config = {
18
18
  $type: "xray.proxy.vless.outbound.Config",
19
19
  encode(message, writer = new wire_1.BinaryWriter()) {
20
- for (const v of message.vnext) {
21
- server_spec_1.ServerEndpoint.encode(v, writer.uint32(10).fork()).join();
20
+ if (message.vnext !== undefined) {
21
+ server_spec_1.ServerEndpoint.encode(message.vnext, writer.uint32(10).fork()).join();
22
22
  }
23
23
  return writer;
24
24
  },
@@ -33,7 +33,7 @@ exports.Config = {
33
33
  if (tag !== 10) {
34
34
  break;
35
35
  }
36
- message.vnext.push(server_spec_1.ServerEndpoint.decode(reader, reader.uint32()));
36
+ message.vnext = server_spec_1.ServerEndpoint.decode(reader, reader.uint32());
37
37
  continue;
38
38
  }
39
39
  }
@@ -45,15 +45,12 @@ exports.Config = {
45
45
  return message;
46
46
  },
47
47
  fromJSON(object) {
48
- return {
49
- $type: exports.Config.$type,
50
- vnext: globalThis.Array.isArray(object?.vnext) ? object.vnext.map((e) => server_spec_1.ServerEndpoint.fromJSON(e)) : [],
51
- };
48
+ return { $type: exports.Config.$type, vnext: isSet(object.vnext) ? server_spec_1.ServerEndpoint.fromJSON(object.vnext) : undefined };
52
49
  },
53
50
  toJSON(message) {
54
51
  const obj = {};
55
- if (message.vnext?.length) {
56
- obj.vnext = message.vnext.map((e) => server_spec_1.ServerEndpoint.toJSON(e));
52
+ if (message.vnext !== undefined) {
53
+ obj.vnext = server_spec_1.ServerEndpoint.toJSON(message.vnext);
57
54
  }
58
55
  return obj;
59
56
  },
@@ -62,8 +59,13 @@ exports.Config = {
62
59
  },
63
60
  fromPartial(object) {
64
61
  const message = createBaseConfig();
65
- message.vnext = object.vnext?.map((e) => server_spec_1.ServerEndpoint.fromPartial(e)) || [];
62
+ message.vnext = (object.vnext !== undefined && object.vnext !== null)
63
+ ? server_spec_1.ServerEndpoint.fromPartial(object.vnext)
64
+ : undefined;
66
65
  return message;
67
66
  },
68
67
  };
69
68
  typeRegistry_1.messageTypeRegistry.set(exports.Config.$type, exports.Config);
69
+ function isSet(value) {
70
+ return value !== null && value !== undefined;
71
+ }
@@ -13,8 +13,6 @@ export interface Config {
13
13
  $type: "xray.proxy.vmess.inbound.Config";
14
14
  user: User[];
15
15
  default: DefaultConfig | undefined;
16
- /** 4 is for legacy setting */
17
- detour: DetourConfig | undefined;
18
16
  }
19
17
  export declare const DetourConfig: MessageFns<DetourConfig, "xray.proxy.vmess.inbound.DetourConfig">;
20
18
  export declare const DefaultConfig: MessageFns<DefaultConfig, "xray.proxy.vmess.inbound.DefaultConfig">;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AAC;IAC7D,QAAQ,CAAC,MAAM,EAAE,GAAG,GAAG,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -118,7 +118,7 @@ exports.DefaultConfig = {
118
118
  };
119
119
  typeRegistry_1.messageTypeRegistry.set(exports.DefaultConfig.$type, exports.DefaultConfig);
120
120
  function createBaseConfig() {
121
- return { $type: "xray.proxy.vmess.inbound.Config", user: [], default: undefined, detour: undefined };
121
+ return { $type: "xray.proxy.vmess.inbound.Config", user: [], default: undefined };
122
122
  }
123
123
  exports.Config = {
124
124
  $type: "xray.proxy.vmess.inbound.Config",
@@ -129,9 +129,6 @@ exports.Config = {
129
129
  if (message.default !== undefined) {
130
130
  exports.DefaultConfig.encode(message.default, writer.uint32(18).fork()).join();
131
131
  }
132
- if (message.detour !== undefined) {
133
- exports.DetourConfig.encode(message.detour, writer.uint32(26).fork()).join();
134
- }
135
132
  return writer;
136
133
  },
137
134
  decode(input, length) {
@@ -155,13 +152,6 @@ exports.Config = {
155
152
  message.default = exports.DefaultConfig.decode(reader, reader.uint32());
156
153
  continue;
157
154
  }
158
- case 3: {
159
- if (tag !== 26) {
160
- break;
161
- }
162
- message.detour = exports.DetourConfig.decode(reader, reader.uint32());
163
- continue;
164
- }
165
155
  }
166
156
  if ((tag & 7) === 4 || tag === 0) {
167
157
  break;
@@ -175,7 +165,6 @@ exports.Config = {
175
165
  $type: exports.Config.$type,
176
166
  user: globalThis.Array.isArray(object?.user) ? object.user.map((e) => user_1.User.fromJSON(e)) : [],
177
167
  default: isSet(object.default) ? exports.DefaultConfig.fromJSON(object.default) : undefined,
178
- detour: isSet(object.detour) ? exports.DetourConfig.fromJSON(object.detour) : undefined,
179
168
  };
180
169
  },
181
170
  toJSON(message) {
@@ -186,9 +175,6 @@ exports.Config = {
186
175
  if (message.default !== undefined) {
187
176
  obj.default = exports.DefaultConfig.toJSON(message.default);
188
177
  }
189
- if (message.detour !== undefined) {
190
- obj.detour = exports.DetourConfig.toJSON(message.detour);
191
- }
192
178
  return obj;
193
179
  },
194
180
  create(base) {
@@ -200,9 +186,6 @@ exports.Config = {
200
186
  message.default = (object.default !== undefined && object.default !== null)
201
187
  ? exports.DefaultConfig.fromPartial(object.default)
202
188
  : undefined;
203
- message.detour = (object.detour !== undefined && object.detour !== null)
204
- ? exports.DetourConfig.fromPartial(object.detour)
205
- : undefined;
206
189
  return message;
207
190
  },
208
191
  };
@@ -3,7 +3,7 @@ import { ServerEndpoint } from "../../../common/protocol/server_spec";
3
3
  export declare const protobufPackage = "xray.proxy.vmess.outbound";
4
4
  export interface Config {
5
5
  $type: "xray.proxy.vmess.outbound.Config";
6
- Receiver: ServerEndpoint[];
6
+ Receiver: ServerEndpoint | undefined;
7
7
  }
8
8
  export declare const Config: MessageFns<Config, "xray.proxy.vmess.outbound.Config">;
9
9
  type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../../src/xray-protos/proxy/vmess/outbound/config.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,MAAM,sCAAsC,CAAC;AAGtE,eAAO,MAAM,eAAe,8BAA8B,CAAC;AAE3D,MAAM,WAAW,MAAM;IACrB,KAAK,EAAE,kCAAkC,CAAC;IAC1C,QAAQ,EAAE,cAAc,EAAE,CAAC;CAC5B;AAMD,eAAO,MAAM,MAAM,EAAE,UAAU,CAAC,MAAM,EAAE,kCAAkC,CA2DzE,CAAC;AAIF,KAAK,OAAO,GAAG,IAAI,GAAG,QAAQ,GAAG,UAAU,GAAG,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,CAAC,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;IAC5B,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACjC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;CACxC"}
@@ -12,13 +12,13 @@ const server_spec_1 = require("../../../common/protocol/server_spec");
12
12
  const typeRegistry_1 = require("../../../typeRegistry");
13
13
  exports.protobufPackage = "xray.proxy.vmess.outbound";
14
14
  function createBaseConfig() {
15
- return { $type: "xray.proxy.vmess.outbound.Config", Receiver: [] };
15
+ return { $type: "xray.proxy.vmess.outbound.Config", Receiver: undefined };
16
16
  }
17
17
  exports.Config = {
18
18
  $type: "xray.proxy.vmess.outbound.Config",
19
19
  encode(message, writer = new wire_1.BinaryWriter()) {
20
- for (const v of message.Receiver) {
21
- server_spec_1.ServerEndpoint.encode(v, writer.uint32(10).fork()).join();
20
+ if (message.Receiver !== undefined) {
21
+ server_spec_1.ServerEndpoint.encode(message.Receiver, writer.uint32(10).fork()).join();
22
22
  }
23
23
  return writer;
24
24
  },
@@ -33,7 +33,7 @@ exports.Config = {
33
33
  if (tag !== 10) {
34
34
  break;
35
35
  }
36
- message.Receiver.push(server_spec_1.ServerEndpoint.decode(reader, reader.uint32()));
36
+ message.Receiver = server_spec_1.ServerEndpoint.decode(reader, reader.uint32());
37
37
  continue;
38
38
  }
39
39
  }
@@ -47,15 +47,13 @@ exports.Config = {
47
47
  fromJSON(object) {
48
48
  return {
49
49
  $type: exports.Config.$type,
50
- Receiver: globalThis.Array.isArray(object?.Receiver)
51
- ? object.Receiver.map((e) => server_spec_1.ServerEndpoint.fromJSON(e))
52
- : [],
50
+ Receiver: isSet(object.Receiver) ? server_spec_1.ServerEndpoint.fromJSON(object.Receiver) : undefined,
53
51
  };
54
52
  },
55
53
  toJSON(message) {
56
54
  const obj = {};
57
- if (message.Receiver?.length) {
58
- obj.Receiver = message.Receiver.map((e) => server_spec_1.ServerEndpoint.toJSON(e));
55
+ if (message.Receiver !== undefined) {
56
+ obj.Receiver = server_spec_1.ServerEndpoint.toJSON(message.Receiver);
59
57
  }
60
58
  return obj;
61
59
  },
@@ -64,8 +62,13 @@ exports.Config = {
64
62
  },
65
63
  fromPartial(object) {
66
64
  const message = createBaseConfig();
67
- message.Receiver = object.Receiver?.map((e) => server_spec_1.ServerEndpoint.fromPartial(e)) || [];
65
+ message.Receiver = (object.Receiver !== undefined && object.Receiver !== null)
66
+ ? server_spec_1.ServerEndpoint.fromPartial(object.Receiver)
67
+ : undefined;
68
68
  return message;
69
69
  },
70
70
  };
71
71
  typeRegistry_1.messageTypeRegistry.set(exports.Config.$type, exports.Config);
72
+ function isSet(value) {
73
+ return value !== null && value !== undefined;
74
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remnawave/xtls-sdk",
3
- "version": "0.6.2",
3
+ "version": "0.7.0",
4
4
  "description": "A Typescript SDK for XRAY (XTLS) Core GRPC Api",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",