dsh-mobile 0.5.2 → 0.5.4

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/lib/index.d.mts CHANGED
@@ -28,9 +28,9 @@ interface DeviceStore {
28
28
  save(snapshot: DeviceSnapshot): Promise<void>;
29
29
  }
30
30
  /** Validate durable data before it can authorize a device. */
31
- declare function parseDeviceSnapshot(value: unknown, maximumDevices?: number): DeviceSnapshot;
31
+ export declare function parseDeviceSnapshot(value: unknown, maximumDevices?: number): DeviceSnapshot;
32
32
  /** Atomic JSON implementation with symlink refusal and owner-only file creation. */
33
- declare class JsonDeviceStore implements DeviceStore {
33
+ export declare class JsonDeviceStore implements DeviceStore {
34
34
  private readonly file;
35
35
  private readonly maximumDevices;
36
36
  constructor(file: string, maximumDevices?: number);
@@ -38,7 +38,7 @@ declare class JsonDeviceStore implements DeviceStore {
38
38
  save(snapshot: DeviceSnapshot): Promise<void>;
39
39
  }
40
40
  /** In-memory store useful for embedding and deterministic tests. */
41
- declare class MemoryDeviceStore implements DeviceStore {
41
+ export declare class MemoryDeviceStore implements DeviceStore {
42
42
  private snapshot;
43
43
  constructor(initial?: DeviceSnapshot);
44
44
  load(): Promise<DeviceSnapshot>;
@@ -49,7 +49,7 @@ declare class MemoryDeviceStore implements DeviceStore {
49
49
  //#endregion
50
50
  //#region src/access.d.ts
51
51
  /** Stable error categories converted to deliberately terse HTTP responses. */
52
- declare class AccessError extends Error {
52
+ export declare class AccessError extends Error {
53
53
  readonly status: number;
54
54
  readonly code: string;
55
55
  constructor(status: number, code: string);
@@ -105,7 +105,7 @@ interface DeviceSummary {
105
105
  readonly revokedAt?: number;
106
106
  }
107
107
  /** Fixed-window limiter whose attacker-controlled key table is itself bounded. */
108
- declare class BoundedRateLimiter {
108
+ export declare class BoundedRateLimiter {
109
109
  private readonly limit;
110
110
  private readonly windowMs;
111
111
  private readonly maximumKeys;
@@ -117,7 +117,7 @@ declare class BoundedRateLimiter {
117
117
  get size(): number;
118
118
  }
119
119
  /** Pairing, persistent-device, short-Session, revocation, and CSRF state machine. */
120
- declare class AccessController {
120
+ export declare class AccessController {
121
121
  private readonly store;
122
122
  private readonly options;
123
123
  private readonly now;
@@ -151,6 +151,9 @@ declare class AccessController {
151
151
  renew(deviceToken: string): Promise<RenewalResult>;
152
152
  /** Validate a persistent device credential without consuming a Session slot. */
153
153
  probe(deviceToken: string): Promise<DeviceProbeResult>;
154
+ /** Validate a device credential without writing state or opening a Session. */
155
+ authorizeDevice(deviceToken: string): DeviceProbeResult;
156
+ private requireDevice;
154
157
  /** Resolve a short Session Cookie without revealing whether device or Session failed. */
155
158
  authorizeSession(sessionToken: string): SessionAuthorization;
156
159
  /** Require the Session-bound anti-CSRF value for an authenticated mutation. */
@@ -194,23 +197,23 @@ interface AuthoritySpec {
194
197
  readonly port?: number;
195
198
  }
196
199
  /** Parse and canonicalize one IPv4 or IPv6 CIDR. */
197
- declare function parseCidr(source: string): ParsedCidr;
200
+ export declare function parseCidr(source: string): ParsedCidr;
198
201
  /** Whether a directly connected socket address belongs to at least one allowed CIDR. */
199
- declare function addressAllowed(address: string | undefined, cidrs: readonly ParsedCidr[]): boolean;
202
+ export declare function addressAllowed(address: string | undefined, cidrs: readonly ParsedCidr[]): boolean;
200
203
  /** Whether an IP literal is loopback and therefore eligible for HTTP-only development. */
201
- declare function isLoopbackAddress(address: string): boolean;
204
+ export declare function isLoopbackAddress(address: string): boolean;
202
205
  /**
203
206
  * Whether a dotted-quad IPv4 literal is globally routable and therefore usable
204
207
  * as a public VPS / remote HTTPS endpoint. Rejects documentation addresses such
205
208
  * as 203.0.113.10 alongside private, shared, and reserved space.
206
209
  */
207
- declare function isGloballyRoutableIpv4(address: string): boolean;
210
+ export declare function isGloballyRoutableIpv4(address: string): boolean;
208
211
  /** Parse a bare host or host:port authority without accepting URL components. */
209
- declare function parseAuthority(source: string): AuthoritySpec;
212
+ export declare function parseAuthority(source: string): AuthoritySpec;
210
213
  /** Resolve an authority against the actual listener port. */
211
- declare function resolveAuthority(spec: AuthoritySpec, listenerPort: number): string;
214
+ export declare function resolveAuthority(spec: AuthoritySpec, listenerPort: number): string;
212
215
  /** Exact Host/Origin/CIDR policy for the directly exposed listener. */
213
- declare class RequestTrustPolicy {
216
+ export declare class RequestTrustPolicy {
214
217
  readonly cidrs: readonly ParsedCidr[];
215
218
  readonly authorities: ReadonlySet<string>;
216
219
  readonly origins: ReadonlySet<string>;
@@ -227,6 +230,24 @@ declare class RequestTrustPolicy {
227
230
  }
228
231
  //#endregion
229
232
  //#region src/config.d.ts
233
+ /** Optional compression for exact, already authorized WebSocket paths. */
234
+ interface WebSocketCompressionConfig {
235
+ paths?: string[];
236
+ maxMessageBytes?: number;
237
+ maxQueuedBytes?: number;
238
+ thresholdBytes?: number;
239
+ concurrencyLimit?: number;
240
+ level?: number;
241
+ }
242
+ /** Validated compression settings; an empty path list keeps the raw transport. */
243
+ interface ResolvedWebSocketCompressionConfig {
244
+ readonly paths: readonly string[];
245
+ readonly maxMessageBytes: number;
246
+ readonly maxQueuedBytes: number;
247
+ readonly thresholdBytes: number;
248
+ readonly concurrencyLimit: number;
249
+ readonly level: number;
250
+ }
230
251
  /** TLS source accepted by the LAN listener. */
231
252
  interface ProvidedTlsConfig {
232
253
  readonly mode: 'provided';
@@ -265,6 +286,8 @@ interface PluginConfig {
265
286
  mobileCompatibilityFile?: string;
266
287
  /** Optional application-phase client package ids omitted only from the mobile boot graph. */
267
288
  excludedClientModules?: string[];
289
+ /** Compression is opt-in; it does not authorize additional WebSocket paths. */
290
+ websocketCompression?: WebSocketCompressionConfig;
268
291
  /** Stable public discovery identifier; it is not an authentication secret. */
269
292
  instanceId?: string;
270
293
  /** Managed CA certificate offered to the Android installer after fingerprint binding. */
@@ -306,6 +329,7 @@ interface ResolvedGatewayConfig {
306
329
  readonly mobileLayoutFile: string;
307
330
  readonly mobileCompatibilityFile: string;
308
331
  readonly excludedClientModules: readonly string[];
332
+ readonly websocketCompression: ResolvedWebSocketCompressionConfig;
309
333
  readonly instanceId: string;
310
334
  readonly pairingCaFile?: string;
311
335
  readonly tls: TlsConfig;
@@ -328,11 +352,11 @@ interface ResolvedGatewayConfig {
328
352
  readonly maxRateLimitKeys: number;
329
353
  }
330
354
  /** Loader-facing defaults; {@link parseGatewayConfig} enforces cross-field security rules. */
331
- declare const Config: z<PluginConfig>;
355
+ export declare const Config: z<PluginConfig>;
332
356
  /** Resolve the hidden runtime-control file independently from gateway configuration. */
333
- declare function parseControlFile(value: unknown): string;
357
+ export declare function parseControlFile(value: unknown): string;
334
358
  /** Parse configuration and reject unsafe topology, credential, and resource combinations. */
335
- declare function parseGatewayConfig(raw: unknown): ResolvedGatewayConfig;
359
+ export declare function parseGatewayConfig(raw: unknown): ResolvedGatewayConfig;
336
360
  //#endregion
337
361
  //#region src/control.d.ts
338
362
  /** Versioned durable preference for the resident mobile-access runtime. */
@@ -350,9 +374,9 @@ interface MobileAccessRuntime {
350
374
  close(): Promise<void>;
351
375
  }
352
376
  /** Validate control state loaded across the filesystem boundary. */
353
- declare function parseMobileAccessControlState(value: unknown): MobileAccessControlState;
377
+ export declare function parseMobileAccessControlState(value: unknown): MobileAccessControlState;
354
378
  /** Atomic JSON store whose absent-file state comes from the installation-time default. */
355
- declare class JsonMobileAccessControlStore implements MobileAccessControlStore {
379
+ export declare class JsonMobileAccessControlStore implements MobileAccessControlStore {
356
380
  private readonly file;
357
381
  private readonly initiallyEnabled;
358
382
  constructor(file: string, initiallyEnabled: boolean);
@@ -362,7 +386,7 @@ declare class JsonMobileAccessControlStore implements MobileAccessControlStore {
362
386
  save(state: MobileAccessControlState): Promise<void>;
363
387
  }
364
388
  /** Serialized persistent lifecycle for the gateway behind the always-loaded Cordis entry. */
365
- declare class MobileAccessGatewayController {
389
+ export declare class MobileAccessGatewayController {
366
390
  private readonly store;
367
391
  private readonly startRuntime;
368
392
  private runtime;
@@ -386,18 +410,18 @@ declare class MobileAccessGatewayController {
386
410
  //#endregion
387
411
  //#region src/websocket-paths.d.ts
388
412
  /** Cap the admin-approved extra WebSocket upgrade paths (exact pathnames). */
389
- declare const MAX_EXTRA_WEBSOCKET_PATHS = 16;
390
- declare const MAX_WEBSOCKET_PATH_LENGTH = 256;
413
+ export declare const MAX_EXTRA_WEBSOCKET_PATHS = 16;
414
+ export declare const MAX_WEBSOCKET_PATH_LENGTH = 256;
391
415
  /**
392
416
  * Validate one exact pathname for proxying. Query strings are matched at
393
417
  * upgrade time, so only the pathname is stored. Rejects anything the
394
418
  * gateway cannot match exactly.
395
419
  */
396
- declare function validateWebSocketPath(value: unknown): string;
420
+ export declare function validateWebSocketPath(value: unknown): string;
397
421
  /** Validate a whole replacement list all-or-nothing; duplicates collapse. */
398
- declare function normalizeWebSocketPaths(value: unknown): string[];
422
+ export declare function normalizeWebSocketPaths(value: unknown): string[];
399
423
  /** Cap remembered rejected upgrade paths offered for one-click approval. */
400
- declare const MAX_BLOCKED_UPGRADE_PATHS = 32;
424
+ export declare const MAX_BLOCKED_UPGRADE_PATHS = 32;
401
425
  interface BlockedUpgradePathEntry {
402
426
  readonly path: string;
403
427
  readonly attempts: number;
@@ -410,13 +434,13 @@ interface BlockedUpgradePathEntry {
410
434
  * Bounded and newest-first; a restart clears it (attempts reappear on
411
435
  * the next blocked handshake).
412
436
  */
413
- declare class BlockedUpgradePathLog {
437
+ export declare class BlockedUpgradePathLog {
414
438
  private readonly entries;
415
439
  record(pathname: string): void;
416
440
  report(): BlockedUpgradePathEntry[];
417
441
  }
418
442
  /** File-backed store shared by every gateway instance (LAN and remote). */
419
- declare class WebSocketPathStore {
443
+ export declare class WebSocketPathStore {
420
444
  private readonly file;
421
445
  private paths;
422
446
  private loaded;
@@ -431,7 +455,7 @@ declare class WebSocketPathStore {
431
455
  //#endregion
432
456
  //#region src/extensions.d.ts
433
457
  /** Maximum sizes enforced at the local-extension filesystem boundary. */
434
- declare const EXTENSION_LIMITS: Readonly<{
458
+ export declare const EXTENSION_LIMITS: Readonly<{
435
459
  manifest: number;
436
460
  script: number;
437
461
  css: number;
@@ -441,7 +465,7 @@ declare const EXTENSION_LIMITS: Readonly<{
441
465
  assetDepth: 8;
442
466
  }>;
443
467
  /** A controlled business failure returned by an extension action or route. */
444
- declare class MobileExtensionError extends Error {
468
+ export declare class MobileExtensionError extends Error {
445
469
  readonly code: string;
446
470
  readonly status: number;
447
471
  constructor(code: string, message: string, status?: number);
@@ -533,11 +557,11 @@ interface ActiveLocalExtension {
533
557
  readonly digest: string;
534
558
  }
535
559
  /** Validate a stable extension id. */
536
- declare function assertExtensionId(value: unknown): string;
560
+ export declare function assertExtensionId(value: unknown): string;
537
561
  /** Validate a manifest from JSON or a plugin definition. */
538
- declare function parseExtensionManifest(value: unknown): LocalExtensionManifest;
562
+ export declare function parseExtensionManifest(value: unknown): LocalExtensionManifest;
539
563
  /** Host registry and service consumed by both npm plugins and local extensions. */
540
- declare class MobileAccessService extends Service {
564
+ export declare class MobileAccessService extends Service {
541
565
  private readonly registered;
542
566
  private readonly local;
543
567
  private readonly retired;
@@ -592,13 +616,13 @@ declare class MobileAccessService extends Service {
592
616
  private retire;
593
617
  }
594
618
  /** Construct the service in a Cordis plugin without importing DSH internals. */
595
- declare function createMobileAccessService(ctx: Context): MobileAccessService;
619
+ export declare function createMobileAccessService(ctx: Context): MobileAccessService;
596
620
  //#endregion
597
621
  //#region src/gateway.d.ts
598
622
  /** Rewrite the dedicated mobile graph; exclusions are opt-in and leave stock DSH unchanged. */
599
- declare function rewriteMobileIndex(html: string, excludedClientModules?: readonly string[]): string;
623
+ export declare function rewriteMobileIndex(html: string, excludedClientModules?: readonly string[]): string;
600
624
  /** Authenticated TLS edge in front of the ordinary loopback-only DSH Web server. */
601
- declare class MobileAccessGateway {
625
+ export declare class MobileAccessGateway {
602
626
  readonly config: ResolvedGatewayConfig;
603
627
  private readonly extensions?;
604
628
  private readonly upstreamAuthenticatedUrl?;
@@ -690,6 +714,7 @@ declare class MobileAccessGateway {
690
714
  private authorize;
691
715
  private requireCsrf;
692
716
  private setSessionCookies;
717
+ private setBrowserDeviceBinding;
693
718
  private handlePair;
694
719
  private handleRenew;
695
720
  private handleNativePair;
@@ -773,13 +798,13 @@ declare class MobileAccessGateway {
773
798
  }
774
799
  //#endregion
775
800
  //#region src/http-security.d.ts
776
- declare const DEVICE_COOKIE = "dsh_ma_device";
777
- declare const SESSION_COOKIE = "dsh_ma_session";
778
- declare const CSRF_COOKIE = "dsh_ma_csrf";
779
- declare const CSRF_HEADER = "x-dsh-mobile-csrf";
780
- declare const LOCAL_ADMIN_PREFIX = "/api/mobile-access";
781
- declare const AUTH_PREFIX = "/mobile-access";
782
- declare const WS_PATHS: Set<string>;
801
+ export declare const DEVICE_COOKIE = "dsh_ma_device";
802
+ export declare const SESSION_COOKIE = "dsh_ma_session";
803
+ export declare const CSRF_COOKIE = "dsh_ma_csrf";
804
+ export declare const CSRF_HEADER = "x-dsh-mobile-csrf";
805
+ export declare const LOCAL_ADMIN_PREFIX = "/api/mobile-access";
806
+ export declare const AUTH_PREFIX = "/mobile-access";
807
+ export declare const WS_PATHS: Set<string>;
783
808
  //#endregion
784
809
  //#region src/frp-component.d.ts
785
810
  interface FrpArtifact {
@@ -792,7 +817,7 @@ interface FrpArtifact {
792
817
  readonly executableName: string;
793
818
  }
794
819
  /** Pinned official FRP release metadata for supported desktop targets. */
795
- declare const FRP_COMPONENT_RELEASES: Readonly<Record<string, FrpArtifact>>;
820
+ export declare const FRP_COMPONENT_RELEASES: Readonly<Record<string, FrpArtifact>>;
796
821
  /** Public, credential-free description of the managed FRP client. */
797
822
  interface FrpComponentStatus {
798
823
  readonly supported: boolean;
@@ -814,7 +839,7 @@ interface FrpComponentManagerOptions {
814
839
  readonly inspectExecutable?: (executable: string) => Promise<string>;
815
840
  }
816
841
  /** Owns the optional official frpc binary inside the DSH Mobile state directory. */
817
- declare class FrpComponentManager {
842
+ export declare class FrpComponentManager {
818
843
  readonly executable: string;
819
844
  readonly componentRoot: string;
820
845
  readonly componentStorage: string;
@@ -842,13 +867,13 @@ declare class FrpComponentManager {
842
867
  //#endregion
843
868
  //#region src/frp-template.d.ts
844
869
  /** Loopback-only HTTP vhost port used between Caddy and frps. */
845
- declare const FRP_VHOST_HTTP_PORT = 7080;
870
+ export declare const FRP_VHOST_HTTP_PORT = 7080;
846
871
  /** Caddy snippet owned entirely by DSH Mobile; the main Caddyfile only imports it. */
847
- declare const FRP_CADDY_SNIPPET_PATH = "/etc/caddy/dsh-mobile-dsh.caddy";
872
+ export declare const FRP_CADDY_SNIPPET_PATH = "/etc/caddy/dsh-mobile-dsh.caddy";
848
873
  /** First line of the owned snippet; also the legacy whole-file marker. */
849
- declare const FRP_CADDY_SNIPPET_MARKER = "# Managed by DSH Mobile - snippet, safe to delete";
874
+ export declare const FRP_CADDY_SNIPPET_MARKER = "# Managed by DSH Mobile - snippet, safe to delete";
850
875
  /** Exact line the main Caddyfile must contain (uncommented) for the site to load. */
851
- declare const FRP_CADDY_IMPORT_LINE = "import /etc/caddy/dsh-mobile-dsh.caddy";
876
+ export declare const FRP_CADDY_IMPORT_LINE = "import /etc/caddy/dsh-mobile-dsh.caddy";
852
877
  /**
853
878
  * Entry TLS mode for the FRP channel.
854
879
  *
@@ -877,7 +902,7 @@ interface CaddySiteOptions {
877
902
  * signature) or a full {@link CaddySiteOptions} object, so existing callers keep
878
903
  * working unchanged.
879
904
  */
880
- declare function createCaddySite(publicHost: string, options?: CaddySiteOptions | string): string;
905
+ export declare function createCaddySite(publicHost: string, options?: CaddySiteOptions | string): string;
881
906
  /**
882
907
  * Build the only supported frps config and Caddy snippet from validated user inputs.
883
908
  *
@@ -885,15 +910,15 @@ declare function createCaddySite(publicHost: string, options?: CaddySiteOptions
885
910
  * passes the user's real vhost port, and `self-signed` is rejected because that
886
911
  * mode publishes a raw TCP proxy instead of an HTTP vhost.
887
912
  */
888
- declare function createRestrictedFrpServerTemplate(serverPort: number, token: string, publicOrigin: string, options?: CaddySiteOptions): string;
913
+ export declare function createRestrictedFrpServerTemplate(serverPort: number, token: string, publicOrigin: string, options?: CaddySiteOptions): string;
889
914
  //#endregion
890
915
  //#region src/frp-config.d.ts
891
916
  /** How the restricted FRP channel is provisioned on the VPS. */
892
917
  type FrpMode = 'deploy' | 'attach';
893
918
  /** Public entry port used by the self-signed TCP passthrough (never 443 by requirement). */
894
- declare const FRP_DEFAULT_PUBLIC_PORT = 33080;
919
+ export declare const FRP_DEFAULT_PUBLIC_PORT = 33080;
895
920
  /** Ports owned by other DSH Mobile listeners; the public entry may never reuse them. */
896
- declare const FRP_RESERVED_PORTS: readonly number[];
921
+ export declare const FRP_RESERVED_PORTS: readonly number[];
897
922
  /** Credentials and endpoints required by the restricted FRP provider. */
898
923
  interface FrpSettings {
899
924
  readonly version: 1;
@@ -932,31 +957,31 @@ interface FrpConfigurationStatus {
932
957
  readonly publicPort?: number;
933
958
  }
934
959
  /** Validate the FRP server hostname or IP address. */
935
- declare function validateFrpServerAddress(value: unknown): string;
960
+ export declare function validateFrpServerAddress(value: unknown): string;
936
961
  /** Validate the FRP control port. */
937
- declare function validateFrpServerPort(value: unknown): number;
962
+ export declare function validateFrpServerPort(value: unknown): number;
938
963
  /** Validate a high-entropy FRP token before durable storage. */
939
- declare function validateFrpToken(value: unknown): string;
964
+ export declare function validateFrpToken(value: unknown): string;
940
965
  /** Validate the public HTTPS origin used by Caddy and Android pairing. */
941
- declare function validateFrpPublicOrigin(value: unknown): string;
966
+ export declare function validateFrpPublicOrigin(value: unknown): string;
942
967
  /** Validate the provisioning mode. */
943
- declare function validateFrpMode(value: unknown): FrpMode;
968
+ export declare function validateFrpMode(value: unknown): FrpMode;
944
969
  /** Validate the entry TLS mode. */
945
- declare function validateFrpEntryTls(value: unknown): FrpEntryTls;
970
+ export declare function validateFrpEntryTls(value: unknown): FrpEntryTls;
946
971
  /** Validate the loopback vhost port of the target frps. */
947
- declare function validateFrpVhostHttpPort(value: unknown): number;
972
+ export declare function validateFrpVhostHttpPort(value: unknown): number;
948
973
  /** Validate the public entry port of the self-signed TCP proxy. */
949
- declare function validateFrpPublicPort(value: unknown): number;
974
+ export declare function validateFrpPublicPort(value: unknown): number;
950
975
  /** Effective provisioning mode; an absent field keeps the upstream behaviour. */
951
- declare function resolveFrpMode(settings: FrpSettings): FrpMode;
976
+ export declare function resolveFrpMode(settings: FrpSettings): FrpMode;
952
977
  /** Effective entry TLS mode; an absent field keeps the upstream behaviour. */
953
- declare function resolveFrpEntryTls(settings: FrpSettings): FrpEntryTls;
978
+ export declare function resolveFrpEntryTls(settings: FrpSettings): FrpEntryTls;
954
979
  /** Effective loopback vhost port; an absent field keeps the upstream behaviour. */
955
- declare function resolveFrpVhostHttpPort(settings: FrpSettings): number;
980
+ export declare function resolveFrpVhostHttpPort(settings: FrpSettings): number;
956
981
  /** Effective public entry port of the self-signed passthrough. */
957
- declare function resolveFrpPublicPort(settings: FrpSettings): number;
982
+ export declare function resolveFrpPublicPort(settings: FrpSettings): number;
958
983
  /** True when the gateway terminates TLS itself behind a raw frps TCP proxy. */
959
- declare function isFrpSelfSignedIngress(settings: FrpSettings): boolean;
984
+ export declare function isFrpSelfSignedIngress(settings: FrpSettings): boolean;
960
985
  /**
961
986
  * Parse FRP settings at the loopback request and filesystem boundaries.
962
987
  *
@@ -967,16 +992,16 @@ declare function isFrpSelfSignedIngress(settings: FrpSettings): boolean;
967
992
  * attach mode with a public-CA entry must state the user's real vhost port —
968
993
  * silently assuming 7080 would disable the plaintext-exposure gate.
969
994
  */
970
- declare function parseFrpSettings(value: unknown): FrpSettings;
995
+ export declare function parseFrpSettings(value: unknown): FrpSettings;
971
996
  /**
972
997
  * Merge a partial VPS request body with the saved configuration so a blank
973
998
  * field keeps its saved value ("已保存时可留空"). Every merged field is still
974
999
  * validated; with nothing saved and nothing supplied the result reports a
975
1000
  * missing configuration instead of silently deploying blanks.
976
1001
  */
977
- declare function mergeSavedFrpSettings(partial: Readonly<Record<string, unknown>>, saved: FrpSettings | undefined): FrpSettings;
1002
+ export declare function mergeSavedFrpSettings(partial: Readonly<Record<string, unknown>>, saved: FrpSettings | undefined): FrpSettings;
978
1003
  /** Merge a VPS target (address and control port) with the saved configuration. */
979
- declare function mergeSavedFrpTarget(partial: Readonly<Record<string, unknown>>, saved: FrpSettings | undefined): {
1004
+ export declare function mergeSavedFrpTarget(partial: Readonly<Record<string, unknown>>, saved: FrpSettings | undefined): {
980
1005
  readonly serverAddress: string;
981
1006
  readonly serverPort: number;
982
1007
  };
@@ -992,14 +1017,14 @@ declare function mergeSavedFrpTarget(partial: Readonly<Record<string, unknown>>,
992
1017
  * from {@link frpProxyName}; this constant only keeps the exported API and the
993
1018
  * byte-for-byte compatibility test working for legacy callers.
994
1019
  */
995
- declare const FRP_DEFAULT_PROXY_NAME = "dsh-mobile";
1020
+ export declare const FRP_DEFAULT_PROXY_NAME = "dsh-mobile";
996
1021
  /**
997
1022
  * Validate a proxy name for the generated frpc configuration.
998
1023
  *
999
1024
  * frps accepts one proxy per name on the whole server, so the name must be a
1000
1025
  * single safe token: no whitespace, no quotes, no path or bracket characters.
1001
1026
  */
1002
- declare function validateFrpProxyName(value: unknown): string;
1027
+ export declare function validateFrpProxyName(value: unknown): string;
1003
1028
  /**
1004
1029
  * Proxy name for one DSH installation.
1005
1030
  *
@@ -1008,7 +1033,7 @@ declare function validateFrpProxyName(value: unknown): string;
1008
1033
  * same name across restarts (so its own stale registration is the only possible
1009
1034
  * conflict, and that one expires with the frps heartbeat).
1010
1035
  */
1011
- declare function frpProxyName(instanceId: string): string;
1036
+ export declare function frpProxyName(instanceId: string): string;
1012
1037
  /**
1013
1038
  * Build the single-purpose frpc configuration for the current loopback gateway.
1014
1039
  *
@@ -1019,11 +1044,11 @@ declare function frpProxyName(instanceId: string): string;
1019
1044
  * `proxyName` defaults to the legacy fixed name only for legacy callers; the
1020
1045
  * provider and the attach preview always pass {@link frpProxyName}.
1021
1046
  */
1022
- declare function createFrpcToml(settings: FrpSettings, localPort: number, proxyName?: string): string;
1047
+ export declare function createFrpcToml(settings: FrpSettings, localPort: number, proxyName?: string): string;
1023
1048
  /** Build the matching restricted frps and Caddy templates for one VPS. */
1024
- declare function createFrpServerTemplate(settings: FrpSettings): string;
1049
+ export declare function createFrpServerTemplate(settings: FrpSettings): string;
1025
1050
  /** Owns private FRP settings and generation-specific frpc configuration. */
1026
- declare class FrpConfigStore {
1051
+ export declare class FrpConfigStore {
1027
1052
  readonly stateRoot: string;
1028
1053
  readonly settingsFile: string;
1029
1054
  readonly runtimeConfigFile: string;
@@ -1060,13 +1085,13 @@ declare class FrpConfigStore {
1060
1085
  //#endregion
1061
1086
  //#region src/frp-attach.d.ts
1062
1087
  /** Default proof path used to confirm the public entry answered from this computer. */
1063
- declare const FRP_ATTACH_DISCOVERY_PATH = "/mobile-access/discovery";
1088
+ export declare const FRP_ATTACH_DISCOVERY_PATH = "/mobile-access/discovery";
1064
1089
  /** Declaration printed above the VPS half of an attach template. */
1065
- declare const FRP_ATTACH_VPS_DECLARATION: string;
1090
+ export declare const FRP_ATTACH_VPS_DECLARATION: string;
1066
1091
  /** Declaration printed above the local half of an attach template. */
1067
- declare const FRP_ATTACH_LOCAL_DECLARATION = "# 本机只写入 frpc.toml 并启动 frpc:不安装、不改动本机 frps,也不改动 DSH 自身配置。";
1092
+ export declare const FRP_ATTACH_LOCAL_DECLARATION = "# 本机只写入 frpc.toml 并启动 frpc:不安装、不改动本机 frps,也不改动 DSH 自身配置。";
1068
1093
  /** Declaration for the self-signed passthrough, which keeps its CA on this computer. */
1069
- declare const FRP_ATTACH_SELF_SIGNED_DECLARATION: string;
1094
+ export declare const FRP_ATTACH_SELF_SIGNED_DECLARATION: string;
1070
1095
  /** Optional inputs for attach artefacts; every field falls back to the validated settings. */
1071
1096
  interface FrpAttachOptions {
1072
1097
  readonly vhostHttpPort?: number;
@@ -1106,7 +1131,7 @@ interface FrpAttachTemplate {
1106
1131
  * artefact is produced. Attach never installs frps, so it must know the user's
1107
1132
  * real vhost port (unless the self-signed passthrough removes the vhost entirely).
1108
1133
  */
1109
- declare function validateAttachSettings(settings: FrpSettings, options?: FrpAttachOptions): void;
1134
+ export declare function validateAttachSettings(settings: FrpSettings, options?: FrpAttachOptions): void;
1110
1135
  /** Shared VPS-side inputs of both the copied runbook and the panel plan. */
1111
1136
  interface FrpAttachVpsParts {
1112
1137
  readonly publicHost: string;
@@ -1120,7 +1145,7 @@ interface FrpAttachVpsParts {
1120
1145
  * Derive every VPS-side value once so the copied runbook and the panel plan can
1121
1146
  * never drift apart.
1122
1147
  */
1123
- declare function frpAttachVpsParts(settings: FrpSettings, options?: FrpAttachOptions): FrpAttachVpsParts;
1148
+ export declare function frpAttachVpsParts(settings: FrpSettings, options?: FrpAttachOptions): FrpAttachVpsParts;
1124
1149
  /**
1125
1150
  * Build the attach artefact for an existing frps.
1126
1151
  *
@@ -1130,9 +1155,9 @@ declare function frpAttachVpsParts(settings: FrpSettings, options?: FrpAttachOpt
1130
1155
  * contains the generated frpc.toml plus its `frpc verify` self-check. Neither
1131
1156
  * half installs, rewrites, or restarts the user's frps.
1132
1157
  */
1133
- declare function createFrpAttachTemplateParts(settings: FrpSettings, options?: FrpAttachOptions): FrpAttachTemplate;
1158
+ export declare function createFrpAttachTemplateParts(settings: FrpSettings, options?: FrpAttachOptions): FrpAttachTemplate;
1134
1159
  /** Combined attach artefact, ready for the clipboard. */
1135
- declare function createFrpAttachTemplate(settings: FrpSettings, options?: FrpAttachOptions): string;
1160
+ export declare function createFrpAttachTemplate(settings: FrpSettings, options?: FrpAttachOptions): string;
1136
1161
  //#endregion
1137
1162
  //#region src/frp-attach-plan.d.ts
1138
1163
  /** Stable step identifiers; the panel maps each one to a translated title. */
@@ -1171,11 +1196,11 @@ interface FrpAttachPlan {
1171
1196
  * filesystem write: the caller renders or copies the steps and the local frpc
1172
1197
  * configuration is written by the ordinary provider lifecycle.
1173
1198
  */
1174
- declare function createFrpAttachPlan(settings: FrpSettings, options?: FrpAttachOptions): FrpAttachPlan;
1199
+ export declare function createFrpAttachPlan(settings: FrpSettings, options?: FrpAttachOptions): FrpAttachPlan;
1175
1200
  //#endregion
1176
1201
  //#region src/cert-renewal.d.ts
1177
1202
  /** Days left below which the entry certificate is reported as expiring. */
1178
- declare const CERT_EXPIRING_DAYS = 2;
1203
+ export declare const CERT_EXPIRING_DAYS = 2;
1179
1204
  /** Read-only lifetime verdict for one certificate; never mutates or renews anything. */
1180
1205
  interface CertRenewalStatus {
1181
1206
  readonly state: 'ok' | 'expiring' | 'expired' | 'unknown';
@@ -1187,14 +1212,14 @@ interface CertRenewalStatus {
1187
1212
  readonly errorCode?: string;
1188
1213
  }
1189
1214
  /** Evaluate one `notAfter` timestamp against the current clock. */
1190
- declare function evaluateCertificateLifetime(notAfter: number, now?: number): CertRenewalStatus;
1215
+ export declare function evaluateCertificateLifetime(notAfter: number, now?: number): CertRenewalStatus;
1191
1216
  /**
1192
1217
  * Read one PEM certificate from disk and report only its lifetime.
1193
1218
  *
1194
1219
  * A missing or unreadable file yields `unknown` with the stable
1195
1220
  * `frp_attach_cert_unknown` code so the panel can explain how to re-issue it.
1196
1221
  */
1197
- declare function readCertificateRenewal(file: string, now?: number): Promise<CertRenewalStatus>;
1222
+ export declare function readCertificateRenewal(file: string, now?: number): Promise<CertRenewalStatus>;
1198
1223
  /**
1199
1224
  * Ask a live TLS endpoint for its leaf certificate and report its lifetime.
1200
1225
  *
@@ -1202,7 +1227,7 @@ declare function readCertificateRenewal(file: string, now?: number): Promise<Cer
1202
1227
  * an endpoint whose trust anchor is already pinned elsewhere, and a self-signed
1203
1228
  * leaf is the expected answer for the passthrough entry.
1204
1229
  */
1205
- declare function probeOriginCertificate(host: string, port: number, timeoutMs?: number): Promise<CertRenewalStatus>;
1230
+ export declare function probeOriginCertificate(host: string, port: number, timeoutMs?: number): Promise<CertRenewalStatus>;
1206
1231
  //#endregion
1207
1232
  //#region src/frp-ingress.d.ts
1208
1233
  /** Private files owned by the self-signed FRP ingress. */
@@ -1242,7 +1267,7 @@ interface FrpIngressSelfCheck {
1242
1267
  };
1243
1268
  }
1244
1269
  /** Private ingress directory, always a sibling of the remote device file. */
1245
- declare function frpIngressPaths(stateFile: string): FrpIngressPaths;
1270
+ export declare function frpIngressPaths(stateFile: string): FrpIngressPaths;
1246
1271
  /**
1247
1272
  * Materialize the CA and leaf the gateway terminates TLS with.
1248
1273
  *
@@ -1250,14 +1275,14 @@ declare function frpIngressPaths(stateFile: string): FrpIngressPaths;
1250
1275
  * replaced silently. The leaf is re-signed when expiring or no longer valid for
1251
1276
  * the public IPv4, and the running gateway reloads it after a renewal check.
1252
1277
  */
1253
- declare function ensureFrpIngressCertificate(settings: FrpSettings, stateFile: string, now?: number, expectedCaFingerprint?: string): Promise<FrpIngressCertificate>;
1278
+ export declare function ensureFrpIngressCertificate(settings: FrpSettings, stateFile: string, now?: number, expectedCaFingerprint?: string): Promise<FrpIngressCertificate>;
1254
1279
  /**
1255
1280
  * Build the read-only self-check payload shown in the desktop panel.
1256
1281
  *
1257
1282
  * No secret ever leaves this function: the CA is reported by fingerprint only,
1258
1283
  * and the token is never read.
1259
1284
  */
1260
- declare function frpIngressSelfCheck(settings: FrpSettings, stateFile: string): Promise<FrpIngressSelfCheck>;
1285
+ export declare function frpIngressSelfCheck(settings: FrpSettings, stateFile: string): Promise<FrpIngressSelfCheck>;
1261
1286
  //#endregion
1262
1287
  //#region src/managed-setup.d.ts
1263
1288
  /** One host a server leaf must be valid for: an IP literal, a DNS name, or both. */
@@ -1284,7 +1309,7 @@ interface ServerCertificateAuthority {
1284
1309
  * required for console addresses (`type: 7`), DNS entries (`type: 2`) cover named
1285
1310
  * hosts; the Android client accepts either through its pinned CA.
1286
1311
  */
1287
- declare function issueServerCertificate(authority: ServerCertificateAuthority, target: ServerCertificateTarget, output: ServerCertificateFiles, lifetimeDays?: number): Promise<void>;
1312
+ export declare function issueServerCertificate(authority: ServerCertificateAuthority, target: ServerCertificateTarget, output: ServerCertificateFiles, lifetimeDays?: number): Promise<void>;
1288
1313
  //#endregion
1289
1314
  //#region src/remote.d.ts
1290
1315
  /** Remote transports supported by the desktop plugin and Android client. */
@@ -1314,11 +1339,11 @@ interface RemoteProviderState {
1314
1339
  readonly version: 1;
1315
1340
  readonly provider: RemoteProvider;
1316
1341
  }
1317
- declare const REMOTE_PROVIDERS: readonly RemoteProvider[];
1342
+ export declare const REMOTE_PROVIDERS: readonly RemoteProvider[];
1318
1343
  /** Validate the provider selection loaded across the filesystem boundary. */
1319
- declare function parseRemoteProviderState(value: unknown): RemoteProviderState;
1344
+ export declare function parseRemoteProviderState(value: unknown): RemoteProviderState;
1320
1345
  /** Atomic selection store whose absent-file state uses the configured default. */
1321
- declare class JsonRemoteProviderStore {
1346
+ export declare class JsonRemoteProviderStore {
1322
1347
  private readonly file;
1323
1348
  private readonly defaultProvider;
1324
1349
  constructor(file: string, defaultProvider: RemoteProvider);
@@ -1326,7 +1351,7 @@ declare class JsonRemoteProviderStore {
1326
1351
  save(state: RemoteProviderState): Promise<void>;
1327
1352
  }
1328
1353
  /** Resolve the first-run provider without letting environment values bypass validation. */
1329
- declare function configuredRemoteProvider(environment: NodeJS.ProcessEnv): RemoteProvider;
1354
+ export declare function configuredRemoteProvider(environment: NodeJS.ProcessEnv): RemoteProvider;
1330
1355
  //#endregion
1331
1356
  //#region src/frp.d.ts
1332
1357
  /** Product-facing states for the restricted self-hosted FRP transport. */
@@ -1395,7 +1420,7 @@ interface FrpControllerOptions {
1395
1420
  readonly retryIntervalMs?: number;
1396
1421
  }
1397
1422
  /** Owns frpc, its generation-specific configuration, and the remote gateway. */
1398
- declare class FrpController implements RemoteProviderController {
1423
+ export declare class FrpController implements RemoteProviderController {
1399
1424
  private readonly options;
1400
1425
  private enabled;
1401
1426
  private initialized;
@@ -1446,7 +1471,7 @@ declare class FrpController implements RemoteProviderController {
1446
1471
  }
1447
1472
  //#endregion
1448
1473
  //#region src/origin-proxy-config.d.ts
1449
- declare const DEFAULT_ORIGIN_LISTEN_PORT = 3444;
1474
+ export declare const DEFAULT_ORIGIN_LISTEN_PORT = 3444;
1450
1475
  /** A private HTTP listener behind a user-managed HTTPS reverse proxy. */
1451
1476
  interface OriginSettings {
1452
1477
  readonly version: 1;
@@ -1467,16 +1492,16 @@ interface OriginConfigurationStatus {
1467
1492
  readonly errorCode?: string;
1468
1493
  }
1469
1494
  /** Require a public HTTPS origin; custom external ports are supported. */
1470
- declare function validateOriginPublicOrigin(value: unknown): string;
1495
+ export declare function validateOriginPublicOrigin(value: unknown): string;
1471
1496
  /** Bind only one explicit loopback or RFC1918 IPv4 interface, never all interfaces. */
1472
- declare function validateOriginListenHost(value: unknown): string;
1473
- declare function validateOriginListenPort(value: unknown): number;
1497
+ export declare function validateOriginListenHost(value: unknown): string;
1498
+ export declare function validateOriginListenPort(value: unknown): number;
1474
1499
  /** Authorize direct proxy socket peers, not untrusted forwarded client headers. */
1475
- declare function validateOriginAllowedCidrs(value: unknown, listenHost: string): readonly string[];
1500
+ export declare function validateOriginAllowedCidrs(value: unknown, listenHost: string): readonly string[];
1476
1501
  /** Validate both saved settings and local administrative requests. */
1477
- declare function parseOriginSettings(value: unknown): OriginSettings;
1502
+ export declare function parseOriginSettings(value: unknown): OriginSettings;
1478
1503
  /** Owns only origin settings; shared paired-device storage is never removed. */
1479
- declare class OriginConfigStore {
1504
+ export declare class OriginConfigStore {
1480
1505
  readonly stateRoot: string;
1481
1506
  readonly settingsFile: string;
1482
1507
  private settingsValue;
@@ -1506,7 +1531,7 @@ interface OriginControllerOptions {
1506
1531
  readonly onStatus?: (status: OriginStatus) => void;
1507
1532
  }
1508
1533
  /** Owns an authenticated HTTP gateway, with no tunnel process or public network probes. */
1509
- declare class OriginController implements RemoteProviderController {
1534
+ export declare class OriginController implements RemoteProviderController {
1510
1535
  private readonly options;
1511
1536
  private enabled;
1512
1537
  private initialized;
@@ -1554,7 +1579,7 @@ interface CloudflaredArtifact {
1554
1579
  * {@link CLOUDFLARED_COMPONENT_RELEASES} by platform and architecture; this
1555
1580
  * alias preserves the original Windows x64 entry for existing callers.
1556
1581
  */
1557
- declare const CLOUDFLARED_COMPONENT_RELEASE: CloudflaredArtifact;
1582
+ export declare const CLOUDFLARED_COMPONENT_RELEASE: CloudflaredArtifact;
1558
1583
  /**
1559
1584
  * Public, credential-free description of the managed cloudflared component.
1560
1585
  *
@@ -1580,7 +1605,7 @@ interface CloudflaredComponentManagerOptions {
1580
1605
  readonly fetchArtifact?: (url: string, signal: AbortSignal) => Promise<Uint8Array>;
1581
1606
  }
1582
1607
  /** Owns the optional cloudflared binary inside DSH Mobile state. */
1583
- declare class CloudflaredComponentManager {
1608
+ export declare class CloudflaredComponentManager {
1584
1609
  readonly executable: string;
1585
1610
  readonly componentRoot: string;
1586
1611
  readonly componentStorage: string;
@@ -1644,9 +1669,9 @@ interface CloudflaredTunnelStatus {
1644
1669
  * belongs to quick tunnels, and a `cfargotunnel.com` name is the routing target
1645
1670
  * rather than a routable public address.
1646
1671
  */
1647
- declare function validateCloudflaredTunnelHostname(value: unknown): string;
1672
+ export declare function validateCloudflaredTunnelHostname(value: unknown): string;
1648
1673
  /** Validate the stable loopback port Cloudflare's ingress forwards to. */
1649
- declare function validateCloudflaredTunnelPort(value: unknown): number;
1674
+ export declare function validateCloudflaredTunnelPort(value: unknown): number;
1650
1675
  /**
1651
1676
  * Validate a connector token before durable storage.
1652
1677
  *
@@ -1654,17 +1679,17 @@ declare function validateCloudflaredTunnelPort(value: unknown): number;
1654
1679
  * and tunnel secret; the provider passes it through the environment rather than
1655
1680
  * the command line, and it is never returned to any client.
1656
1681
  */
1657
- declare function validateCloudflaredTunnelToken(value: unknown): string;
1682
+ export declare function validateCloudflaredTunnelToken(value: unknown): string;
1658
1683
  /** Parse tunnel settings at the request and filesystem boundaries. */
1659
- declare function parseCloudflaredTunnelSettings(value: unknown): CloudflaredTunnelSettings;
1684
+ export declare function parseCloudflaredTunnelSettings(value: unknown): CloudflaredTunnelSettings;
1660
1685
  /**
1661
1686
  * Merge a partial panel request with the saved named-tunnel settings so a blank
1662
1687
  * field keeps its stored value. The token in particular is write-only, so the
1663
1688
  * panel submits an empty string to mean "keep the existing connector token".
1664
1689
  */
1665
- declare function mergeSavedCloudflaredTunnelSettings(partial: Readonly<Record<string, unknown>>, saved: CloudflaredTunnelSettings | undefined): CloudflaredTunnelSettings;
1690
+ export declare function mergeSavedCloudflaredTunnelSettings(partial: Readonly<Record<string, unknown>>, saved: CloudflaredTunnelSettings | undefined): CloudflaredTunnelSettings;
1666
1691
  /** Owns the private cloudflared tunnel configuration for one DSH installation. */
1667
- declare class CloudflaredTunnelStore {
1692
+ export declare class CloudflaredTunnelStore {
1668
1693
  readonly stateRoot: string;
1669
1694
  readonly settingsFile: string;
1670
1695
  private settingsValue;
@@ -1719,7 +1744,7 @@ interface CloudflaredControllerOptions {
1719
1744
  * as `https://x.trycloudflare.com.evil.test` fails the hostname check instead of
1720
1745
  * being truncated into an accepted origin.
1721
1746
  */
1722
- declare function parseCloudflaredOrigin(line: string): string | undefined;
1747
+ export declare function parseCloudflaredOrigin(line: string): string | undefined;
1723
1748
  /**
1724
1749
  * Whether one cloudflared log line reports an established edge connection.
1725
1750
  *
@@ -1728,7 +1753,7 @@ declare function parseCloudflaredOrigin(line: string): string | undefined;
1728
1753
  * the current and the older wording are accepted; anything else is ignored so a
1729
1754
  * chatty log line cannot be mistaken for readiness.
1730
1755
  */
1731
- declare function isCloudflaredRegistration(line: string): boolean;
1756
+ export declare function isCloudflaredRegistration(line: string): boolean;
1732
1757
  /**
1733
1758
  * Owns an installed cloudflared client and a provider-specific DSH remote gateway.
1734
1759
  *
@@ -1737,7 +1762,7 @@ declare function isCloudflaredRegistration(line: string): boolean;
1737
1762
  * hostname from the tunnel store, forward to the configured loopback port, and
1738
1763
  * learn readiness from the connector's registration line rather than a banner.
1739
1764
  */
1740
- declare class CloudflaredController implements RemoteProviderController {
1765
+ export declare class CloudflaredController implements RemoteProviderController {
1741
1766
  private readonly options;
1742
1767
  private enabled;
1743
1768
  private initialized;
@@ -1830,19 +1855,19 @@ interface TaskEventWatcherOptions {
1830
1855
  readonly onTaskCompleted: (event: TaskCompletionEvent) => void;
1831
1856
  readonly log?: (event: string, fields: Readonly<Record<string, string | number | boolean>>) => void;
1832
1857
  }
1833
- declare const TASK_EVENT_DEBOUNCE_MS = 1000;
1858
+ export declare const TASK_EVENT_DEBOUNCE_MS = 1000;
1834
1859
  /**
1835
1860
  * Subscribe to completed root turns. Subagent turns are skipped so one task
1836
1861
  * announces once, and rapid turn boundaries collapse into a single event.
1837
1862
  * Returns a disposer that also drops pending debounces.
1838
1863
  */
1839
- declare function watchTaskCompletions(ctx: TaskEventContext, options: TaskEventWatcherOptions): () => void;
1864
+ export declare function watchTaskCompletions(ctx: TaskEventContext, options: TaskEventWatcherOptions): () => void;
1840
1865
  /** Receives fanned-out completion events (normally a mobile gateway). */
1841
1866
  interface TaskEventSink {
1842
1867
  broadcastTaskEvent(event: TaskCompletionEvent): void;
1843
1868
  }
1844
1869
  /** One subscription feeding every live gateway; gateways register on start. */
1845
- declare class TaskEventHub {
1870
+ export declare class TaskEventHub {
1846
1871
  private readonly sinks;
1847
1872
  /** Register a sink; returns its disposer. */
1848
1873
  add(sink: TaskEventSink): () => void;
@@ -1863,13 +1888,13 @@ declare module '@deepseek-ai/dsh-llm' {
1863
1888
  }
1864
1889
  }
1865
1890
  /** Stable Cordis plugin name. */
1866
- declare const name = "dsh-mobile";
1891
+ export declare const name = "dsh-mobile";
1867
1892
  /** The stock WebServer serves the control card; Connection authenticates the loopback DSH origin. */
1868
- declare const inject: string[];
1893
+ export declare const inject: string[];
1869
1894
  /** Reuse remote HTTPS policy while binding a separately validated private HTTP origin. */
1870
- declare function originGatewayConfig(template: ResolvedGatewayConfig, settings: OriginSettings, stateFile: string, instanceId: string, listenPort?: number): ResolvedGatewayConfig;
1895
+ export declare function originGatewayConfig(template: ResolvedGatewayConfig, settings: OriginSettings, stateFile: string, instanceId: string, listenPort?: number): ResolvedGatewayConfig;
1871
1896
  /** Mount the resident control route and its optional authenticated LAN gateway. */
1872
- declare function apply(ctx: Context, config: PluginConfig): Promise<void>;
1897
+ export declare function apply(ctx: Context, config: PluginConfig): Promise<void>;
1873
1898
  //#endregion
1874
- export { AUTH_PREFIX, AccessController, type AccessControllerOptions, AccessError, type AuthoritySpec, type BlockedUpgradePathEntry, BlockedUpgradePathLog, BoundedRateLimiter, CERT_EXPIRING_DAYS, CLOUDFLARED_COMPONENT_RELEASE, CSRF_COOKIE, CSRF_HEADER, type CaddySiteOptions, type CertRenewalStatus, CloudflaredComponentManager, type CloudflaredComponentStatus, CloudflaredController, type CloudflaredControllerOptions, type CloudflaredState, type CloudflaredStatus, type CloudflaredTunnelMode, type CloudflaredTunnelSettings, type CloudflaredTunnelStatus, CloudflaredTunnelStore, Config, DEFAULT_ORIGIN_LISTEN_PORT, FRP_VHOST_HTTP_PORT as DEFAULT_VHOST_HTTP_PORT, FRP_VHOST_HTTP_PORT, DEVICE_COOKIE, type DeviceProbeResult, type DeviceSnapshot, type DeviceStore, type DeviceSummary, type DisabledTlsConfig, EXTENSION_LIMITS, FRP_ATTACH_DISCOVERY_PATH, FRP_ATTACH_LOCAL_DECLARATION, FRP_ATTACH_SELF_SIGNED_DECLARATION, FRP_ATTACH_VPS_DECLARATION, FRP_CADDY_IMPORT_LINE, FRP_CADDY_SNIPPET_MARKER, FRP_CADDY_SNIPPET_PATH, FRP_COMPONENT_RELEASES, FRP_DEFAULT_PROXY_NAME, FRP_DEFAULT_PUBLIC_PORT, FRP_RESERVED_PORTS, type FrpAttachOptions, type FrpAttachPlan, type FrpAttachPlanLocal, type FrpAttachPlanStep, type FrpAttachStepId, type FrpAttachTemplate, type FrpAttachVpsParts, FrpComponentManager, type FrpComponentStatus, FrpConfigStore, type FrpConfigurationStatus, FrpController, type FrpControllerOptions, type FrpEntryTls, type FrpIngressCertificate, type FrpIngressPaths, type FrpIngressSelfCheck, type FrpSettings, type FrpState, type FrpStatus, JsonDeviceStore, JsonMobileAccessControlStore, JsonRemoteProviderStore, LOCAL_ADMIN_PREFIX, type LocalExtensionManifest, MAX_BLOCKED_UPGRADE_PATHS, MAX_EXTRA_WEBSOCKET_PATHS, MAX_WEBSOCKET_PATH_LENGTH, MemoryDeviceStore, type MobileAccessControlState, type MobileAccessControlStore, MobileAccessGateway, MobileAccessGatewayController, type MobileAccessService as MobileAccessRegistry, MobileAccessService, type MobileAccessRuntime, type MobileActionContext, type MobileExtensionClientEntry, type MobileExtensionDefinition, MobileExtensionError, type MobileExtensionManifest, type MobileExtensionStatus, type MobileHostAction, type MobileHostRoute, type MobileRouteRequest, type MobileRouteResponse, OriginConfigStore, type OriginConfigurationStatus, OriginController, type OriginControllerOptions, type OriginSettings, type OriginState, type OriginStatus, type PairingResult, type ParsedCidr, type PluginConfig, type ProvidedTlsConfig, REMOTE_PROVIDERS, type RemoteProvider, type RemoteProviderController, type RemoteProviderState, type RemoteProviderStatus, type RenewalResult, RequestTrustPolicy, type ResolvedGatewayConfig, SESSION_COOKIE, type ServerCertificateAuthority, type ServerCertificateFiles, type ServerCertificateTarget, type SessionAuthorization, type SessionEndReason, type StoredDevice, TASK_EVENT_DEBOUNCE_MS, type TaskCompletionEvent, type TaskEventContext, TaskEventHub, type TaskEventSession, type TaskEventSink, type TaskEventWatcherOptions, type TaskTurnEvent, type TlsConfig, WS_PATHS, WebSocketPathStore, addressAllowed, apply, assertExtensionId, configuredRemoteProvider, createCaddySite, createFrpAttachPlan, createFrpAttachTemplate, createFrpAttachTemplateParts, createFrpServerTemplate, createFrpcToml, createMobileAccessService, createRestrictedFrpServerTemplate, ensureFrpIngressCertificate, evaluateCertificateLifetime, frpAttachVpsParts, frpIngressPaths, frpIngressSelfCheck, frpProxyName, inject, isCloudflaredRegistration, isFrpSelfSignedIngress, isGloballyRoutableIpv4, isLoopbackAddress, issueServerCertificate, mergeSavedCloudflaredTunnelSettings, mergeSavedFrpSettings, mergeSavedFrpTarget, name, normalizeWebSocketPaths, originGatewayConfig, parseAuthority, parseCidr, parseCloudflaredOrigin, parseCloudflaredTunnelSettings, parseControlFile, parseDeviceSnapshot, parseExtensionManifest, parseFrpSettings, parseGatewayConfig, parseMobileAccessControlState, parseOriginSettings, parseRemoteProviderState, probeOriginCertificate, readCertificateRenewal, resolveAuthority, resolveFrpEntryTls, resolveFrpMode, resolveFrpPublicPort, resolveFrpVhostHttpPort, rewriteMobileIndex, validateAttachSettings, validateCloudflaredTunnelHostname, validateCloudflaredTunnelPort, validateCloudflaredTunnelToken, validateFrpEntryTls, validateFrpMode, validateFrpProxyName, validateFrpPublicOrigin, validateFrpPublicPort, validateFrpServerAddress, validateFrpServerPort, validateFrpToken, validateFrpVhostHttpPort, validateOriginAllowedCidrs, validateOriginListenHost, validateOriginListenPort, validateOriginPublicOrigin, validateWebSocketPath, watchTaskCompletions };
1899
+ export { type AccessControllerOptions, type AuthoritySpec, type BlockedUpgradePathEntry, type CaddySiteOptions, type CertRenewalStatus, type CloudflaredComponentStatus, type CloudflaredControllerOptions, type CloudflaredState, type CloudflaredStatus, type CloudflaredTunnelMode, type CloudflaredTunnelSettings, type CloudflaredTunnelStatus, FRP_VHOST_HTTP_PORT as DEFAULT_VHOST_HTTP_PORT, type DeviceProbeResult, type DeviceSnapshot, type DeviceStore, type DeviceSummary, type DisabledTlsConfig, type FrpAttachOptions, type FrpAttachPlan, type FrpAttachPlanLocal, type FrpAttachPlanStep, type FrpAttachStepId, type FrpAttachTemplate, type FrpAttachVpsParts, type FrpComponentStatus, type FrpConfigurationStatus, type FrpControllerOptions, type FrpEntryTls, type FrpIngressCertificate, type FrpIngressPaths, type FrpIngressSelfCheck, type FrpSettings, type FrpState, type FrpStatus, type LocalExtensionManifest, type MobileAccessControlState, type MobileAccessControlStore, type MobileAccessService as MobileAccessRegistry, type MobileAccessRuntime, type MobileActionContext, type MobileExtensionClientEntry, type MobileExtensionDefinition, type MobileExtensionManifest, type MobileExtensionStatus, type MobileHostAction, type MobileHostRoute, type MobileRouteRequest, type MobileRouteResponse, type OriginConfigurationStatus, type OriginControllerOptions, type OriginSettings, type OriginState, type OriginStatus, type PairingResult, type ParsedCidr, type PluginConfig, type ProvidedTlsConfig, type RemoteProvider, type RemoteProviderController, type RemoteProviderState, type RemoteProviderStatus, type RenewalResult, type ResolvedGatewayConfig, type ServerCertificateAuthority, type ServerCertificateFiles, type ServerCertificateTarget, type SessionAuthorization, type SessionEndReason, type StoredDevice, type TaskCompletionEvent, type TaskEventContext, type TaskEventSession, type TaskEventSink, type TaskEventWatcherOptions, type TaskTurnEvent, type TlsConfig };
1875
1900
  //# sourceMappingURL=index.d.mts.map