@camstack/system 1.2.380 → 1.2.381

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 (76) hide show
  1. package/dist/addon-runner.js +1 -1
  2. package/dist/addon-runner.mjs +1 -1
  3. package/dist/addon-utils.js +1 -1
  4. package/dist/addon-utils.mjs +1 -1
  5. package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
  6. package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
  7. package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
  8. package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
  9. package/dist/builtins/alerts/alerts.addon.js +1 -1
  10. package/dist/builtins/alerts/alerts.addon.mjs +1 -1
  11. package/dist/builtins/autotrack/index.js +1 -1
  12. package/dist/builtins/autotrack/index.mjs +1 -1
  13. package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +1 -1
  14. package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +1 -1
  15. package/dist/builtins/calendars/calendars.addon.js +1 -1
  16. package/dist/builtins/calendars/calendars.addon.mjs +1 -1
  17. package/dist/builtins/camera-grid/index.js +1 -1
  18. package/dist/builtins/camera-grid/index.mjs +1 -1
  19. package/dist/builtins/composer/composer.addon.js +2 -2
  20. package/dist/builtins/composer/composer.addon.mjs +2 -2
  21. package/dist/builtins/console-logging/index.js +1 -1
  22. package/dist/builtins/console-logging/index.mjs +1 -1
  23. package/dist/builtins/core-blocks/core-blocks.addon.js +2 -2
  24. package/dist/builtins/core-blocks/core-blocks.addon.mjs +2 -2
  25. package/dist/builtins/device-manager/device-aggregation.d.ts +12 -0
  26. package/dist/builtins/device-manager/device-form-secrets.d.ts +25 -0
  27. package/dist/builtins/device-manager/device-manager.addon.d.ts +2 -0
  28. package/dist/builtins/device-manager/device-manager.addon.js +165 -26
  29. package/dist/builtins/device-manager/device-manager.addon.mjs +165 -26
  30. package/dist/builtins/hub-forwarder/index.js +1 -1
  31. package/dist/builtins/hub-forwarder/index.mjs +1 -1
  32. package/dist/builtins/keychain/index.js +3 -3
  33. package/dist/builtins/keychain/index.mjs +3 -3
  34. package/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
  35. package/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
  36. package/dist/builtins/local-auth/local-auth.addon.js +2 -2
  37. package/dist/builtins/local-auth/local-auth.addon.mjs +2 -2
  38. package/dist/builtins/local-network/local-network.addon.js +1 -1
  39. package/dist/builtins/local-network/local-network.addon.mjs +1 -1
  40. package/dist/builtins/loki-logging/index.js +1 -1
  41. package/dist/builtins/loki-logging/index.mjs +1 -1
  42. package/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
  43. package/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
  44. package/dist/builtins/platform-probe/index.js +1 -1
  45. package/dist/builtins/platform-probe/index.mjs +1 -1
  46. package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
  47. package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
  48. package/dist/builtins/snapshot/index.js +1 -1
  49. package/dist/builtins/snapshot/index.mjs +1 -1
  50. package/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
  51. package/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
  52. package/dist/builtins/sqlite-storage/sqlite-settings.addon.js +0 -0
  53. package/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +0 -0
  54. package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
  55. package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
  56. package/dist/builtins/system-config/system-config.addon.js +2 -2
  57. package/dist/builtins/system-config/system-config.addon.mjs +2 -2
  58. package/dist/builtins/winston-logging/index.js +1 -1
  59. package/dist/builtins/winston-logging/index.mjs +1 -1
  60. package/dist/{child-cap-dispatch-CpjohToR.mjs → child-cap-dispatch-BTe4eKep.mjs} +1 -1
  61. package/dist/{child-cap-dispatch-CZeRUgYF.js → child-cap-dispatch-hf-Gce_4.js} +1 -1
  62. package/dist/{cluster-secret-Dg0OOOSr.js → cluster-secret-BUiG8DCo.js} +1 -1
  63. package/dist/{cluster-secret-BDue-uJj.mjs → cluster-secret-DgJTZ4qY.mjs} +1 -1
  64. package/dist/{composition-sources-CHvLMrFI.js → composition-sources-4SmsP0O4.js} +1 -1
  65. package/dist/{composition-sources-DT_uJwI3.mjs → composition-sources-CgOQVIwa.mjs} +1 -1
  66. package/dist/{dist-B9oFw2jh.mjs → dist-BC0GnGeg.mjs} +5 -1
  67. package/dist/{dist-Cc6KOdY-.js → dist-BugrtARh.js} +34 -0
  68. package/dist/{event-loop-stall-monitor-mk6WGxir.js → event-loop-stall-monitor-CnQ-K6Gn.js} +1 -1
  69. package/dist/{event-loop-stall-monitor-anUH2IE1.mjs → event-loop-stall-monitor-GgpnfAC0.mjs} +1 -1
  70. package/dist/index.js +5 -5
  71. package/dist/index.mjs +5 -5
  72. package/dist/{jwt-signing-key-C2rE3wH6.js → jwt-signing-key-CjoZcol8.js} +1 -1
  73. package/dist/{jwt-signing-key-Qhde8r82.mjs → jwt-signing-key-CsuVKA1W.mjs} +1 -1
  74. package/dist/{retired-settings-keys-YOOKLA3v.js → retired-settings-keys-DCuetwOt.js} +1 -1
  75. package/dist/{retired-settings-keys-DlZ3VV6x.mjs → retired-settings-keys-MCVhxPkJ.mjs} +1 -1
  76. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
1
  const require_chunk = require("./chunk-Cek0wNdY.js");
2
- const require_child_cap_dispatch = require("./child-cap-dispatch-CZeRUgYF.js");
2
+ const require_child_cap_dispatch = require("./child-cap-dispatch-hf-Gce_4.js");
3
3
  const require_custom_action_registry = require("./custom-action-registry-acBY3mHA.js");
4
4
  let node_path = require("node:path");
5
5
  node_path = require_chunk.__toESM(node_path);
@@ -1,4 +1,4 @@
1
- import { Ft as installManifestNativeDeps, H as createUdsLoggerWithControl, It as resolveAddonClass, St as validateProviderRegistrations, U as LocalChildClient, _n as startRunnerHeapWatch, _t as getWorkerNativeCapProvider, bt as setWorkerNativeCapsChangeListener, f as installManifestSystemDeps, g as createUdsAddonContext, i as killOwnRunnerGroupAfterParentLoss, in as RUNNER_RSS_BUDGET_ENV, kn as emitHeapDiagnosticReport, n as createChildCapDispatch, p as installManifestPythonDeps, u as startRunnerParentDeathWatchdog, vt as getWorkerNativeCapSnapshot } from "./child-cap-dispatch-CpjohToR.mjs";
1
+ import { Ft as installManifestNativeDeps, H as createUdsLoggerWithControl, It as resolveAddonClass, St as validateProviderRegistrations, U as LocalChildClient, _n as startRunnerHeapWatch, _t as getWorkerNativeCapProvider, bt as setWorkerNativeCapsChangeListener, f as installManifestSystemDeps, g as createUdsAddonContext, i as killOwnRunnerGroupAfterParentLoss, in as RUNNER_RSS_BUDGET_ENV, kn as emitHeapDiagnosticReport, n as createChildCapDispatch, p as installManifestPythonDeps, u as startRunnerParentDeathWatchdog, vt as getWorkerNativeCapSnapshot } from "./child-cap-dispatch-BTe4eKep.mjs";
2
2
  import { t as CustomActionRegistry } from "./custom-action-registry-B4Cf4O_X.mjs";
3
3
  import { register } from "node:module";
4
4
  import * as path$1 from "node:path";
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  require("./chunk-Cek0wNdY.js");
3
- const require_event_loop_stall_monitor = require("./event-loop-stall-monitor-mk6WGxir.js");
3
+ const require_event_loop_stall_monitor = require("./event-loop-stall-monitor-CnQ-K6Gn.js");
4
4
  const require_custom_action_registry = require("./custom-action-registry-acBY3mHA.js");
5
5
  const require_snapshot_courtesy = require("./snapshot-courtesy-D_C5-nC0.js");
6
6
  exports.COURTESY_DEFAULT_WIDTH = require_snapshot_courtesy.COURTESY_DEFAULT_WIDTH;
@@ -1,4 +1,4 @@
1
- import { C as resolveFormatRevision, S as isModelDownloaded, a as createFileDataPlaneHandler, b as getModelFilePath, c as parseRangeHeader, d as ModelDownloadService, f as ModelDownloadHttpError, g as downloadFile, h as deleteModelFromDisk, i as startEventLoopStallMonitor, m as collectModelFiles, n as STALL_TICK_MS, o as contentTypeFor, p as adoptModelRevisions, r as attributeStall, t as STALL_REPORT_MS, v as ensureModel, x as isModelDownloadHttpError } from "./event-loop-stall-monitor-anUH2IE1.mjs";
1
+ import { C as resolveFormatRevision, S as isModelDownloaded, a as createFileDataPlaneHandler, b as getModelFilePath, c as parseRangeHeader, d as ModelDownloadService, f as ModelDownloadHttpError, g as downloadFile, h as deleteModelFromDisk, i as startEventLoopStallMonitor, m as collectModelFiles, n as STALL_TICK_MS, o as contentTypeFor, p as adoptModelRevisions, r as attributeStall, t as STALL_REPORT_MS, v as ensureModel, x as isModelDownloadHttpError } from "./event-loop-stall-monitor-GgpnfAC0.mjs";
2
2
  import { t as CustomActionRegistry } from "./custom-action-registry-B4Cf4O_X.mjs";
3
3
  import { i as renderCourtesyOverlayJpeg, n as courtesyCacheKey, r as renderCourtesyJpeg, t as COURTESY_DEFAULT_WIDTH } from "./snapshot-courtesy-CyFs1M3I.mjs";
4
4
  export { COURTESY_DEFAULT_WIDTH, CustomActionRegistry, ModelDownloadHttpError, ModelDownloadService, STALL_REPORT_MS, STALL_TICK_MS, adoptModelRevisions, attributeStall, collectModelFiles, contentTypeFor, courtesyCacheKey, createFileDataPlaneHandler, deleteModelFromDisk, downloadFile, ensureModel, getModelFilePath, isModelDownloadHttpError, isModelDownloaded, parseRangeHeader, renderCourtesyJpeg, renderCourtesyOverlayJpeg, resolveFormatRevision, startEventLoopStallMonitor };
@@ -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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.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 { W as addonPagesCapability, cr as errMsg, lr as BaseAddon, qr as EventCategory } from "../../dist-B9oFw2jh.mjs";
1
+ import { Qr as EventCategory, W as addonPagesCapability, cr as errMsg, lr as BaseAddon } from "../../dist-BC0GnGeg.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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.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 { K as addonWidgetsCapability, cr as errMsg, lr as BaseAddon, qr as EventCategory } from "../../dist-B9oFw2jh.mjs";
1
+ import { K as addonWidgetsCapability, Qr as EventCategory, cr as errMsg, lr as BaseAddon } from "../../dist-BC0GnGeg.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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.js");
7
7
  //#region src/builtins/alerts/device-label.ts
8
8
  /**
9
9
  * Operator-facing device label for alert messages.
@@ -1,4 +1,4 @@
1
- import { Cr as createEvent, cr as errMsg, lr as BaseAddon, n as AlertSchema, q as alertsCapability, qr as EventCategory } from "../../dist-B9oFw2jh.mjs";
1
+ import { Qr as EventCategory, cr as errMsg, lr as BaseAddon, n as AlertSchema, q as alertsCapability, wr as createEvent } from "../../dist-BC0GnGeg.mjs";
2
2
  //#region src/builtins/alerts/device-label.ts
3
3
  /**
4
4
  * Operator-facing device label for alert messages.
@@ -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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.js");
7
7
  //#region src/builtins/autotrack/autotrack-config.ts
8
8
  var DEFAULT_AUTOTRACK_LOOP_CONFIG = {
9
9
  deadZoneFraction: .5,
@@ -1,4 +1,4 @@
1
- import { Ar as isEvent, S as FIRST_LEVEL_MACRO_CLASSES, X as bareAddonId, cr as errMsg, gn as ptzAutotrackCapability, lr as BaseAddon, qr as EventCategory } from "../../dist-B9oFw2jh.mjs";
1
+ import { Qr as EventCategory, S as FIRST_LEVEL_MACRO_CLASSES, X as bareAddonId, cr as errMsg, gn as ptzAutotrackCapability, jr as isEvent, lr as BaseAddon } from "../../dist-BC0GnGeg.mjs";
2
2
  //#region src/builtins/autotrack/autotrack-config.ts
3
3
  var DEFAULT_AUTOTRACK_LOOP_CONFIG = {
4
4
  deadZoneFraction: .5,
@@ -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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.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 { Gr as toNodeId, In as storageOccupancyCapability, Mr as nodePin, Y as backupCapability, g as DATABASE_SNAPSHOT_SUFFIX, lr as BaseAddon, nn as mayWriteToLocation, qr as EventCategory } from "../../dist-B9oFw2jh.mjs";
1
+ import { In as storageOccupancyCapability, Ir as nodePin, Qr as EventCategory, Y as backupCapability, Yr as toNodeId, g as DATABASE_SNAPSHOT_SUFFIX, lr as BaseAddon, nn as mayWriteToLocation } from "../../dist-BC0GnGeg.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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.js");
7
7
  const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
8
8
  let zod = require("zod");
9
9
  //#region src/builtins/calendars/calendar-color.ts
@@ -1,4 +1,4 @@
1
- import { et as calendarsCapability, lr as BaseAddon, p as CalendarPreferencesSchema } from "../../dist-B9oFw2jh.mjs";
1
+ import { et as calendarsCapability, lr as BaseAddon, p as CalendarPreferencesSchema } from "../../dist-BC0GnGeg.mjs";
2
2
  import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
3
3
  import { z } from "zod";
4
4
  //#region src/builtins/calendars/calendar-color.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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.js");
7
7
  let zod = require("zod");
8
8
  let _camstack_types_node = require("@camstack/types/node");
9
9
  let node_path = require("node:path");
@@ -1,4 +1,4 @@
1
- import { Cr as createEvent, Jn as buildFfmpegArgs, M as MOTION_CLOSE_AFTER_MS, Nn as snapshotCapability, Or as hydrateSchema, Rn as streamCatalogCapability, ar as DeviceFeature, b as DeclaredDevices, cr as errMsg, i as BaseDevice, lr as BaseAddon, mt as declarationOwnerNodeId, on as motionCapability, qr as EventCategory, rn as memoizePinnedFfmpeg, sr as DeviceType, tt as cameraGridLayoutCapability, y as DERIVED_CAMERA_SILENCED_CAP_NAMES } from "../../dist-B9oFw2jh.mjs";
1
+ import { Jn as buildFfmpegArgs, M as MOTION_CLOSE_AFTER_MS, Nn as snapshotCapability, Qr as EventCategory, Rn as streamCatalogCapability, ar as DeviceFeature, b as DeclaredDevices, cr as errMsg, i as BaseDevice, kr as hydrateSchema, lr as BaseAddon, mt as declarationOwnerNodeId, on as motionCapability, rn as memoizePinnedFfmpeg, sr as DeviceType, tt as cameraGridLayoutCapability, wr as createEvent, y as DERIVED_CAMERA_SILENCED_CAP_NAMES } from "../../dist-BC0GnGeg.mjs";
2
2
  import { z } from "zod";
3
3
  import { FfmpegProcess } from "@camstack/types/node";
4
4
  import { join } 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-Cc6KOdY-.js");
7
- const require_composition_sources = require("../../composition-sources-CHvLMrFI.js");
6
+ const require_dist = require("../../dist-BugrtARh.js");
7
+ const require_composition_sources = require("../../composition-sources-4SmsP0O4.js");
8
8
  let zod = require("zod");
9
9
  //#region src/builtins/shared/device-state-changed.ts
10
10
  /** Structural narrowing helper for untrusted bus payloads. */
@@ -1,5 +1,5 @@
1
- import { $n as compositionItemFieldPath, Cr as createEvent, Et as evaluateCompositionField, Q as buildCapabilityLookup, Qn as compositionFeatureEnabled, Xn as composedDeviceRef, Yn as cloneStatefulExpressionMemory, Zn as composedDeviceStableId, b as DeclaredDevices, cr as errMsg, er as compositionSliceKey, i as BaseDevice, ir as toExpressionValue, it as compositionFieldKey, kt as expressionContainsBuiltinCall, l as COMPOSED_ITEM_FIXED_FIELDS, lr as BaseAddon, nr as createStatefulExpressionMemory, pn as planComposition, qn as COMPOSER_ADDON_ID, qr as EventCategory, rr as disarmRoseMemory, rt as composerCapability, sr as DeviceType, t as ALL_CAPABILITY_DEFINITIONS, tr as compositionSourceKey } from "../../dist-B9oFw2jh.mjs";
2
- import { n as normalizedNativeOwner } from "../../composition-sources-DT_uJwI3.mjs";
1
+ import { $n as compositionItemFieldPath, Et as evaluateCompositionField, Q as buildCapabilityLookup, Qn as compositionFeatureEnabled, Qr as EventCategory, Xn as composedDeviceRef, Yn as cloneStatefulExpressionMemory, Zn as composedDeviceStableId, b as DeclaredDevices, cr as errMsg, er as compositionSliceKey, i as BaseDevice, ir as toExpressionValue, it as compositionFieldKey, kt as expressionContainsBuiltinCall, l as COMPOSED_ITEM_FIXED_FIELDS, lr as BaseAddon, nr as createStatefulExpressionMemory, pn as planComposition, qn as COMPOSER_ADDON_ID, rr as disarmRoseMemory, rt as composerCapability, sr as DeviceType, t as ALL_CAPABILITY_DEFINITIONS, tr as compositionSourceKey, wr as createEvent } from "../../dist-BC0GnGeg.mjs";
2
+ import { n as normalizedNativeOwner } from "../../composition-sources-CgOQVIwa.mjs";
3
3
  import { z } from "zod";
4
4
  //#region src/builtins/shared/device-state-changed.ts
5
5
  /** Structural narrowing helper for untrusted bus payloads. */
@@ -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-Cc6KOdY-.js");
6
+ const require_dist = require("../../dist-BugrtARh.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 { Zt as logDestinationCapability, lr as BaseAddon } from "../../dist-B9oFw2jh.mjs";
1
+ import { Zt as logDestinationCapability, lr as BaseAddon } from "../../dist-BC0GnGeg.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,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_chunk = require("../../chunk-Cek0wNdY.js");
3
- const require_dist = require("../../dist-Cc6KOdY-.js");
4
- const require_composition_sources = require("../../composition-sources-CHvLMrFI.js");
3
+ const require_dist = require("../../dist-BugrtARh.js");
4
+ const require_composition_sources = require("../../composition-sources-4SmsP0O4.js");
5
5
  let node_crypto = require("node:crypto");
6
6
  let _camstack_types_node = require("@camstack/types/node");
7
7
  let node_fs_promises = require("node:fs/promises");
@@ -1,5 +1,5 @@
1
- import { Or as hydrateSchema, Q as buildCapabilityLookup, Sn as resolveCoreBlockFiles, Vn as validateComposition, Xn as composedDeviceRef, at as compositionSourceRefs, b as DeclaredDevices, cr as errMsg, ct as coreBlockIdFromAddonId, d as CORE_BLOCKS_ADDON_ID, f as CORE_BLOCK_ADDON_PREFIX, lr as BaseAddon, lt as coreBlockSourceKind, m as CoreBlockSchema, ot as coreBlockAddonId, pn as planComposition, sn as normalizeCoreBlockWrite, st as coreBlockComposition, t as ALL_CAPABILITY_DEFINITIONS, tr as compositionSourceKey, u as COMPOSER_RUNNER_ID, ut as coreBlocksCapability, vn as replacedFieldKeys, vt as describeComposableCaps, xn as resolveCoreBlockEntry } from "../../dist-B9oFw2jh.mjs";
2
- import { t as describeCompositionSources } from "../../composition-sources-DT_uJwI3.mjs";
1
+ import { Q as buildCapabilityLookup, Sn as resolveCoreBlockFiles, Vn as validateComposition, Xn as composedDeviceRef, at as compositionSourceRefs, b as DeclaredDevices, cr as errMsg, ct as coreBlockIdFromAddonId, d as CORE_BLOCKS_ADDON_ID, f as CORE_BLOCK_ADDON_PREFIX, kr as hydrateSchema, lr as BaseAddon, lt as coreBlockSourceKind, m as CoreBlockSchema, ot as coreBlockAddonId, pn as planComposition, sn as normalizeCoreBlockWrite, st as coreBlockComposition, t as ALL_CAPABILITY_DEFINITIONS, tr as compositionSourceKey, u as COMPOSER_RUNNER_ID, ut as coreBlocksCapability, vn as replacedFieldKeys, vt as describeComposableCaps, xn as resolveCoreBlockEntry } from "../../dist-BC0GnGeg.mjs";
2
+ import { t as describeCompositionSources } from "../../composition-sources-CgOQVIwa.mjs";
3
3
  import { createRequire } from "node:module";
4
4
  import { randomUUID } from "node:crypto";
5
5
  import { customizationBlockName } from "@camstack/types/node";
@@ -12,6 +12,18 @@ export interface AggregationDeps {
12
12
  readonly capabilityRegistry: ICapabilityRegistry | undefined;
13
13
  readonly remoteNativeCaps: RemoteNativeCaps;
14
14
  readonly bindingsDeps: BindingsDeps;
15
+ /**
16
+ * The keychain side of a driver's device form (D789): the STORED blob (its
17
+ * markers, never resolved), the device's declared secret paths, and the
18
+ * door's explicit clear. Without it a driver form carries what the driver
19
+ * hydrated and a clear cannot be applied.
20
+ */
21
+ readonly deviceFormSecrets?: DeviceFormSecretsDeps;
22
+ }
23
+ export interface DeviceFormSecretsDeps {
24
+ readonly readStored: (deviceId: number) => Promise<Record<string, unknown>>;
25
+ readonly declaredPaths: (deviceId: number) => readonly string[];
26
+ readonly clear: (deviceId: number, keys: readonly string[]) => Promise<void>;
15
27
  }
16
28
  type IDeviceManagerProvider = InferProvider<typeof deviceManagerCapability>;
17
29
  export declare function getDeviceAggregate(deps: AggregationDeps, deviceId: number, kind: 'settings' | 'live'): Promise<ContributionShape | null>;
@@ -0,0 +1,25 @@
1
+ import { ContributionShape } from './device-meta-types.js';
2
+ type Sections = ContributionShape['sections'];
3
+ /**
4
+ * The driver's hydrated sections with every keychain-stored secret replaced
5
+ * by its view. Returns the input unchanged when the blob holds no marker.
6
+ */
7
+ export declare function viewStoredSecrets(sections: Sections, stored: Record<string, unknown>, declaredPaths: readonly string[]): Sections;
8
+ /** A form patch split into what the driver applies and what the door clears. */
9
+ export interface DriverFormPatch {
10
+ readonly driverPatch: Record<string, unknown>;
11
+ readonly clearKeys: readonly string[];
12
+ }
13
+ /** Split a device-settings form patch (see the module doc). */
14
+ export declare function splitDriverFormPatch(patch: Record<string, unknown>): DriverFormPatch;
15
+ /**
16
+ * Apply a device-settings form patch: the driver gets plain values only, then
17
+ * an explicit clear removes the stored secret at the keychain door (after the
18
+ * driver's own persist, whose `''` the door reads as KEEP).
19
+ */
20
+ export declare function applyDriverFormPatch(input: {
21
+ readonly patch: Record<string, unknown>;
22
+ readonly applyToDriver: (driverPatch: Record<string, unknown>) => Promise<void>;
23
+ readonly clearSecrets: (keys: readonly string[]) => Promise<void>;
24
+ }): Promise<void>;
25
+ export {};
@@ -71,6 +71,8 @@ export declare class DeviceManagerAddon extends BaseAddon {
71
71
  private readonly removalFence;
72
72
  /** Declared secret config paths per device, as last registered (D783). */
73
73
  private readonly secretConfigPaths;
74
+ /** The keychain side of driver device forms (D789), wired in onInitialize. */
75
+ private deviceFormSecrets;
74
76
  /** The runtime-state mirror, asserted present (constructed in onInitialize). */
75
77
  private get stateMirror();
76
78
  /**
@@ -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-Cc6KOdY-.js");
7
- const require_retired_settings_keys = require("../../retired-settings-keys-YOOKLA3v.js");
6
+ const require_dist = require("../../dist-BugrtARh.js");
7
+ const require_retired_settings_keys = require("../../retired-settings-keys-DCuetwOt.js");
8
8
  let zod = require("zod");
9
9
  let node_crypto = require("node:crypto");
10
10
  let _camstack_types_node = require("@camstack/types/node");
@@ -1033,6 +1033,105 @@ function mergeAggregates(parts) {
1033
1033
  return out;
1034
1034
  }
1035
1035
  //#endregion
1036
+ //#region src/builtins/device-manager/device-form-secrets.ts
1037
+ /**
1038
+ * A driver's device-settings form, kept on the keychain side of the wire
1039
+ * (D787 / D789 for device forms).
1040
+ *
1041
+ * A driver hydrates its own form from the config `loadConfig` RESOLVED for it,
1042
+ * so a camera password reaches the form as plaintext even though the stored
1043
+ * blob holds a keychain marker. This module closes that in ONE place — the
1044
+ * device-manager aggregate every device form goes through — for every driver:
1045
+ *
1046
+ * - READ ({@link viewStoredSecrets}): a form field whose key names a stored
1047
+ * MARKER (a declared `secretConfigPaths` entry, or a field secret by type)
1048
+ * is handed the marker's VIEW instead of the driver's plaintext. A value
1049
+ * that is still inline plaintext in the blob (not migrated) is left as the
1050
+ * driver hydrated it: there is nothing to reveal it by.
1051
+ * - WRITE ({@link applyDriverFormPatch}): the form sends the view back for an
1052
+ * untouched field and `{ $secretClear: true }` for an explicit clear. The
1053
+ * driver understands neither (its schema wants a string), so a view is
1054
+ * dropped from the driver's patch (KEEP — the driver still holds the
1055
+ * resolved value) and a clear reaches the driver as `''` while the stored
1056
+ * marker is removed at the keychain door. A typed value passes through and
1057
+ * the driver's own persist stores it in the keychain.
1058
+ *
1059
+ * Top-level keys only: a driver form's field key is its config key for every
1060
+ * declared device secret today (`password`, `apiKey`, `localKey`). A nested or
1061
+ * per-row path (`connection.password`, `rows[].pin`) is not mapped onto a form
1062
+ * field and keeps the driver's hydration.
1063
+ */
1064
+ function isRecord$2(value) {
1065
+ return typeof value === "object" && value !== null && !Array.isArray(value);
1066
+ }
1067
+ /** The declared paths that name a top-level config key. */
1068
+ function topLevelKeys(paths) {
1069
+ return new Set(paths.filter((p) => p.length > 0 && !p.includes(".") && !p.includes("[")));
1070
+ }
1071
+ function viewField(field, stored, declared) {
1072
+ if (!isRecord$2(field)) return field;
1073
+ const nested = field["fields"];
1074
+ if (Array.isArray(nested)) return {
1075
+ ...field,
1076
+ fields: nested.map((f) => viewField(f, stored, declared))
1077
+ };
1078
+ const tabs = field["tabs"];
1079
+ if (Array.isArray(tabs)) return {
1080
+ ...field,
1081
+ tabs: tabs.map((tab) => isRecord$2(tab) && Array.isArray(tab["fields"]) ? {
1082
+ ...tab,
1083
+ fields: tab["fields"].map((f) => viewField(f, stored, declared))
1084
+ } : tab)
1085
+ };
1086
+ const key = field["key"];
1087
+ if (typeof key !== "string" || !("value" in field)) return field;
1088
+ const marker = stored[key];
1089
+ if (!require_dist.isSecretMarker(marker)) return field;
1090
+ const secretByType = require_dist.isKeychainStoredField(field);
1091
+ if (!secretByType && !declared.has(key)) return field;
1092
+ const type = secretByType ? field["type"] : "password";
1093
+ return {
1094
+ ...field,
1095
+ type,
1096
+ value: require_dist.toSecretFieldView(marker)
1097
+ };
1098
+ }
1099
+ /**
1100
+ * The driver's hydrated sections with every keychain-stored secret replaced
1101
+ * by its view. Returns the input unchanged when the blob holds no marker.
1102
+ */
1103
+ function viewStoredSecrets(sections, stored, declaredPaths) {
1104
+ if (!Object.values(stored).some(require_dist.isSecretMarker)) return sections;
1105
+ const declared = topLevelKeys(declaredPaths);
1106
+ return sections.map((section) => ({
1107
+ ...section,
1108
+ fields: section.fields.map((f) => viewField(f, stored, declared))
1109
+ }));
1110
+ }
1111
+ /** Split a device-settings form patch (see the module doc). */
1112
+ function splitDriverFormPatch(patch) {
1113
+ const driverPatch = {};
1114
+ const clearKeys = [];
1115
+ for (const [key, value] of Object.entries(patch)) if (require_dist.isSecretClear(value)) {
1116
+ driverPatch[key] = "";
1117
+ clearKeys.push(key);
1118
+ } else if (!require_dist.isSecretMarkerLike(value)) driverPatch[key] = value;
1119
+ return {
1120
+ driverPatch,
1121
+ clearKeys
1122
+ };
1123
+ }
1124
+ /**
1125
+ * Apply a device-settings form patch: the driver gets plain values only, then
1126
+ * an explicit clear removes the stored secret at the keychain door (after the
1127
+ * driver's own persist, whose `''` the door reads as KEEP).
1128
+ */
1129
+ async function applyDriverFormPatch(input) {
1130
+ const { driverPatch, clearKeys } = splitDriverFormPatch(input.patch);
1131
+ if (Object.keys(driverPatch).length > 0) await input.applyToDriver(driverPatch);
1132
+ if (clearKeys.length > 0) await input.clearSecrets(clearKeys);
1133
+ }
1134
+ //#endregion
1036
1135
  //#region src/builtins/device-manager/stale-wrapper-activations.ts
1037
1136
  /**
1038
1137
  * A stored wrapper activation that names a cap with NO wrapper any more.
@@ -3451,6 +3550,25 @@ function refusedLinkedPicks(params) {
3451
3550
  //#endregion
3452
3551
  //#region src/builtins/device-manager/device-aggregation.ts
3453
3552
  /**
3553
+ * A driver's hydrated sections as the browser may see them: every secret the
3554
+ * keychain stores is its VIEW, never the plaintext the driver was handed by
3555
+ * `loadConfig`. An unreadable blob withholds nothing new — the non-admin
3556
+ * redaction still runs at the transport — but it is logged.
3557
+ */
3558
+ async function driverSectionsWithSecretViews(deps, deviceId, sections) {
3559
+ const door = deps.deviceFormSecrets;
3560
+ if (!door) return sections;
3561
+ try {
3562
+ return viewStoredSecrets(sections, await door.readStored(deviceId), door.declaredPaths(deviceId));
3563
+ } catch (err) {
3564
+ deps.ctx.logger.warn("device form: stored config unreadable — secret views not applied", {
3565
+ tags: { deviceId },
3566
+ meta: { error: require_dist.errMsg(err) }
3567
+ });
3568
+ return sections;
3569
+ }
3570
+ }
3571
+ /**
3454
3572
  * One process-wide cache behind every device-details fan-out.
3455
3573
  *
3456
3574
  * Module-level on purpose: the page re-polls every 2.5 s and a per-call cache
@@ -3676,16 +3794,18 @@ async function buildBaseDeviceSection(deps, deviceId) {
3676
3794
  if (!hubLocal && !nativeOwner) return null;
3677
3795
  const sections = [];
3678
3796
  const driverResult = await resolveDriverConfigSchema(deps, deviceId, hubLocal);
3679
- if (driverResult.status === "ok") for (const section of driverResult.schema.sections) sections.push({
3680
- id: section.id,
3681
- title: section.title,
3682
- tab: section.tab ?? "general",
3683
- order: section.order ?? 1,
3684
- fields: [...section.fields],
3685
- ...section.description !== void 0 ? { description: section.description } : {},
3686
- ...section.columns !== void 0 ? { columns: section.columns } : {}
3687
- });
3688
- else if (driverResult.status === "unavailable") sections.push({
3797
+ if (driverResult.status === "ok") {
3798
+ const driverSections = await driverSectionsWithSecretViews(deps, deviceId, driverResult.schema.sections);
3799
+ for (const section of driverSections) sections.push({
3800
+ id: section.id,
3801
+ title: section.title,
3802
+ tab: section.tab ?? "general",
3803
+ order: section.order ?? 1,
3804
+ fields: [...section.fields],
3805
+ ...section.description !== void 0 ? { description: section.description } : {},
3806
+ ...section.columns !== void 0 ? { columns: section.columns } : {}
3807
+ });
3808
+ } else if (driverResult.status === "unavailable") sections.push({
3689
3809
  id: "driver-settings-unavailable",
3690
3810
  title: "Driver Settings",
3691
3811
  tab: "general",
@@ -4079,19 +4199,26 @@ async function applyGroupPatch(deps, deviceId, group) {
4079
4199
  });
4080
4200
  throw new Error(`[device-manager] ${retired.join(", ")} can no longer be saved from the settings section — reload the page and use the Extensions section`);
4081
4201
  }
4082
- const driverPatch = group.patch;
4083
- if (Object.keys(driverPatch).length === 0) return;
4084
- const hubRegistry = deps.ctx.kernel?.deviceRegistry;
4085
- const found = hubRegistry ? resolveDeviceById(hubRegistry, deviceId) : null;
4086
- if (found) {
4087
- await found.device.applySettingsPatch(driverPatch);
4088
- return;
4089
- }
4090
- const ops = deps.capabilityRegistry?.getNativeProvider("device-ops", deviceId);
4091
- if (!ops) throw new Error(`[device-manager] device "${deviceId}" not found (no hub-local entry, no device-ops native provider)`);
4092
- await ops.setConfig({
4093
- deviceId,
4094
- values: driverPatch
4202
+ await applyDriverFormPatch({
4203
+ patch: group.patch,
4204
+ applyToDriver: async (driverPatch) => {
4205
+ const hubRegistry = deps.ctx.kernel?.deviceRegistry;
4206
+ const found = hubRegistry ? resolveDeviceById(hubRegistry, deviceId) : null;
4207
+ if (found) {
4208
+ await found.device.applySettingsPatch(driverPatch);
4209
+ return;
4210
+ }
4211
+ const ops = deps.capabilityRegistry?.getNativeProvider("device-ops", deviceId);
4212
+ if (!ops) throw new Error(`[device-manager] device "${deviceId}" not found (no hub-local entry, no device-ops native provider)`);
4213
+ await ops.setConfig({
4214
+ deviceId,
4215
+ values: driverPatch
4216
+ });
4217
+ },
4218
+ clearSecrets: async (keys) => {
4219
+ if (!deps.deviceFormSecrets) throw new Error(`[device-manager] cannot clear ${keys.join(", ")}: no keychain door`);
4220
+ await deps.deviceFormSecrets.clear(deviceId, keys);
4221
+ }
4095
4222
  });
4096
4223
  return;
4097
4224
  }
@@ -9717,6 +9844,8 @@ var DeviceManagerAddon = class extends require_dist.BaseAddon {
9717
9844
  removalFence = createRemovalFence();
9718
9845
  /** Declared secret config paths per device, as last registered (D783). */
9719
9846
  secretConfigPaths = createSecretConfigPathRegistry();
9847
+ /** The keychain side of driver device forms (D789), wired in onInitialize. */
9848
+ deviceFormSecrets;
9720
9849
  /** The runtime-state mirror, asserted present (constructed in onInitialize). */
9721
9850
  get stateMirror() {
9722
9851
  if (!this.stateMirrorImpl) throw new Error("DeviceManagerAddon: state mirror accessed before onInitialize");
@@ -9869,7 +9998,8 @@ var DeviceManagerAddon = class extends require_dist.BaseAddon {
9869
9998
  ctx: this.ctx,
9870
9999
  capabilityRegistry: this.capabilityRegistry,
9871
10000
  remoteNativeCaps: this.remoteNativeCaps,
9872
- bindingsDeps: this.bindingsDeps
10001
+ bindingsDeps: this.bindingsDeps,
10002
+ ...this.deviceFormSecrets ? { deviceFormSecrets: this.deviceFormSecrets } : {}
9873
10003
  };
9874
10004
  }
9875
10005
  async getDeviceAggregate(deviceId, kind) {
@@ -9965,6 +10095,15 @@ var DeviceManagerAddon = class extends require_dist.BaseAddon {
9965
10095
  return provider;
9966
10096
  }
9967
10097
  };
10098
+ this.deviceFormSecrets = {
10099
+ readStored: (deviceId) => settings.readDeviceStore(deviceId),
10100
+ declaredPaths: (deviceId) => this.secretConfigPaths.get(deviceId) ?? [],
10101
+ clear: (deviceId, keys) => persistConfig(pctx, {
10102
+ deviceId,
10103
+ data: Object.fromEntries(keys.map((key) => [key, require_dist.SECRET_CLEAR])),
10104
+ secretConfigPaths: [...new Set([...this.secretConfigPaths.get(deviceId) ?? [], ...keys])]
10105
+ })
10106
+ };
9968
10107
  try {
9969
10108
  await runLocationBackfillAtBoot(pctx, bootRows);
9970
10109
  } catch (err) {