@camstack/system 1.2.116 → 1.2.118
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/dist/addon-utils.d.ts +1 -1
- package/dist/addon-utils.js +1 -1
- package/dist/addon-utils.mjs +1 -1
- package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
- package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
- package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
- package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
- package/dist/builtins/alerts/alerts.addon.js +1 -1
- package/dist/builtins/alerts/alerts.addon.mjs +1 -1
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +1 -1
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +1 -1
- package/dist/builtins/console-logging/index.js +1 -1
- package/dist/builtins/console-logging/index.mjs +1 -1
- package/dist/builtins/core-blocks/core-blocks.addon.js +1 -1
- package/dist/builtins/core-blocks/core-blocks.addon.mjs +1 -1
- package/dist/builtins/device-manager/device-manager.addon.js +2 -2
- package/dist/builtins/device-manager/device-manager.addon.mjs +2 -2
- package/dist/builtins/doorbell/virtual-doorbell.addon.js +1 -1
- package/dist/builtins/doorbell/virtual-doorbell.addon.mjs +1 -1
- package/dist/builtins/hub-forwarder/index.js +1 -1
- package/dist/builtins/hub-forwarder/index.mjs +1 -1
- package/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
- package/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
- package/dist/builtins/local-auth/local-auth.addon.js +1 -1
- package/dist/builtins/local-auth/local-auth.addon.mjs +1 -1
- package/dist/builtins/local-network/ipv6-lan.d.ts +26 -0
- package/dist/builtins/local-network/local-network.addon.d.ts +50 -14
- package/dist/builtins/local-network/local-network.addon.js +254 -38
- package/dist/builtins/local-network/local-network.addon.mjs +248 -39
- package/dist/builtins/loki-logging/index.js +1 -1
- package/dist/builtins/loki-logging/index.mjs +1 -1
- package/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
- package/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
- package/dist/builtins/platform-probe/index.js +1 -1
- package/dist/builtins/platform-probe/index.mjs +1 -1
- package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
- package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
- package/dist/builtins/snapshot/index.js +1 -1
- package/dist/builtins/snapshot/index.mjs +1 -1
- package/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
- package/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
- package/dist/builtins/sqlite-storage/sqlite-settings.addon.js +2 -2
- package/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +2 -2
- package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
- package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
- package/dist/builtins/system-config/system-config.addon.js +1 -1
- package/dist/builtins/system-config/system-config.addon.mjs +1 -1
- package/dist/builtins/winston-logging/index.js +1 -1
- package/dist/builtins/winston-logging/index.mjs +1 -1
- package/dist/{dist-Cri60Jd0.js → dist-C2_1HCpW.js} +149 -23
- package/dist/{dist-BpzbLPel.mjs → dist-DCTpBXm4.mjs} +149 -23
- package/dist/download/model-downloader.d.ts +18 -1
- package/dist/{file-data-plane-CuE_hBli.mjs → file-data-plane-BhKdxJgf.mjs} +49 -13
- package/dist/{file-data-plane-DUHPHa-Y.js → file-data-plane-DO8KbxCe.js} +49 -13
- package/dist/http/lan-http-bind.d.ts +12 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -3
- package/dist/index.mjs +4 -4
- package/dist/{lan-http-bind-CZ4EBeD_.js → lan-http-bind-DmgpFP6_.js} +53 -11
- package/dist/{lan-http-bind-BDJm4d-K.mjs → lan-http-bind-jKrj6OjQ.mjs} +48 -12
- package/dist/{retired-settings-keys-SrxMH3OT.mjs → retired-settings-keys-Czd76yLZ.mjs} +1 -1
- package/dist/{retired-settings-keys-BVAxT5XL.js → retired-settings-keys-DHRXLMPn.js} +1 -1
- package/package.json +1 -1
package/dist/addon-utils.d.ts
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*
|
|
15
15
|
* See memory: camstack_runner_ram_and_build_rootcause.
|
|
16
16
|
*/
|
|
17
|
-
export { downloadFile, ensureModel, isModelDownloaded, deleteModelFromDisk, collectModelFiles, getModelFilePath, } from './download/model-downloader.js';
|
|
17
|
+
export { downloadFile, ensureModel, isModelDownloaded, deleteModelFromDisk, collectModelFiles, getModelFilePath, type DownloadFileOptions, type DownloadRedirectPolicy, } from './download/model-downloader.js';
|
|
18
18
|
export { ModelDownloadService } from './download/model-download-service.js';
|
|
19
19
|
export { createFileDataPlaneHandler } from './http/file-data-plane.js';
|
|
20
20
|
export { parseRangeHeader, contentTypeFor, type ByteRange, } from './http/authenticated-file-server.js';
|
package/dist/addon-utils.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
require("./chunk-Cek0wNdY.js");
|
|
3
|
-
const require_file_data_plane = require("./file-data-plane-
|
|
3
|
+
const require_file_data_plane = require("./file-data-plane-DO8KbxCe.js");
|
|
4
4
|
const require_custom_action_registry = require("./custom-action-registry-jY0NOZK8.js");
|
|
5
5
|
exports.CustomActionRegistry = require_custom_action_registry.CustomActionRegistry;
|
|
6
6
|
exports.ModelDownloadService = require_file_data_plane.ModelDownloadService;
|
package/dist/addon-utils.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { c as collectModelFiles, f as ensureModel, h as isModelDownloaded, i as parseRangeHeader, l as deleteModelFromDisk, m as getModelFilePath, n as contentTypeFor, s as ModelDownloadService, t as createFileDataPlaneHandler, u as downloadFile } from "./file-data-plane-
|
|
1
|
+
import { c as collectModelFiles, f as ensureModel, h as isModelDownloaded, i as parseRangeHeader, l as deleteModelFromDisk, m as getModelFilePath, n as contentTypeFor, s as ModelDownloadService, t as createFileDataPlaneHandler, u as downloadFile } from "./file-data-plane-BhKdxJgf.mjs";
|
|
2
2
|
import { t as CustomActionRegistry } from "./custom-action-registry-F__gp_VX.mjs";
|
|
3
3
|
export { CustomActionRegistry, ModelDownloadService, collectModelFiles, contentTypeFor, createFileDataPlaneHandler, deleteModelFromDisk, downloadFile, ensureModel, getModelFilePath, isModelDownloaded, parseRangeHeader };
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
let node_path = require("node:path");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Gt as EventCategory, v as addonPagesCapability, vt as errMsg, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { Gt as EventCategory, v as addonPagesCapability, vt as errMsg, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
|
|
3
3
|
import { createHash, randomUUID } from "node:crypto";
|
|
4
4
|
import * as path$1 from "node:path";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
let node_path = require("node:path");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Gt as EventCategory, b as addonWidgetsCapability, vt as errMsg, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { Gt as EventCategory, b as addonWidgetsCapability, vt as errMsg, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
|
|
3
3
|
import { createHash, randomUUID } from "node:crypto";
|
|
4
4
|
import * as path$1 from "node:path";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
//#region src/builtins/alerts/prune-policy.ts
|
|
8
8
|
/**
|
|
9
9
|
* Ids older than `cutoffMs`, oldest first.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Gt as EventCategory, Mt as createEvent, n as AlertSchema, vt as errMsg, x as alertsCapability, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { Gt as EventCategory, Mt as createEvent, n as AlertSchema, vt as errMsg, x as alertsCapability, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
//#region src/builtins/alerts/prune-policy.ts
|
|
3
3
|
/**
|
|
4
4
|
* Ids older than `cutoffMs`, oldest first.
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
let node_crypto = require("node:crypto");
|
|
8
8
|
let buffer = require("buffer");
|
|
9
9
|
let node_fs_promises = require("node:fs/promises");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as backupCapability, Gt as EventCategory, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { C as backupCapability, Gt as EventCategory, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
import { randomBytes, randomUUID } from "node:crypto";
|
|
3
3
|
import { Buffer as Buffer$1 } from "buffer";
|
|
4
4
|
import * as fsp from "node:fs/promises";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
const require_formatter = require("../../formatter-DqAKDlvN.js");
|
|
8
8
|
//#region src/builtins/console-logging/console-destination.ts
|
|
9
9
|
var LEVEL_RANK = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { X as logDestinationCapability, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { X as logDestinationCapability, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
|
|
3
3
|
//#region src/builtins/console-logging/console-destination.ts
|
|
4
4
|
var LEVEL_RANK = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist-
|
|
3
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
4
4
|
let node_crypto = require("node:crypto");
|
|
5
5
|
let node_fs_promises = require("node:fs/promises");
|
|
6
6
|
node_fs_promises = require_chunk.__toESM(node_fs_promises);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { D as coreBlockAddonId, O as coreBlockIdFromAddonId, c as CoreBlockSchema, k as coreBlocksCapability, l as DeclaredDevices, o as CORE_BLOCKS_ADDON_ID, s as CORE_BLOCK_ADDON_PREFIX, vt as errMsg, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { D as coreBlockAddonId, O as coreBlockIdFromAddonId, c as CoreBlockSchema, k as coreBlocksCapability, l as DeclaredDevices, o as CORE_BLOCKS_ADDON_ID, s as CORE_BLOCK_ADDON_PREFIX, vt as errMsg, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
import * as fs from "node:fs/promises";
|
|
4
4
|
import * as path$1 from "node:path";
|
|
@@ -3,8 +3,8 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
7
|
-
const require_retired_settings_keys = require("../../retired-settings-keys-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
|
+
const require_retired_settings_keys = require("../../retired-settings-keys-DHRXLMPn.js");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
let _camstack_types_node = require("@camstack/types/node");
|
|
10
10
|
//#region src/builtins/device-manager/adoption-job-engine.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Ct as DeviceFeature, E as buildStreamParamsConfigSchema, F as deviceStatusCapability, Gt as EventCategory, Lt as isDeviceConfigCap, N as deviceManagerCapability, Ot as WELL_KNOWN_TAB_MAP, P as deviceStateCapability, R as enumerateItemArrayFields, Tt as DeviceType, Wt as sleep, a as CAP_NAMES_WITH_STATUS, at as runtimeStatePolicyFor, et as normalizeUnit, nt as parseStreamParamsFormPatch, p as STREAM_PROFILE_META, t as ALL_CAPABILITY_DEFINITIONS, u as DeviceStatusSchema, vt as errMsg, wt as DeviceRole, yt as BaseAddon, z as enumerateSchemaFields } from "../../dist-
|
|
2
|
-
import { n as purgeRetiredSettingsRows } from "../../retired-settings-keys-
|
|
1
|
+
import { Ct as DeviceFeature, E as buildStreamParamsConfigSchema, F as deviceStatusCapability, Gt as EventCategory, Lt as isDeviceConfigCap, N as deviceManagerCapability, Ot as WELL_KNOWN_TAB_MAP, P as deviceStateCapability, R as enumerateItemArrayFields, Tt as DeviceType, Wt as sleep, a as CAP_NAMES_WITH_STATUS, at as runtimeStatePolicyFor, et as normalizeUnit, nt as parseStreamParamsFormPatch, p as STREAM_PROFILE_META, t as ALL_CAPABILITY_DEFINITIONS, u as DeviceStatusSchema, vt as errMsg, wt as DeviceRole, yt as BaseAddon, z as enumerateSchemaFields } from "../../dist-DCTpBXm4.mjs";
|
|
2
|
+
import { n as purgeRetiredSettingsRows } from "../../retired-settings-keys-Czd76yLZ.mjs";
|
|
3
3
|
import { randomUUID } from "node:crypto";
|
|
4
4
|
import { canonicalDeviceFingerprint } from "@camstack/types/node";
|
|
5
5
|
//#region src/builtins/device-manager/adoption-job-engine.ts
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
//#region src/builtins/doorbell/trigger-engine.ts
|
|
8
8
|
/**
|
|
9
9
|
* Pure trigger logic for the virtual-doorbell builtin — edge detection over
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { G as isSameAddonId, Gt as EventCategory, I as doorbellCapability, Mt as createEvent, Tt as DeviceType, vt as errMsg, w as bareAddonId, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { G as isSameAddonId, Gt as EventCategory, I as doorbellCapability, Mt as createEvent, Tt as DeviceType, vt as errMsg, w as bareAddonId, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
//#region src/builtins/doorbell/trigger-engine.ts
|
|
3
3
|
/**
|
|
4
4
|
* Pure trigger logic for the virtual-doorbell builtin — edge detection over
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
const require_formatter = require("../../formatter-DqAKDlvN.js");
|
|
8
8
|
//#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
|
|
9
9
|
var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { X as logDestinationCapability, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { X as logDestinationCapability, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
|
|
3
3
|
//#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
|
|
4
4
|
var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist-
|
|
3
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
4
4
|
//#region src/builtins/liveness-monitor/liveness-checks.ts
|
|
5
5
|
var NO_DEVICES = "liveness:no-devices";
|
|
6
6
|
var ALL_OFFLINE = "liveness:all-devices-offline";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Gt as EventCategory, Mt as createEvent, vt as errMsg, yt as BaseAddon } from "../../dist-
|
|
1
|
+
import { Gt as EventCategory, Mt as createEvent, vt as errMsg, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
2
2
|
//#region src/builtins/liveness-monitor/liveness-checks.ts
|
|
3
3
|
var NO_DEVICES = "liveness:no-devices";
|
|
4
4
|
var ALL_OFFLINE = "liveness:all-devices-offline";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-C2_1HCpW.js");
|
|
7
7
|
let node_crypto = require("node:crypto");
|
|
8
8
|
node_crypto = require_chunk.__toESM(node_crypto);
|
|
9
9
|
let crypto$1 = require("crypto");
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { i as __require, o as __toESM, t as __commonJSMin } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import { S as authProviderCapability, _ as UserRecordSchema, ht as userManagementCapability, m as ScopedTokenSchema, r as ApiKeyRecordSchema, yt as BaseAddon } from "../../dist-
|
|
2
|
+
import { S as authProviderCapability, _ as UserRecordSchema, ht as userManagementCapability, m as ScopedTokenSchema, r as ApiKeyRecordSchema, yt as BaseAddon } from "../../dist-DCTpBXm4.mjs";
|
|
3
3
|
import * as crypto$2 from "node:crypto";
|
|
4
4
|
import { createHash, randomUUID, timingSafeEqual } from "node:crypto";
|
|
5
5
|
import nodeCrypto from "crypto";
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* IPv6 helpers for LAN advertisement: prefix matching (privacy addresses
|
|
3
|
+
* rotate inside a /64), Linux `/proc/net/if_inet6` flags, and the gate
|
|
4
|
+
* that keeps temporary GUA off the connection candidate list.
|
|
5
|
+
*/
|
|
6
|
+
/** First 64 bits, canonical hex groups, or null if the address is not IPv6. */
|
|
7
|
+
export declare function ipv6Prefix64Key(address: string): string | null;
|
|
8
|
+
/** 32-char lowercase hex (same encoding as `/proc/net/if_inet6`). */
|
|
9
|
+
export declare function ipv6ToHex32(address: string): string | null;
|
|
10
|
+
/**
|
|
11
|
+
* Parse Linux `if_inet6` into hex32 → flags. Unknown / malformed lines
|
|
12
|
+
* are skipped. Keys match {@link ipv6ToHex32}.
|
|
13
|
+
*/
|
|
14
|
+
export declare function parseProcIfInet6(text: string): ReadonlyMap<string, number>;
|
|
15
|
+
/**
|
|
16
|
+
* Whether this IPv6 should be auto-seeded / advertised.
|
|
17
|
+
* `flags === undefined` means the platform did not tell us (macOS, tests
|
|
18
|
+
* without a proc snapshot) — keep every non-link-local plausible address.
|
|
19
|
+
*
|
|
20
|
+
* On Linux, drop addresses marked TEMPORARY / DEPRECATED / TENTATIVE, and
|
|
21
|
+
* `flags === 0` which is how this kernel reports RFC 4941 privacy temps
|
|
22
|
+
* (the stable GUA is PERMANENT|NODAD). Do **not** require PERMANENT —
|
|
23
|
+
* stateful DHCPv6 GUA often has only NODAD (0x02).
|
|
24
|
+
*/
|
|
25
|
+
export declare function shouldAdvertiseIpv6(address: string, flags: number | undefined): boolean;
|
|
26
|
+
export declare function ipv6AllowlistMatches(address: string, allowed: readonly string[]): boolean;
|
|
@@ -10,6 +10,8 @@ interface MeshEndpointCache {
|
|
|
10
10
|
/** Hub HTTPS port the mesh endpoint targets. */
|
|
11
11
|
readonly port: number;
|
|
12
12
|
}
|
|
13
|
+
/** Drop rotated IPv6 / dead extras from the persisted allowlist. */
|
|
14
|
+
export declare const ALLOWLIST_RECONCILE_INTERVAL_MS: number;
|
|
13
15
|
/** The three places a hub listen port can be learned, most authoritative first. */
|
|
14
16
|
export interface ListenPortSources {
|
|
15
17
|
/** `server.port` from the hub's live config section; null when unreadable. */
|
|
@@ -37,6 +39,11 @@ interface LocalNetworkConfig {
|
|
|
37
39
|
* different address after a reboot.
|
|
38
40
|
*/
|
|
39
41
|
readonly notificationBaseUrl: string;
|
|
42
|
+
/**
|
|
43
|
+
* Base URLs the SDK / viewer should race. Empty = AUTO (LAN IPv4 + public
|
|
44
|
+
* tunnel). Stored verbatim, same contract as `notificationBaseUrl`.
|
|
45
|
+
*/
|
|
46
|
+
readonly viewerBaseUrls: readonly string[];
|
|
40
47
|
/** LAN HTTP listener. Default true — native apps skip the private cert. */
|
|
41
48
|
readonly httpEnabled: boolean;
|
|
42
49
|
/** Dedicated HTTP port. Must not equal the HTTPS listen port. */
|
|
@@ -46,6 +53,8 @@ interface LocalNetworkConfig {
|
|
|
46
53
|
}
|
|
47
54
|
export declare class LocalNetworkAddon extends BaseAddon<LocalNetworkConfig> {
|
|
48
55
|
private pollTimer;
|
|
56
|
+
private allowlistTimer;
|
|
57
|
+
private allowlistReconcilePending;
|
|
49
58
|
private lastSnapshotKey;
|
|
50
59
|
/** Optional public hostname tracked from `NetworkTunnelStarted`/
|
|
51
60
|
* `Stopped` events on the bus. */
|
|
@@ -66,6 +75,13 @@ export declare class LocalNetworkAddon extends BaseAddon<LocalNetworkConfig> {
|
|
|
66
75
|
* rather than a link that 404s).
|
|
67
76
|
*/
|
|
68
77
|
private resolveNotificationEndpoint;
|
|
78
|
+
private snapshotViewerEndpoints;
|
|
79
|
+
/**
|
|
80
|
+
* Palette shown in the Network tab: LAN IPv4, stable LAN IPv6, public,
|
|
81
|
+
* mesh. The viewer HTTP/WS race is a subset (`selectViewerEndpoints`) —
|
|
82
|
+
* IPv6 stays in this list because ICE/WebRTC gathers it regardless.
|
|
83
|
+
*/
|
|
84
|
+
private buildAdvertisedEndpoints;
|
|
69
85
|
protected onInitialize(): Promise<ProviderRegistration[]>;
|
|
70
86
|
protected globalSettingsSchema(): import('@camstack/types').ConfigUISchema;
|
|
71
87
|
protected onConfigChanged(): Promise<void>;
|
|
@@ -115,6 +131,11 @@ export declare class LocalNetworkAddon extends BaseAddon<LocalNetworkConfig> {
|
|
|
115
131
|
/** `server.port` from the live config section, or null when unreadable. */
|
|
116
132
|
private readConfiguredPort;
|
|
117
133
|
private enumerate;
|
|
134
|
+
/**
|
|
135
|
+
* Replace rotated IPv6 and drop addresses that no longer exist, without
|
|
136
|
+
* clearing operator extras that are still live (docker/vpn opt-in).
|
|
137
|
+
*/
|
|
138
|
+
private persistReconciledAllowlist;
|
|
118
139
|
private detectChanges;
|
|
119
140
|
}
|
|
120
141
|
/**
|
|
@@ -142,12 +163,14 @@ interface OsNetworkInterfaceInfo {
|
|
|
142
163
|
readonly internal: boolean;
|
|
143
164
|
readonly mac: string;
|
|
144
165
|
}
|
|
145
|
-
export declare function enumerateOsInterfaces(ifaces: NodeJS.Dict<readonly OsNetworkInterfaceInfo[]>): readonly LocalInterface[];
|
|
166
|
+
export declare function enumerateOsInterfaces(ifaces: NodeJS.Dict<readonly OsNetworkInterfaceInfo[]>, ipv6Flags?: ReadonlyMap<string, number>): readonly LocalInterface[];
|
|
146
167
|
/**
|
|
147
168
|
* Filter the interface list by the operator's allowlist. Empty
|
|
148
169
|
* allowlist = no-op (every interface passes); otherwise only entries
|
|
149
|
-
* whose `address` matches an allowlist entry remain.
|
|
150
|
-
*
|
|
170
|
+
* whose `address` matches an allowlist entry remain. IPv6 matches the
|
|
171
|
+
* allowlisted /64 so a rotated privacy address does not hide the live
|
|
172
|
+
* GUA. Loopback is not an advertised client route and is not forced
|
|
173
|
+
* through.
|
|
151
174
|
*/
|
|
152
175
|
export declare function applyAllowlist(interfaces: readonly LocalInterface[], allowed: readonly string[]): readonly LocalInterface[];
|
|
153
176
|
/**
|
|
@@ -157,17 +180,16 @@ export declare function applyAllowlist(interfaces: readonly LocalInterface[], al
|
|
|
157
180
|
export declare function pickPreferred(interfaces: readonly LocalInterface[]): LocalInterface | null;
|
|
158
181
|
/**
|
|
159
182
|
* Build the ordered candidate URL list. Priority schema:
|
|
160
|
-
* 0 — preferred LAN IPv4
|
|
161
|
-
* 10+ — other LAN IPv4
|
|
183
|
+
* 0 — preferred LAN IPv4 (or local hostname)
|
|
184
|
+
* 10+ — other LAN IPv4 and stable LAN IPv6
|
|
162
185
|
* 100 — public tunnel hostname (always HTTPS)
|
|
163
186
|
* 150 — mesh endpoint (Tailscale MagicDNS / 100.x, always HTTPS)
|
|
164
|
-
* 200+ — LAN IPv6
|
|
165
187
|
* 1000 — loopback (last resort)
|
|
166
188
|
*
|
|
167
189
|
* The mesh endpoint ranks just below a true public funnel (a Funnel is
|
|
168
190
|
* reachable by ANY client; the mesh needs the peer on the same tailnet)
|
|
169
|
-
* but above
|
|
170
|
-
*
|
|
191
|
+
* but above loopback. LAN IPv6 sits in the LAN band with IPv4 so a
|
|
192
|
+
* dual-stack client can win the race on IPv6 when it is faster.
|
|
171
193
|
*
|
|
172
194
|
* `scheme` controls loopback URLs and, when LAN HTTP is off, LAN URLs.
|
|
173
195
|
* When {@link LanHttpAdvertisement} is enabled and listening, LAN (and
|
|
@@ -184,17 +206,25 @@ export interface LanHttpAdvertisement {
|
|
|
184
206
|
readonly localHostname: string | null;
|
|
185
207
|
}
|
|
186
208
|
export declare function buildEndpoints(interfaces: readonly LocalInterface[], port: number, includeLoopback: boolean, ipv4Only: boolean, publicHostname: string, scheme?: 'http' | 'https', meshEndpoint?: MeshEndpointCache | null, lanHttp?: LanHttpAdvertisement | null): ConnectionEndpoint[];
|
|
209
|
+
/** AUTO viewer race: LAN IPv4 + the public tunnel. Never IPv6, mesh, or loopback. */
|
|
210
|
+
export declare function isDefaultViewerEndpoint(endpoint: ConnectionEndpoint): boolean;
|
|
211
|
+
/**
|
|
212
|
+
* The URLs the SDK should race for API / viewer access.
|
|
213
|
+
*
|
|
214
|
+
* Empty `viewerBaseUrls` = AUTO (IPv4 + public tunnel). A non-empty list is
|
|
215
|
+
* the operator's pin; if none of those URLs are in the current palette,
|
|
216
|
+
* fall back to AUTO rather than racing an empty set.
|
|
217
|
+
*/
|
|
218
|
+
export declare function selectViewerEndpoints(endpoints: readonly ConnectionEndpoint[], viewerBaseUrls: readonly string[]): ConnectionEndpoint[];
|
|
187
219
|
/**
|
|
188
220
|
* First-boot heuristic: which addresses should the allowlist start
|
|
189
221
|
* with? Includes LAN + Wi-Fi IPv4 addresses + plausible IPv6:
|
|
190
222
|
*
|
|
191
223
|
* - **IPv4**: skip link-local (`169.254.*`), keep the rest.
|
|
192
224
|
* - **IPv6**: skip link-local (`fe80::*`), unspecified, and
|
|
193
|
-
* multicast. Keep ULAs (`fc00::/7`
|
|
194
|
-
*
|
|
195
|
-
*
|
|
196
|
-
* prune them from the Network Addresses tab if the rotating IPs
|
|
197
|
-
* become a nuisance.
|
|
225
|
+
* multicast. Keep ULAs (`fc00::/7`) and Global Unicast (`2000::/3`).
|
|
226
|
+
* Privacy-extension temporary addresses are skipped when Linux flags
|
|
227
|
+
* mark them non-permanent (`plausible === false`).
|
|
198
228
|
*
|
|
199
229
|
* Skips docker/vpn/loopback/other entirely — those stay opt-in.
|
|
200
230
|
*/
|
|
@@ -219,4 +249,10 @@ export declare function isPlausibleAutoSeed(address: string, family: 'IPv4' | 'I
|
|
|
219
249
|
export declare function classifyKind(name: string, address: string, internal: boolean): LocalInterface['kind'];
|
|
220
250
|
/** Convert an IPv4/IPv6 netmask string to its prefix length (CIDR). */
|
|
221
251
|
export declare function prefixLen(netmask: string): number;
|
|
222
|
-
|
|
252
|
+
/**
|
|
253
|
+
* Rewrite a persisted allowlist against the live interface set:
|
|
254
|
+
* current auto-seed (LAN/Wi-Fi, stable IPv6) plus still-live operator
|
|
255
|
+
* extras (docker/vpn). Empty stays empty — that is "unrestricted".
|
|
256
|
+
*/
|
|
257
|
+
export declare function reconcileAllowlist(current: readonly string[], interfaces: readonly LocalInterface[]): string[];
|
|
258
|
+
export { ipv6Prefix64Key, parseProcIfInet6, shouldAdvertiseIpv6, } from './ipv6-lan.js';
|