infracensus-collector 1.6.63 → 1.6.65
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/a10-index.js +3 -3
- package/dist/{archive-I5B3BHJ6.js → archive-TH3ZNWXA.js} +3 -3
- package/dist/aws-index.js +16 -10
- package/dist/aws-index.js.map +1 -1
- package/dist/azure-index.js +14 -10
- package/dist/azure-index.js.map +1 -1
- package/dist/{chunk-UWHPNJX3.js → chunk-2AKCDNDQ.js} +14 -1
- package/dist/{chunk-UWHPNJX3.js.map → chunk-2AKCDNDQ.js.map} +2 -2
- package/dist/{chunk-HTKYWRZP.js → chunk-33I2MPFG.js} +349 -49
- package/dist/chunk-33I2MPFG.js.map +7 -0
- package/dist/{chunk-XHO3HSOG.js → chunk-3ALCM7G2.js} +5 -5
- package/dist/{chunk-C7XGFC3T.js → chunk-4JPAK3PE.js} +2 -2
- package/dist/chunk-72CJXXQK.js +465 -0
- package/dist/chunk-72CJXXQK.js.map +7 -0
- package/dist/{chunk-MGTF35XJ.js → chunk-7VTCVVVW.js} +2 -2
- package/dist/{chunk-UCP3GI6J.js → chunk-AJFG522Q.js} +3 -3
- package/dist/chunk-B6QF53HK.js +1084 -0
- package/dist/chunk-B6QF53HK.js.map +7 -0
- package/dist/{chunk-6T3ZO6RX.js → chunk-BHXFCBES.js} +3 -3
- package/dist/{chunk-TZJK3G7Q.js → chunk-CWCMOYPY.js} +2 -2
- package/dist/{chunk-YJUZC3OZ.js → chunk-ENRRKIRL.js} +4 -3
- package/dist/chunk-ENRRKIRL.js.map +7 -0
- package/dist/{chunk-AWBQTJZ2.js → chunk-FGJTAVLY.js} +64 -1799
- package/dist/chunk-FGJTAVLY.js.map +7 -0
- package/dist/{chunk-XTYV6K3I.js → chunk-FQF2RQKB.js} +142 -28
- package/dist/chunk-FQF2RQKB.js.map +7 -0
- package/dist/{chunk-TJCOBEME.js → chunk-GNLX2XVF.js} +27 -11
- package/dist/{chunk-TJCOBEME.js.map → chunk-GNLX2XVF.js.map} +3 -3
- package/dist/{chunk-KNWEBW4V.js → chunk-HTYGFJHP.js} +30 -5
- package/dist/chunk-HTYGFJHP.js.map +7 -0
- package/dist/{chunk-FZ3FCAXP.js → chunk-HUK4PPTF.js} +371 -724
- package/dist/chunk-HUK4PPTF.js.map +7 -0
- package/dist/{chunk-TZAAYAVS.js → chunk-HZA52DVI.js} +8 -6
- package/dist/{chunk-TZAAYAVS.js.map → chunk-HZA52DVI.js.map} +2 -2
- package/dist/{chunk-SMBYVIRD.js → chunk-IF6IWPO4.js} +202 -18
- package/dist/chunk-IF6IWPO4.js.map +7 -0
- package/dist/{chunk-2K56PIY5.js → chunk-IKNNKWHQ.js} +2 -2
- package/dist/chunk-IVDM47JP.js +64 -0
- package/dist/chunk-IVDM47JP.js.map +7 -0
- package/dist/chunk-J7DL4WOM.js +89 -0
- package/dist/chunk-J7DL4WOM.js.map +7 -0
- package/dist/{chunk-MNHWQDK5.js → chunk-JM6HQQ5I.js} +2 -2
- package/dist/chunk-LNX3G2LA.js +2012 -0
- package/dist/chunk-LNX3G2LA.js.map +7 -0
- package/dist/{chunk-2FDBXEX4.js → chunk-M3H7ASCA.js} +4 -4
- package/dist/chunk-M6WFVXNV.js +1285 -0
- package/dist/chunk-M6WFVXNV.js.map +7 -0
- package/dist/{chunk-Q5LJMRDH.js → chunk-NHBSR3KA.js} +6 -2
- package/dist/chunk-NHBSR3KA.js.map +7 -0
- package/dist/chunk-SRJBTS4B.js +718 -0
- package/dist/chunk-SRJBTS4B.js.map +7 -0
- package/dist/{chunk-ICXOPST5.js → chunk-UD3EQMFY.js} +7 -7
- package/dist/{chunk-XWMNCXEN.js → chunk-URPLLWPH.js} +3 -3
- package/dist/{chunk-WXF6IZHC.js → chunk-VD7KJ32O.js} +52 -14
- package/dist/chunk-VD7KJ32O.js.map +7 -0
- package/dist/{chunk-7A55BHQ6.js → chunk-WANORD6H.js} +164 -19
- package/dist/chunk-WANORD6H.js.map +7 -0
- package/dist/{chunk-MMCMGFMN.js → chunk-XQKPLPUI.js} +2 -2
- package/dist/{chunk-O7LUC73D.js → chunk-XU3TIZM6.js} +3 -3
- package/dist/{chunk-3PAI2EV6.js → chunk-ZD6JFAF3.js} +7 -7
- package/dist/{chunk-NZ7LI65I.js → chunk-ZOGPCD5O.js} +58 -4
- package/dist/{chunk-NZ7LI65I.js.map → chunk-ZOGPCD5O.js.map} +2 -2
- package/dist/cli.js +9 -9
- package/dist/{config-5TR73FPJ.js → config-VRESOMLH.js} +3 -3
- package/dist/configimport-index.js +4 -4
- package/dist/gcp-index.js +17 -11
- package/dist/gcp-index.js.map +1 -1
- package/dist/hyperv-index.js +6 -6
- package/dist/identity-index.js +12 -10
- package/dist/identity-index.js.map +1 -1
- package/dist/index.js +258 -44
- package/dist/index.js.map +4 -4
- package/dist/kubernetes-index.js +184 -0
- package/dist/kubernetes-index.js.map +7 -0
- package/dist/{ocr-QHZQMHQH.js → ocr-WYDE54N7.js} +4 -4
- package/dist/sdd-classify-worker-index.js +3 -3
- package/dist/sensitive-data-index.js +19 -15
- package/dist/sensitive-data-index.js.map +1 -1
- package/dist/smb-shares-index.js +18 -14
- package/dist/smb-shares-index.js.map +1 -1
- package/dist/sql-index.js +6 -6
- package/dist/{status-RE2DQUPP.js → status-WSF3TZYV.js} +8 -8
- package/dist/vmware-index.js +6 -6
- package/dist/voice-index.js +6 -6
- package/package.json +99 -98
- package/dist/chunk-7A55BHQ6.js.map +0 -7
- package/dist/chunk-AWBQTJZ2.js.map +0 -7
- package/dist/chunk-FZ3FCAXP.js.map +0 -7
- package/dist/chunk-HTKYWRZP.js.map +0 -7
- package/dist/chunk-KNWEBW4V.js.map +0 -7
- package/dist/chunk-Q5LJMRDH.js.map +0 -7
- package/dist/chunk-SMBYVIRD.js.map +0 -7
- package/dist/chunk-WXF6IZHC.js.map +0 -7
- package/dist/chunk-XTYV6K3I.js.map +0 -7
- package/dist/chunk-YJUZC3OZ.js.map +0 -7
- /package/dist/{archive-I5B3BHJ6.js.map → archive-TH3ZNWXA.js.map} +0 -0
- /package/dist/{chunk-XHO3HSOG.js.map → chunk-3ALCM7G2.js.map} +0 -0
- /package/dist/{chunk-C7XGFC3T.js.map → chunk-4JPAK3PE.js.map} +0 -0
- /package/dist/{chunk-MGTF35XJ.js.map → chunk-7VTCVVVW.js.map} +0 -0
- /package/dist/{chunk-UCP3GI6J.js.map → chunk-AJFG522Q.js.map} +0 -0
- /package/dist/{chunk-6T3ZO6RX.js.map → chunk-BHXFCBES.js.map} +0 -0
- /package/dist/{chunk-TZJK3G7Q.js.map → chunk-CWCMOYPY.js.map} +0 -0
- /package/dist/{chunk-2K56PIY5.js.map → chunk-IKNNKWHQ.js.map} +0 -0
- /package/dist/{chunk-MNHWQDK5.js.map → chunk-JM6HQQ5I.js.map} +0 -0
- /package/dist/{chunk-2FDBXEX4.js.map → chunk-M3H7ASCA.js.map} +0 -0
- /package/dist/{chunk-ICXOPST5.js.map → chunk-UD3EQMFY.js.map} +0 -0
- /package/dist/{chunk-XWMNCXEN.js.map → chunk-URPLLWPH.js.map} +0 -0
- /package/dist/{chunk-MMCMGFMN.js.map → chunk-XQKPLPUI.js.map} +0 -0
- /package/dist/{chunk-O7LUC73D.js.map → chunk-XU3TIZM6.js.map} +0 -0
- /package/dist/{chunk-3PAI2EV6.js.map → chunk-ZD6JFAF3.js.map} +0 -0
- /package/dist/{config-5TR73FPJ.js.map → config-VRESOMLH.js.map} +0 -0
- /package/dist/{ocr-QHZQMHQH.js.map → ocr-WYDE54N7.js.map} +0 -0
- /package/dist/{status-RE2DQUPP.js.map → status-WSF3TZYV.js.map} +0 -0
package/dist/a10-index.js
CHANGED
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
} from "./chunk-2CKQ2AXQ.js";
|
|
5
5
|
import {
|
|
6
6
|
requireEntitlementToScan
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-URPLLWPH.js";
|
|
8
|
+
import "./chunk-ZOGPCD5O.js";
|
|
9
9
|
import {
|
|
10
10
|
ROUTES
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-FQF2RQKB.js";
|
|
12
12
|
|
|
13
13
|
// src/a10-index.ts
|
|
14
14
|
var LEVEL_RANK = { debug: 10, info: 20, warn: 30, error: 40 };
|
|
@@ -2,12 +2,12 @@ import {
|
|
|
2
2
|
extensionKind,
|
|
3
3
|
extractOpenXml,
|
|
4
4
|
extractPlainText
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-WANORD6H.js";
|
|
6
6
|
import {
|
|
7
7
|
checkEntryPath,
|
|
8
8
|
checkEntrySize
|
|
9
9
|
} from "./chunk-PTGS7JVX.js";
|
|
10
|
-
import "./chunk-
|
|
10
|
+
import "./chunk-FQF2RQKB.js";
|
|
11
11
|
|
|
12
12
|
// src/sensitiveData/archive.ts
|
|
13
13
|
import { unzipSync } from "fflate";
|
|
@@ -68,4 +68,4 @@ function extractArchive(bytes) {
|
|
|
68
68
|
export {
|
|
69
69
|
extractArchive
|
|
70
70
|
};
|
|
71
|
-
//# sourceMappingURL=archive-
|
|
71
|
+
//# sourceMappingURL=archive-TH3ZNWXA.js.map
|
package/dist/aws-index.js
CHANGED
|
@@ -3,36 +3,42 @@ import {
|
|
|
3
3
|
awsWithCost,
|
|
4
4
|
describeAwsRun,
|
|
5
5
|
runAwsAccount
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-HUK4PPTF.js";
|
|
7
|
+
import "./chunk-M6WFVXNV.js";
|
|
8
|
+
import "./chunk-J7DL4WOM.js";
|
|
9
|
+
import "./chunk-SRJBTS4B.js";
|
|
10
|
+
import "./chunk-B6QF53HK.js";
|
|
7
11
|
import {
|
|
8
12
|
AWS_PERMISSIONS,
|
|
9
13
|
AWS_PERMISSION_NOTES,
|
|
10
14
|
AWS_RECOMMENDED_POLICY
|
|
11
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-HTYGFJHP.js";
|
|
16
|
+
import "./chunk-72CJXXQK.js";
|
|
12
17
|
import {
|
|
13
18
|
openVault
|
|
14
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-NHBSR3KA.js";
|
|
15
20
|
import "./chunk-BPIFQYJR.js";
|
|
16
21
|
import "./chunk-PTGS7JVX.js";
|
|
17
|
-
import "./chunk-
|
|
22
|
+
import "./chunk-FGJTAVLY.js";
|
|
18
23
|
import "./chunk-YEOXVIEZ.js";
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-LNX3G2LA.js";
|
|
25
|
+
import "./chunk-JM6HQQ5I.js";
|
|
26
|
+
import "./chunk-AJFG522Q.js";
|
|
21
27
|
import "./chunk-URNQQQIZ.js";
|
|
22
|
-
import "./chunk-
|
|
28
|
+
import "./chunk-ENRRKIRL.js";
|
|
23
29
|
import {
|
|
24
30
|
collectorOwnsModule,
|
|
25
31
|
requireEntitlementToScan
|
|
26
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-URPLLWPH.js";
|
|
27
33
|
import {
|
|
28
34
|
FileConfig,
|
|
29
35
|
configFilePath,
|
|
30
36
|
stateDir,
|
|
31
37
|
vaultSettings
|
|
32
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-ZOGPCD5O.js";
|
|
33
39
|
import {
|
|
34
40
|
VaultProtection
|
|
35
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-FQF2RQKB.js";
|
|
36
42
|
|
|
37
43
|
// src/aws-index.ts
|
|
38
44
|
import { existsSync, readFileSync } from "node:fs";
|
package/dist/aws-index.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/aws-index.ts"],
|
|
4
4
|
"sourcesContent": ["/**\r\n * AWS Cloud Posture collector CLI entry point (docs/design/cloud-aws-gcp.md \u00A74.1).\r\n *\r\n * netdoc-collector scan aws read the account behind this\r\n * collector's aws credential set\r\n * and push it to /ingest/aws\r\n * tsx src/aws-index.ts --dry-run read and summarize, push nothing\r\n * tsx src/aws-index.ts --set \"<name>\" use the named aws set (default:\r\n * every aws set in the vault, one\r\n * account each)\r\n * tsx src/aws-index.ts --print-permissions print the read-only policy and exit\r\n *\r\n * \u2500\u2500 THE VAULT IS THE ONLY CREDENTIAL SOURCE \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\r\n *\r\n * Unlike azure-index.ts there is no AWS_* environment fallback, and that is the\r\n * design (\u00A714 D1): the AWS SDK's credential chain \u2014 environment, ~/.aws,\r\n * instance metadata \u2014 is exactly how a scan ends up using a credential nobody\r\n * gave InfraCensus. This entry reads the collector's own vault and nothing else.\r\n *\r\n * Ctrl-C (SIGINT) triggers a cooperative AbortSignal so in-flight requests stop.\r\n */\r\nimport { existsSync, readFileSync } from \"node:fs\";\r\nimport {\r\n AWS_PERMISSIONS,\r\n AWS_PERMISSION_NOTES,\r\n AWS_RECOMMENDED_POLICY,\r\n VaultProtection,\r\n} from \"@netdoc/collector-contract\";\r\nimport { FileConfig, configFilePath, stateDir, vaultSettings } from \"./config.js\";\r\nimport type { Logger } from \"./core/runner.js\";\r\nimport { requireEntitlementToScan, collectorOwnsModule } from \"./entitlement/index.js\";\r\nimport { openVault } from \"./vault/store.js\";\r\nimport { awsCredentialFromCloud, awsWithCost, describeAwsRun, runAwsAccount, type AwsCredentialInput } from \"./aws/run.js\";\r\n\r\nconst LEVEL_RANK = { debug: 10, info: 20, warn: 30, error: 40 } as const;\r\n\r\nfunction makeLogger(minLevel: keyof typeof LEVEL_RANK = \"info\"): Logger {\r\n const min = LEVEL_RANK[minLevel];\r\n return (level, msg, meta) => {\r\n if (LEVEL_RANK[level] < min) return;\r\n const line = `${new Date().toISOString()} ${level.toUpperCase().padEnd(5)} ${msg}`;\r\n const out = level === \"error\" ? console.error : level === \"warn\" ? console.warn : console.log;\r\n if (meta !== undefined) out(line, meta);\r\n else out(line);\r\n };\r\n}\r\n\r\nfunction errMsg(err: unknown): string {\r\n return err instanceof Error ? err.message : String(err);\r\n}\r\n\r\nfunction printPermissions(): void {\r\n console.log(\"AWS \u2014 recommended customer-managed policy (read-only):\\n\");\r\n console.log(JSON.stringify(AWS_RECOMMENDED_POLICY, null, 2));\r\n console.log(\"\\nWhat each action is for:\");\r\n for (const r of AWS_PERMISSIONS) console.log(` ${r.action.padEnd(46)} ${r.why}`);\r\n console.log(\"\");\r\n for (const n of AWS_PERMISSION_NOTES) console.log(`- ${n}`);\r\n}\r\n\r\n/** The enrolment this one-shot run reports as: environment first, then the config file. */\r\nfunction loadTenancy(): { controlPlaneUrl?: string; apiKey?: string; tenantId?: string; collectorId?: string } {\r\n const env = process.env;\r\n let file: Record<string, unknown> = {};\r\n const path = configFilePath(env);\r\n if (existsSync(path)) {\r\n const parsed = FileConfig.safeParse(JSON.parse(readFileSync(path, \"utf8\")));\r\n if (!parsed.success) throw new Error(`Failed to read config file \"${path}\": ${parsed.error.issues[0]?.message ?? \"invalid\"}`);\r\n file = parsed.data as Record<string, unknown>;\r\n }\r\n const pick = (envValue: string | undefined, key: string): string | undefined =>\r\n envValue ?? (typeof file[key] === \"string\" ? (file[key] as string) : undefined);\r\n return {\r\n controlPlaneUrl: pick(env.CONTROL_PLANE_URL, \"controlPlaneUrl\"),\r\n apiKey: pick(env.COLLECTOR_API_KEY, \"apiKey\"),\r\n tenantId: pick(env.TENANT_ID, \"tenantId\"),\r\n collectorId: pick(env.COLLECTOR_ID, \"collectorId\"),\r\n };\r\n}\r\n\r\n/** Every usable aws set in this host's vault (or the one named), as signing material. Names only are logged. */\r\nasync function awsSetsFromVault(log: Logger, onlyName: string | null): Promise<{ name: string; credential: AwsCredentialInput }[]> {\r\n const settings = vaultSettings(process.env);\r\n if (!existsSync(settings.vaultPath)) {\r\n throw new Error(\r\n `no credential vault at ${settings.vaultPath}. Add an \"AWS (access key, optional role)\" credential set ` +\r\n \"in the collector console (Credentials tab) and run this again.\",\r\n );\r\n }\r\n const forced = VaultProtection.safeParse(settings.vaultProtection);\r\n const { vault } = await openVault({\r\n path: settings.vaultPath,\r\n passphrase: settings.vaultPassphrase,\r\n forceProtection: forced.success ? forced.data : null,\r\n log,\r\n });\r\n const out: { name: string; credential: AwsCredentialInput }[] = [];\r\n for (const view of vault.list()) {\r\n if (view.kind !== \"aws\") continue;\r\n if (onlyName !== null && view.name !== onlyName) continue;\r\n const match = await vault.matchForScan({ id: view.id, kind: \"aws\" });\r\n if (!match.found) {\r\n log(\"warn\", `AWS: credential set \"${view.name}\" holds no access key and was skipped`);\r\n continue;\r\n }\r\n const d = match.set.secret.domain;\r\n const credential = awsCredentialFromCloud({\r\n awsAccessKeyId: d?.awsAccessKeyId,\r\n awsSecretAccessKey: d?.awsSecretAccessKey,\r\n awsRoleArn: d?.awsRoleArn,\r\n awsExternalId: d?.awsExternalId,\r\n });\r\n if (credential) out.push({ name: view.name, credential });\r\n }\r\n if (out.length === 0) {\r\n throw new Error(\r\n onlyName !== null\r\n ? `this collector's vault holds no usable aws credential set named \"${onlyName}\".`\r\n : 'this collector\\'s vault holds no usable aws credential set. Add one in the collector console (Credentials tab, kind \"AWS (access key, optional role)\").',\r\n );\r\n }\r\n return out;\r\n}\r\n\r\nasync function main(): Promise<void> {\r\n const argv = process.argv.slice(2);\r\n if (argv.includes(\"--print-permissions\")) {\r\n printPermissions();\r\n return;\r\n }\r\n const dryRun = argv.includes(\"--dry-run\");\r\n const debug = argv.includes(\"--debug\") || process.env.LOG_LEVEL === \"debug\";\r\n const setAt = argv.indexOf(\"--set\");\r\n const onlyName = setAt >= 0 ? (argv[setAt + 1] ?? null) : null;\r\n const log = makeLogger(debug ? \"debug\" : \"info\");\r\n\r\n const config = loadTenancy();\r\n\r\n // \u2500\u2500 PAID-LICENCE GATE \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\r\n // Before the vault is opened for a key and before any request reaches AWS.\r\n // A dry run is gated too: it still signs in to the customer's account and\r\n // reads it; it merely declines to upload.\r\n await requireEntitlementToScan(config, log, \"the one-shot AWS Cloud Posture scan\");\r\n if (!collectorOwnsModule(\"aws\")) {\r\n throw new Error(\"this tenant's plan does not include AWS Cloud Posture; nothing was read.\");\r\n }\r\n\r\n const controller = new AbortController();\r\n const onSigint = (): void => {\r\n log(\"warn\", \"SIGINT received \u2014 shutting down\u2026\");\r\n controller.abort();\r\n };\r\n process.on(\"SIGINT\", onSigint);\r\n\r\n try {\r\n const sets = await awsSetsFromVault(log, onlyName);\r\n // Held AND not turned off by the operator (NETDOC_COST_OPTIMIZATION=0), as Azure and GCP.\r\n const withCost = awsWithCost();\r\n const failures: string[] = [];\r\n let delivered = 0;\r\n for (const set of sets) {\r\n if (controller.signal.aborted) break;\r\n log(\"info\", `AWS Cloud Posture: credential set \"${set.name}\" (dryRun=${dryRun})`);\r\n try {\r\n const result = await runAwsAccount({\r\n credential: set.credential,\r\n push: dryRun ? null : { controlPlaneUrl: config.controlPlaneUrl ?? \"\", apiKey: config.apiKey ?? \"\" },\r\n log,\r\n signal: controller.signal,\r\n withCost,\r\n stateDirectory: stateDir(),\r\n });\r\n delivered += 1;\r\n log(\"info\", `${dryRun ? \"=== DRY RUN \u2014 nothing pushed === \" : \"=== PUSH OK === \"}${describeAwsRun(result)}`);\r\n } catch (err) {\r\n if (controller.signal.aborted) throw err;\r\n failures.push(`\"${set.name}\": ${errMsg(err)}`);\r\n log(\"warn\", `AWS: credential set \"${set.name}\" was not read \u2014 ${errMsg(err)}`);\r\n }\r\n }\r\n // One account's failure does not end the run: it fails only when NOTHING\r\n // could be delivered (collector-standard \u00A73); otherwise the accounts not\r\n // read are named and the ones delivered stand.\r\n if (failures.length > 0 && delivered === 0) {\r\n throw new Error(`AWS: none of ${sets.length} account(s) could be read: ${failures.join(\" | \")}`);\r\n }\r\n if (failures.length > 0) {\r\n log(\"warn\", `AWS: ${delivered} of ${sets.length} account(s) delivered; not read: ${failures.join(\" | \")}`);\r\n }\r\n } finally {\r\n process.off(\"SIGINT\", onSigint);\r\n }\r\n}\r\n\r\nmain().catch((err) => {\r\n console.error(`${new Date().toISOString()} ERROR ${errMsg(err)}`);\r\n process.exitCode = 1;\r\n});\r\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,SAAS,YAAY,oBAAoB;AAazC,IAAM,aAAa,EAAE,OAAO,IAAI,MAAM,IAAI,MAAM,IAAI,OAAO,GAAG;AAE9D,SAAS,WAAW,WAAoC,QAAgB;AACtE,QAAM,MAAM,WAAW,QAAQ;AAC/B,SAAO,CAAC,OAAO,KAAK,SAAS;AAC3B,QAAI,WAAW,KAAK,IAAI,IAAK;AAC7B,UAAM,OAAO,IAAG,oBAAI,KAAK,GAAE,YAAY,CAAC,IAAI,MAAM,YAAY,EAAE,OAAO,CAAC,CAAC,IAAI,GAAG;AAChF,UAAM,MAAM,UAAU,UAAU,QAAQ,QAAQ,UAAU,SAAS,QAAQ,OAAO,QAAQ;AAC1F,QAAI,SAAS,OAAW,KAAI,MAAM,IAAI;AAAA,QACjC,KAAI,IAAI;AAAA,EACf;AACF;AAEA,SAAS,OAAO,KAAsB;AACpC,SAAO,eAAe,QAAQ,IAAI,UAAU,OAAO,GAAG;AACxD;AAEA,SAAS,mBAAyB;AAChC,UAAQ,IAAI,+DAA0D;AACtE,UAAQ,IAAI,KAAK,UAAU,wBAAwB,MAAM,CAAC,CAAC;AAC3D,UA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AA,IAC3G;AAAA,EACF,UAAE;AACA,YAAQ,IAAI,UAAU,QAAQ;AAAA,EAChC;AACF;AAEA,KAAK,EAAE,MAAM,CAAC,QAAQ;AACpB,UAAQ,MAAM,IAAG,oBAAI,KAAK,GAAE,YAAY,CAAC,UAAU,OAAO,GAAG,CAAC,EAAE;AAChE,UAAQ,WAAW;AACrB,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/azure-index.js
CHANGED
|
@@ -2,28 +2,32 @@ import {
|
|
|
2
2
|
buildAzureInventory,
|
|
3
3
|
listAccessibleSubscriptions,
|
|
4
4
|
runAzureMonitoringCoverage
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-IF6IWPO4.js";
|
|
6
|
+
import "./chunk-SRJBTS4B.js";
|
|
7
|
+
import "./chunk-XU3TIZM6.js";
|
|
8
|
+
import "./chunk-HTYGFJHP.js";
|
|
9
|
+
import "./chunk-72CJXXQK.js";
|
|
7
10
|
import "./chunk-4ARXQ6VD.js";
|
|
8
11
|
import {
|
|
9
12
|
ArmClient,
|
|
10
13
|
runCostAfterAzure
|
|
11
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-FGJTAVLY.js";
|
|
12
15
|
import "./chunk-YEOXVIEZ.js";
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-LNX3G2LA.js";
|
|
17
|
+
import "./chunk-JM6HQQ5I.js";
|
|
18
|
+
import "./chunk-AJFG522Q.js";
|
|
15
19
|
import "./chunk-URNQQQIZ.js";
|
|
16
20
|
import {
|
|
17
21
|
pushAzureInventory
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
22
|
+
} from "./chunk-3ALCM7G2.js";
|
|
23
|
+
import "./chunk-ENRRKIRL.js";
|
|
20
24
|
import {
|
|
21
25
|
requireEntitlementToScan
|
|
22
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-URPLLWPH.js";
|
|
23
27
|
import {
|
|
24
28
|
loadAzureConfig
|
|
25
|
-
} from "./chunk-
|
|
26
|
-
import "./chunk-
|
|
29
|
+
} from "./chunk-ZOGPCD5O.js";
|
|
30
|
+
import "./chunk-FQF2RQKB.js";
|
|
27
31
|
|
|
28
32
|
// src/azure-index.ts
|
|
29
33
|
var LEVEL_RANK = { debug: 10, info: 20, warn: 30, error: 40 };
|
package/dist/azure-index.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/azure-index.ts"],
|
|
4
4
|
"sourcesContent": ["/**\r\n * Azure Cloud Posture (CSPM) collector CLI entry point.\r\n *\r\n * pnpm azure-scan inventory every subscription the configured ARM\r\n * service principal can see (or the AZURE_SUBSCRIPTIONS\r\n * allow-list, if set) and push each to /ingest/azure\r\n * pnpm azure-scan:dry inventory and print a summary WITHOUT pushing\r\n * tsx src/azure-index.ts --dry-run (equivalent to azure-scan:dry)\r\n *\r\n * ONE service principal (ARM app registration, OAuth2 client-credentials) that\r\n * may see MANY subscriptions \u2014 unlike identity-index.ts's \"one Graph app\r\n * registration = one cloud org\", this loops {@link listAccessibleSubscriptions}\r\n * and builds + pushes ONE AzureInventory PER subscription, each versioned\r\n * independently on the control plane by subscriptionId. A gather that 403s on a\r\n * missing role/unregistered resource provider degrades that ONE signal\r\n * gracefully within a single subscription's build (see azure/plugin.ts); only a\r\n * failure to acquire a token or list subscriptions at all fails the whole run.\r\n *\r\n * Ctrl-C (SIGINT) triggers a cooperative AbortSignal so in-flight requests stop.\r\n */\r\nimport { loadAzureConfig } from \"./config.js\";\r\nimport { pushAzureInventory } from \"./core/push.js\";\r\nimport { ArmClient } from \"./azure/arm.js\";\r\nimport { buildAzureInventory, listAccessibleSubscriptions, runAzureMonitoringCoverage, type AzureStamp } from \"./azure/plugin.js\";\r\nimport type { Logger } from \"./core/runner.js\";\r\nimport type { AzureInventory } from \"@netdoc/collector-contract\";\r\nimport { requireEntitlementToScan } from \"./entitlement/index.js\";\r\n// Cost Optimization (docs/design/cost-optimization.md): the Advisor cost gather after the pushes.\r\nimport { runCostAfterAzure } from \"./costOptimization/run.js\";\r\n\r\nconst LEVEL_RANK = { debug: 10, info: 20, warn: 30, error: 40 } as const;\r\n\r\nfunction makeLogger(minLevel: keyof typeof LEVEL_RANK = \"info\"): Logger {\r\n const min = LEVEL_RANK[minLevel];\r\n return (level, msg, meta) => {\r\n if (LEVEL_RANK[level] < min) return;\r\n const line = `${new Date().toISOString()} ${level.toUpperCase().padEnd(5)} ${msg}`;\r\n const out = level === \"error\" ? console.error : level === \"warn\" ? console.warn : console.log;\r\n if (meta !== undefined) out(line, meta);\r\n else out(line);\r\n };\r\n}\r\n\r\nfunction errMsg(err: unknown): string {\r\n return err instanceof Error ? err.message : String(err);\r\n}\r\n\r\nfunction printSummary(inv: AzureInventory, log: Logger): void {\r\n log(\"info\", \"=== DRY RUN \u2014 AzureInventory NOT pushed ===\");\r\n log(\"info\", `subscription : ${inv.subscription.name} (${inv.subscriptionId})`);\r\n log(\"info\", `tenant : ${inv.tenantId}`);\r\n log(\"info\", `directory tenant : ${inv.tenantDirId}`);\r\n log(\"info\", `capturedAt : ${inv.capturedAt}`);\r\n log(\"info\", `state : ${inv.subscription.state}`);\r\n log(\r\n \"info\",\r\n `management group : ${inv.subscription.managementGroupName ?? inv.subscription.managementGroupId ?? \"not observed\"}`,\r\n );\r\n log(\"info\", `resources : ${inv.resources.length}`);\r\n // `hasRiskyInbound` is true when SOME inbound Allow rule names an any-source\r\n // prefix; it says nothing about which port that rule opens, so an NSG fronting\r\n // a public web server (443 from the internet, exactly as intended) sets it.\r\n // Reporting that count as \"risky\" told the operator about an exposure this\r\n // payload cannot substantiate \u2014 the per-port verdict belongs to the control\r\n // plane's audit engine, which reads the rules shipped alongside the flag.\r\n const internetFacingNsgs = inv.network.filter((n) => n.kind === \"nsg\" && n.hasRiskyInbound).length;\r\n log(\"info\", `network entities : ${inv.network.length} (${internetFacingNsgs} NSG(s) with any-source inbound)`);\r\n log(\"info\", `rbac assignments : ${inv.rbac.length} (${inv.rbac.filter((r) => r.isPrivileged).length} privileged)`);\r\n if (inv.defender) {\r\n log(\r\n \"info\",\r\n `defender : secureScore=${inv.defender.secureScore ?? \"?\"} ` +\r\n `${Object.keys(inv.defender.planCoverage).length} plan(s), ${inv.defender.recommendations.length} recommendation(s)`,\r\n );\r\n } else {\r\n log(\"info\", \"defender : not observed (missing Microsoft.Security role/RP registration?)\");\r\n }\r\n const nonCompliant = inv.policy.filter((p) => p.complianceState === \"NonCompliant\").length;\r\n log(\"info\", `policy : ${inv.policy.length} assignment(s) (${nonCompliant} non-compliant)`);\r\n}\r\n\r\nasync function main(): Promise<void> {\r\n const argv = process.argv.slice(2);\r\n const dryRun = argv.includes(\"--dry-run\");\r\n const debug = argv.includes(\"--debug\") || process.env.LOG_LEVEL === \"debug\";\r\n const log = makeLogger(debug ? \"debug\" : \"info\");\r\n\r\n const config = loadAzureConfig();\r\n\r\n // \u2500\u2500 PAID-LICENCE GATE \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\r\n //\r\n // BEFORE the client is built and before a credential leaves this process.\r\n // `core/planRefusal.ts` named this exact path as the one its own refusal\r\n // handling could not save: \"a refusal is learned at PUSH \u2014 which for a\r\n // one-shot `netdoc-collector scan azure` is after the collector has already\r\n // logged into the customer's Azure subscriptions and read their whole inventory\". Asking\r\n // first is what closes it.\r\n //\r\n // `--dry-run` IS GATED TOO, deliberately. A dry run still authenticates to\r\n // the customer's appliance and reads their estate; it merely declines to\r\n // upload it. The connection is the thing an unentitled tenant must not make.\r\n await requireEntitlementToScan(config, log, \"the one-shot Azure Cloud Posture scan\");\r\n\r\n\r\n const controller = new AbortController();\r\n const onSigint = (): void => {\r\n log(\"warn\", \"SIGINT received \u2014 shutting down\u2026\");\r\n controller.abort();\r\n };\r\n process.on(\"SIGINT\", onSigint);\r\n\r\n log(\"info\", `Azure Cloud Posture (CSPM) collector starting (dryRun=${dryRun}) \u2014 ARM tenant ${config.azureTenantId}`);\r\n\r\n try {\r\n const client = new ArmClient(\r\n {\r\n tenantId: config.azureTenantId,\r\n clientId: config.azureClientId,\r\n clientSecret: config.azureClientSecret,\r\n signal: controller.signal,\r\n },\r\n log,\r\n );\r\n\r\n const subs = await listAccessibleSubscriptions(client, config.azureSubscriptions);\r\n log(\r\n \"info\",\r\n `found ${subs.length} accessible subscription(s): ${subs.map((s) => `${s.displayName} (${s.subscriptionId})`).join(\", \")}`,\r\n );\r\n\r\n for (const sub of subs) {\r\n const stamp: AzureStamp = {\r\n collectorId: config.collectorId,\r\n tenantId: config.tenantId,\r\n siteId: config.siteId,\r\n tenantDirId: config.azureTenantId,\r\n };\r\n const inventory = await buildAzureInventory(client, sub, stamp, log);\r\n\r\n if (dryRun) {\r\n printSummary(inventory, log);\r\n continue;\r\n }\r\n\r\n log(\"info\", `pushing Azure inventory for subscription ${sub.subscriptionId} to ${config.controlPlaneUrl}`);\r\n const result = await pushAzureInventory(\r\n inventory,\r\n { controlPlaneUrl: config.controlPlaneUrl, apiKey: config.apiKey },\r\n log,\r\n controller.signal,\r\n );\r\n log(\"info\", `=== PUSH OK (subscription ${sub.subscriptionId}) ===`);\r\n if (result.snapshotId) log(\"info\", `snapshotId : ${result.snapshotId}`);\r\n if (result.version !== undefined) log(\"info\", `version : ${result.version}`);\r\n }\r\n\r\n // Monitoring coverage, after the inventory pushes (never throws; a dry run\r\n // uploads nothing, so it does not read for an upload either).\r\n if (!dryRun && !controller.signal.aborted) {\r\n await runAzureMonitoringCoverage(\r\n client,\r\n subs,\r\n { collectorId: config.collectorId, tenantId: config.tenantId, siteId: config.siteId, tenantDirId: config.azureTenantId },\r\n { controlPlaneUrl: config.controlPlaneUrl, apiKey: config.apiKey },\r\n log,\r\n controller.signal,\r\n );\r\n }\r\n\r\n // Cost Optimization: Advisor cost recommendations, after the pushes (never\r\n // throws; reads nothing unless the plan includes the module; not on a dry run).\r\n if (!dryRun && !controller.signal.aborted) {\r\n await runCostAfterAzure({\r\n client,\r\n subscriptionIds: subs.map((s) => s.subscriptionId),\r\n push: { controlPlaneUrl: config.controlPlaneUrl, apiKey: config.apiKey },\r\n log,\r\n signal: controller.signal,\r\n });\r\n }\r\n } finally {\r\n process.off(\"SIGINT\", onSigint);\r\n }\r\n}\r\n\r\nmain().catch((err) => {\r\n console.error(`${new Date().toISOString()} ERROR ${errMsg(err)}`);\r\n process.exitCode = 1;\r\n});\r\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BA,IAAM,aAAa,EAAE,OAAO,IAAI,MAAM,IAAI,MAAM,IAAI,OAAO,GAAG;AAE9D,SAAS,WAAW,WAAoC,QAAgB;AACtE,QAAM,MAAM,WAAW,QAAQ;AAC/B,SAAO,CAAC,OAAO,KAAK,SAAS;AAC3B,QAAI,WAAW,KAAK,IAAI,IAAK;AAC7B,UAAM,OAAO,IAAG,oBAAI,KAAK,GAAE,YAAY,CAAC,IAAI,MAAM,YAAY,EAAE,OAAO,CAAC,CAAC,IAAI,GAAG;AAChF,UAAM,MAAM,UAAU,UAAU,QAAQ,QAAQ,UAAU,SAAS,QAAQ,OAAO,QAAQ;AAC1F,QAAI,SAAS,OAAW,KAAI,MAAM,IAAI;AAAA,QACjC,KAAI,IAAI;AAAA,EACf;AACF;AAEA,SAAS,OAAO,KAAsB;AACpC,SAAO,eAAe,QAAQ,IAAI,UAAU,OAAO,GAAG;AACxD;AAEA,SAAS,aAAa,KAAqB,KAAmB;AAC5D,MAAI,QAAQ,kDAA6C;AACzD,MAAI,Q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AI,QAAQ,iBAAiB,OAAO,UAAU,EAAE;AACvE,UAAI,OAAO,YAAY,OAAW,KAAI,QAAQ,iBAAiB,OAAO,OAAO,EAAE;AAAA,IACjF;AAIA,QAAI,CAAC,UAAU,CAAC,WAAW,OAAO,SAAS;AACzC,YAAM;AAAA,QACJ;AAAA,QACA;AAAA,QACA,EAAE,aAAa,OAAO,aAAa,UAAU,OAAO,UAAU,QAAQ,OAAO,QAAQ,aAAa,OAAO,cAAc;AAAA,QACvH,EAAE,iBAAiB,OAAO,iBAAiB,QAAQ,OAAO,OAAO;AAAA,QACjE;AAAA,QACA,WAAW;AAAA,MACb;AAAA,IACF;AAIA,QAAI,CAAC,UAAU,CAAC,WAAW,OAAO,SAAS;AACzC,YAAM,kBAAkB;AAAA,QACtB;AAAA,QACA,iBAAiB,KAAK,IAAI,CAAC,MAAM,EAAE,cAAc;AAAA,QACjD,MAAM,EAAE,iBAAiB,OAAO,iBAAiB,QAAQ,OAAO,OAAO;AAAA,QACvE;AAAA,QACA,QAAQ,WAAW;AAAA,MACrB,CAAC;AAAA,IACH;AAAA,EACF,UAAE;AACA,YAAQ,IAAI,UAAU,QAAQ;AAAA,EAChC;AACF;AAEA,KAAK,EAAE,MAAM,CAAC,QAAQ;AACpB,UAAQ,MAAM,IAAG,oBAAI,KAAK,GAAE,YAAY,CAAC,UAAU,OAAO,GAAG,CAAC,EAAE;AAChE,UAAQ,WAAW;AACrB,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -135,6 +135,19 @@ var COLLECTOR_MODULES = [
|
|
|
135
135
|
entry: "./aws-index.js",
|
|
136
136
|
ledgerModes: ["daemon:aws"]
|
|
137
137
|
},
|
|
138
|
+
{
|
|
139
|
+
// Kubernetes in-cluster read (docs/design/cloud-containers-refresh-multicloud.md §4):
|
|
140
|
+
// namespaces, workloads, services, ingresses and node counts of every cluster this
|
|
141
|
+
// collector holds a read-only `kubernetes` credential set for. Gated on the scan
|
|
142
|
+
// module MODULE_FOR_SCAN_DOMAIN names (`discovery`); the daemon driver is kubernetes/run.ts.
|
|
143
|
+
key: "kubernetes",
|
|
144
|
+
domain: "kubernetes",
|
|
145
|
+
consoleRefusal: null,
|
|
146
|
+
moduleKey: "discovery",
|
|
147
|
+
label: "Kubernetes clusters (in-cluster read)",
|
|
148
|
+
entry: "./kubernetes-index.js",
|
|
149
|
+
ledgerModes: ["daemon:kubernetes"]
|
|
150
|
+
},
|
|
138
151
|
{
|
|
139
152
|
// Microsoft 365 Sharing (docs/design/m365-sharing.md §2.3.1): what in
|
|
140
153
|
// SharePoint and OneDrive has been shared, read through Microsoft Graph with
|
|
@@ -214,4 +227,4 @@ export {
|
|
|
214
227
|
COLLECTOR_MODULES,
|
|
215
228
|
findModule
|
|
216
229
|
};
|
|
217
|
-
//# sourceMappingURL=chunk-
|
|
230
|
+
//# sourceMappingURL=chunk-2AKCDNDQ.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/ui/modules.ts"],
|
|
4
|
-
"sourcesContent": ["/**\r\n * The collector's scan modules, as ONE table.\r\n *\r\n * Three consumers read it, and keeping them on a single list is the point:\r\n *\r\n * - `src/cli.ts` maps `netdoc-collector scan <key>` onto the module's\r\n * existing entry file. The entrypoints themselves are untouched \u2014 they\r\n * talk to real hardware and each already knows how to load its own config,\r\n * print its own summary and set its own exit code. The CLI only DISPATCHES.\r\n * - `src/ui/status.ts` folds the use-log ledger into a per-module \"last run\"\r\n * row, and needs to know which ledger `mode` strings belong to which module.\r\n * - `src/ui/server.ts` accepts `POST /ui/api/scan {module}` and must refuse a\r\n * key that is not on this list \u2014 the module name is the only part of that\r\n * request that reaches a `spawn`, so the allowlist IS the injection guard.\r\n *\r\n * A module added here gains all three surfaces at once; a module added to only\r\n * one of them is the drift this table exists to prevent.\r\n */\r\n\r\nimport type { ModuleKey, ScanDomain } from \"@netdoc/collector-contract\";\r\n\r\nexport interface CollectorModule {\r\n /** The key typed after `scan` and posted by the UI's Run button. */\r\n key: string;\r\n /**\r\n * The control plane's name for this scan \u2014 the `domain` a job carries.\r\n *\r\n * It is what lets the UI's Run button build a LOCAL JOB and hand it to the\r\n * running daemon (`core/manualRuns.ts`) instead of spawning a one-shot child\r\n * that would demand `ORG_ID` / `SITE_ID` / `SCAN_TARGETS` from a config file\r\n * enrolment never writes them into. Stated here rather than parsed back out\r\n * of `ledgerModes`, where it has always been half-present as\r\n * `daemon:<domain>`: a string that is load-bearing for what runs should not\r\n * have to be recovered from a string that exists to match log records.\r\n *\r\n * NULL for a module that is not a scan domain at all \u2014 `config-import`, which\r\n * reads a directory of device configs rather than reaching an estate.\r\n */\r\n domain: ScanDomain | null;\r\n /**\r\n * Why the local console cannot START this module, when it cannot \u2014 the whole\r\n * sentence the button answers with, naming the command that does work.\r\n *\r\n * TWO modules refuse, for two different reasons, and keeping the reason here\r\n * rather than deriving it from `domain` is the point: `config-import` has no\r\n * domain at all, while `sensitive-data` has a perfectly real one that the\r\n * daemon nevertheless REFUSES from the scan-job queue (`core/daemon.ts` \u2014 it\r\n * pushes through a resumable run/batch/close sequence instead of one\r\n * snapshot, and the queue's dispatch chain would otherwise fall through to\r\n * the SQL Server driver). Deriving the refusal from `domain === null` would\r\n * have queued a sensitive-data job that the daemon fails a second later, and\r\n * the operator would read that as a broken scan rather than a wrong button.\r\n *\r\n * NULL means the console can run it.\r\n */\r\n consoleRefusal: string | null;\r\n /**\r\n * The licence module this scan is gated on \u2014 the key the tenant must OWN for\r\n * the resulting push to be accepted, and the one the UI checks (via\r\n * `collectorOwnsModule`) before it enables a \"Run scan\" button. It is the\r\n * catalogue name, which is not always the CLI key: `lb` is sold as\r\n * `load-balancer`, the `identity` collector feeds `cloud-identity`. Kept beside\r\n * the CLI key here rather than derived at the call site so this one table stays\r\n * the single source of truth for \"what is this module, in every sense\".\r\n */\r\n moduleKey: ModuleKey;\r\n /** Human label for the UI's modules table. */\r\n label: string;\r\n /**\r\n * The module's entry file, as an import specifier RELATIVE TO `src/` (and\r\n * therefore to the compiled `dist/`). `src/cli.ts` sits in that directory, so\r\n * a plain dynamic `import(entry)` from there resolves it in both worlds \u2014\r\n * under tsx in a checkout and as compiled JS in the installed package.\r\n */\r\n /**\r\n * The one-shot module to import for `netdoc-collector scan <key>`.\r\n *\r\n * NULL for a domain that has no one-shot entrypoint. Four of them do not \u2014\r\n * storage, firewall, wireless and NAC are implemented as DOMAIN RUNNERS in\r\n * `core/domainScan.ts` and reached through a job, which is how the portal has\r\n * always run them. They were absent from this table entirely until\r\n * 2026-09-11, so the local console offered no way to run four scan types the\r\n * collector fully supports.\r\n *\r\n * Listing them with a null entry is what fixes that without inventing four\r\n * `*-index.ts` files nobody asked for: the console's Run button builds a JOB\r\n * (see `ui/actions.ts`), which the daemon dispatches by domain, and never\r\n * touches this field. `cli.ts` does, and refuses with a sentence naming the\r\n * two ways that do work.\r\n */\r\n entry: string | null;\r\n /**\r\n * The `mode` strings this module's runs are recorded under in the use log\r\n * (`core/useLog.ts`): one-shot runs write \"scan\"/\"scan --dry-run\", daemon\r\n * jobs write \"daemon:<domain>\" where <domain> is the CONTROL PLANE's name\r\n * for the module \u2014 which is not always the CLI key (`lb` is the plane's\r\n * \"loadbalancer\"). Empty means the module keeps no ledger record today\r\n * (config-import), and its status row honestly shows \"never\".\r\n */\r\n ledgerModes: readonly string[];\r\n}\r\n\r\nexport const COLLECTOR_MODULES: readonly CollectorModule[] = [\r\n {\r\n key: \"network\",\r\n domain: \"network\",\r\n consoleRefusal: null,\r\n moduleKey: \"discovery\",\r\n label: \"Network sweep (ICMP / ARP / SNMP / SSH)\",\r\n entry: \"./index.js\",\r\n ledgerModes: [\"scan\", \"scan --dry-run\", \"daemon:network\"],\r\n },\r\n {\r\n key: \"vmware\",\r\n domain: \"vmware\",\r\n consoleRefusal: null,\r\n moduleKey: \"vmware\",\r\n label: \"VMware vSphere\",\r\n entry: \"./vmware-index.js\",\r\n ledgerModes: [\"daemon:vmware\"],\r\n },\r\n {\r\n key: \"hyperv\",\r\n domain: \"hyperv\",\r\n consoleRefusal: null,\r\n moduleKey: \"hyperv\",\r\n label: \"Hyper-V\",\r\n entry: \"./hyperv-index.js\",\r\n ledgerModes: [\"daemon:hyperv\"],\r\n },\r\n {\r\n key: \"sql\",\r\n domain: \"sql\",\r\n consoleRefusal: null,\r\n moduleKey: \"sql\",\r\n label: \"SQL Server\",\r\n entry: \"./sql-index.js\",\r\n ledgerModes: [\"daemon:sql\"],\r\n },\r\n {\r\n key: \"lb\",\r\n domain: \"loadbalancer\",\r\n consoleRefusal: null,\r\n // The CLI key is `lb`; the module is sold as `load-balancer`.\r\n moduleKey: \"load-balancer\",\r\n label: \"Load balancers (A10)\",\r\n entry: \"./a10-index.js\",\r\n ledgerModes: [\"daemon:loadbalancer\"],\r\n },\r\n {\r\n key: \"storage\",\r\n domain: \"storage\",\r\n consoleRefusal: null,\r\n moduleKey: \"storage\",\r\n label: \"Storage arrays (NetApp / Dell EMC / EqualLogic)\",\r\n // Daemon-only: no one-shot entrypoint exists for this domain.\r\n entry: null,\r\n ledgerModes: [\"daemon:storage\"],\r\n },\r\n {\r\n key: \"firewall\",\r\n domain: \"firewall\",\r\n consoleRefusal: null,\r\n // The domain is `firewall`; the catalogue sells it as `firewall-audit`.\r\n moduleKey: \"firewall-audit\",\r\n label: \"Firewalls (FMC / FDM / PAN-OS)\",\r\n entry: null,\r\n ledgerModes: [\"daemon:firewall\"],\r\n },\r\n {\r\n key: \"wireless\",\r\n domain: \"wireless\",\r\n consoleRefusal: null,\r\n moduleKey: \"wireless\",\r\n label: \"Wireless controllers (WLC)\",\r\n entry: null,\r\n ledgerModes: [\"daemon:wireless\"],\r\n },\r\n {\r\n key: \"nac\",\r\n domain: \"nac\",\r\n consoleRefusal: null,\r\n moduleKey: \"nac\",\r\n label: \"Network access control (ISE / ClearPass)\",\r\n entry: null,\r\n ledgerModes: [\"daemon:nac\"],\r\n },\r\n {\r\n key: \"voice\",\r\n domain: \"voice\",\r\n consoleRefusal: null,\r\n moduleKey: \"voice\",\r\n label: \"Voice & Collaboration (CUCM / Unity / Webex)\",\r\n entry: \"./voice-index.js\",\r\n ledgerModes: [\"daemon:voice\"],\r\n },\r\n {\r\n key: \"identity\",\r\n domain: \"identity\",\r\n consoleRefusal: null,\r\n // The `identity` collector is the Microsoft Graph one; it feeds\r\n // `cloud-identity` (Entra / M365), NOT the on-prem `ad-identity` module.\r\n moduleKey: \"cloud-identity\",\r\n label: \"Identity & Cloud (Microsoft Entra ID)\",\r\n entry: \"./identity-index.js\",\r\n ledgerModes: [\"daemon:identity\"],\r\n },\r\n {\r\n key: \"azure\",\r\n domain: \"azure\",\r\n consoleRefusal: null,\r\n moduleKey: \"azure\",\r\n label: \"Azure Cloud Posture (CSPM)\",\r\n entry: \"./azure-index.js\",\r\n ledgerModes: [\"daemon:azure\"],\r\n },\r\n {\r\n // Google Cloud (docs/design/cloud-aws-gcp.md \u00A74.1): one service account,\r\n // every project it can see. The daemon driver is gcp/run.ts.\r\n key: \"gcp\",\r\n domain: \"gcp\",\r\n consoleRefusal: null,\r\n moduleKey: \"gcp\",\r\n label: \"GCP Cloud Posture\",\r\n entry: \"./gcp-index.js\",\r\n ledgerModes: [\"daemon:gcp\"],\r\n },\r\n {\r\n // AWS (docs/design/cloud-aws-gcp.md \u00A74.1): one account per credential set\r\n // (an IAM user's key, optionally assuming a role). The daemon driver is aws/run.ts.\r\n key: \"aws\",\r\n domain: \"aws\",\r\n consoleRefusal: null,\r\n moduleKey: \"aws\",\r\n label: \"AWS Cloud Posture\",\r\n entry: \"./aws-index.js\",\r\n ledgerModes: [\"daemon:aws\"],\r\n },\r\n {\r\n // Microsoft 365 Sharing (docs/design/m365-sharing.md \u00A72.3.1): what in\r\n // SharePoint and OneDrive has been shared, read through Microsoft Graph with\r\n // the `graph` vault set. Daemon-only (`core/domainScan.ts`\r\n // `runM365SharingScan`): it pushes through a run/batch/close sequence and\r\n // resumes per library, which a one-shot command would only duplicate. The\r\n // run's targets are its two switches: `sharepoint` and/or `onedrive`.\r\n key: \"m365-sharing\",\r\n domain: \"m365-sharing\",\r\n consoleRefusal: null,\r\n moduleKey: \"m365-sharing\",\r\n label: \"Microsoft 365 Sharing\",\r\n entry: null,\r\n ledgerModes: [\"daemon:m365-sharing\"],\r\n },\r\n {\r\n key: \"config-import\",\r\n domain: null,\r\n consoleRefusal:\r\n \"reads a directory of device configurations given as --path, which no button can supply \u2014 \" +\r\n \"run it from a shell, as: netdoc-collector scan config-import --path <directory>\",\r\n moduleKey: \"config-import\",\r\n label: \"Config import (offline device configs)\",\r\n entry: \"./configimport-index.js\",\r\n ledgerModes: [],\r\n },\r\n {\r\n // Sensitive-data discovery (PLAN-010, Phases 2-4). Its entrypoint arrived\r\n // without a row here, which left the packaged CLI unable to dispatch it \u2014\r\n // `netdoc-collector scan sensitive-data` is this line. Empty ledgerModes\r\n // like config-import: its run/batch/close ingest keeps its own records and\r\n // writes no use-log mode yet, so the status row honestly shows \"never\"\r\n // rather than guessing at a mode string the ledger never carries.\r\n //\r\n // Now that a scan classifies and PUSHES (sensitiveData/pushRun.ts), \"never\"\r\n // is a thinner answer than it was \u2014 the run is recorded in sdd_scan_runs at\r\n // the far end, just not in the local ledger this row reads. Giving it a real\r\n // mode is a small piece of work and the right one; it is deliberately not\r\n // being smuggled in with the ingest wiring.\r\n key: \"sensitive-data\",\r\n domain: \"sensitive-data\",\r\n // Runs from the button since 2026-09-12: the daemon drives this module's\r\n // own entry as a supervised child (core/sddJob.ts), so the resumable\r\n // run/batch/close protocol stays in one place and the Run button, the\r\n // schedule and the plane's queue all reach it. Targets are the file servers\r\n // to enumerate \u2014 names, addresses or CIDRs.\r\n consoleRefusal: null,\r\n moduleKey: \"sensitive-data\",\r\n label: \"Sensitive Data Discovery\",\r\n entry: \"./sensitive-data-index.js\",\r\n ledgerModes: [],\r\n },\r\n {\r\n // \u2500\u2500 THE OTHER HALF OF THE MODULE \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\r\n //\r\n // Same `moduleKey`, because a customer buys Sensitive Data Discovery\r\n // once. A separate ROW because the two scans are pointed at different\r\n // things and an operator has to choose: this one enumerates what named\r\n // FILE SERVERS publish and walks those shares; the row above reads the\r\n // user folders on the machines a sweep found, share or no share.\r\n //\r\n // Until 2026-09-18 there was one row doing both badly: a workstation\r\n // publishes nothing, so the machines in an estate came back \"nothing here\r\n // to scan\".\r\n key: \"smb-shares\",\r\n domain: \"smb-shares\",\r\n consoleRefusal: null,\r\n moduleKey: \"sensitive-data\",\r\n label: \"Sensitive Data Discovery (SMB shares)\",\r\n entry: \"./smb-shares-index.js\",\r\n ledgerModes: [],\r\n },\r\n];\r\n\r\n/** Look a module up by its CLI/UI key. */\r\nexport function findModule(key: string): CollectorModule | undefined {\r\n return COLLECTOR_MODULES.find((m) => m.key === key);\r\n}\r\n"],
|
|
5
|
-
"mappings": ";AAsGO,IAAM,oBAAgD;AAAA,EAC3D;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC,QAAQ,kBAAkB,gBAAgB;AAAA,EAC1D;AAAA,EACA;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC,eAAe;AAAA,EAC/B;AAAA,EACA;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC,eAAe;AAAA,EAC/B;AAAA,EACA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A;AAAA;AAAA;AAAA;AAAA,IAYE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC;AAAA,EAChB;AACF;AAGO,SAAS,WAAW,KAA0C;AACnE,SAAO,kBAAkB,KAAK,CAAC,MAAM,EAAE,QAAQ,GAAG;AACpD;",
|
|
4
|
+
"sourcesContent": ["/**\r\n * The collector's scan modules, as ONE table.\r\n *\r\n * Three consumers read it, and keeping them on a single list is the point:\r\n *\r\n * - `src/cli.ts` maps `netdoc-collector scan <key>` onto the module's\r\n * existing entry file. The entrypoints themselves are untouched \u2014 they\r\n * talk to real hardware and each already knows how to load its own config,\r\n * print its own summary and set its own exit code. The CLI only DISPATCHES.\r\n * - `src/ui/status.ts` folds the use-log ledger into a per-module \"last run\"\r\n * row, and needs to know which ledger `mode` strings belong to which module.\r\n * - `src/ui/server.ts` accepts `POST /ui/api/scan {module}` and must refuse a\r\n * key that is not on this list \u2014 the module name is the only part of that\r\n * request that reaches a `spawn`, so the allowlist IS the injection guard.\r\n *\r\n * A module added here gains all three surfaces at once; a module added to only\r\n * one of them is the drift this table exists to prevent.\r\n */\r\n\r\nimport type { ModuleKey, ScanDomain } from \"@netdoc/collector-contract\";\r\n\r\nexport interface CollectorModule {\r\n /** The key typed after `scan` and posted by the UI's Run button. */\r\n key: string;\r\n /**\r\n * The control plane's name for this scan \u2014 the `domain` a job carries.\r\n *\r\n * It is what lets the UI's Run button build a LOCAL JOB and hand it to the\r\n * running daemon (`core/manualRuns.ts`) instead of spawning a one-shot child\r\n * that would demand `ORG_ID` / `SITE_ID` / `SCAN_TARGETS` from a config file\r\n * enrolment never writes them into. Stated here rather than parsed back out\r\n * of `ledgerModes`, where it has always been half-present as\r\n * `daemon:<domain>`: a string that is load-bearing for what runs should not\r\n * have to be recovered from a string that exists to match log records.\r\n *\r\n * NULL for a module that is not a scan domain at all \u2014 `config-import`, which\r\n * reads a directory of device configs rather than reaching an estate.\r\n */\r\n domain: ScanDomain | null;\r\n /**\r\n * Why the local console cannot START this module, when it cannot \u2014 the whole\r\n * sentence the button answers with, naming the command that does work.\r\n *\r\n * TWO modules refuse, for two different reasons, and keeping the reason here\r\n * rather than deriving it from `domain` is the point: `config-import` has no\r\n * domain at all, while `sensitive-data` has a perfectly real one that the\r\n * daemon nevertheless REFUSES from the scan-job queue (`core/daemon.ts` \u2014 it\r\n * pushes through a resumable run/batch/close sequence instead of one\r\n * snapshot, and the queue's dispatch chain would otherwise fall through to\r\n * the SQL Server driver). Deriving the refusal from `domain === null` would\r\n * have queued a sensitive-data job that the daemon fails a second later, and\r\n * the operator would read that as a broken scan rather than a wrong button.\r\n *\r\n * NULL means the console can run it.\r\n */\r\n consoleRefusal: string | null;\r\n /**\r\n * The licence module this scan is gated on \u2014 the key the tenant must OWN for\r\n * the resulting push to be accepted, and the one the UI checks (via\r\n * `collectorOwnsModule`) before it enables a \"Run scan\" button. It is the\r\n * catalogue name, which is not always the CLI key: `lb` is sold as\r\n * `load-balancer`, the `identity` collector feeds `cloud-identity`. Kept beside\r\n * the CLI key here rather than derived at the call site so this one table stays\r\n * the single source of truth for \"what is this module, in every sense\".\r\n */\r\n moduleKey: ModuleKey;\r\n /** Human label for the UI's modules table. */\r\n label: string;\r\n /**\r\n * The module's entry file, as an import specifier RELATIVE TO `src/` (and\r\n * therefore to the compiled `dist/`). `src/cli.ts` sits in that directory, so\r\n * a plain dynamic `import(entry)` from there resolves it in both worlds \u2014\r\n * under tsx in a checkout and as compiled JS in the installed package.\r\n */\r\n /**\r\n * The one-shot module to import for `netdoc-collector scan <key>`.\r\n *\r\n * NULL for a domain that has no one-shot entrypoint. Four of them do not \u2014\r\n * storage, firewall, wireless and NAC are implemented as DOMAIN RUNNERS in\r\n * `core/domainScan.ts` and reached through a job, which is how the portal has\r\n * always run them. They were absent from this table entirely until\r\n * 2026-09-11, so the local console offered no way to run four scan types the\r\n * collector fully supports.\r\n *\r\n * Listing them with a null entry is what fixes that without inventing four\r\n * `*-index.ts` files nobody asked for: the console's Run button builds a JOB\r\n * (see `ui/actions.ts`), which the daemon dispatches by domain, and never\r\n * touches this field. `cli.ts` does, and refuses with a sentence naming the\r\n * two ways that do work.\r\n */\r\n entry: string | null;\r\n /**\r\n * The `mode` strings this module's runs are recorded under in the use log\r\n * (`core/useLog.ts`): one-shot runs write \"scan\"/\"scan --dry-run\", daemon\r\n * jobs write \"daemon:<domain>\" where <domain> is the CONTROL PLANE's name\r\n * for the module \u2014 which is not always the CLI key (`lb` is the plane's\r\n * \"loadbalancer\"). Empty means the module keeps no ledger record today\r\n * (config-import), and its status row honestly shows \"never\".\r\n */\r\n ledgerModes: readonly string[];\r\n}\r\n\r\nexport const COLLECTOR_MODULES: readonly CollectorModule[] = [\r\n {\r\n key: \"network\",\r\n domain: \"network\",\r\n consoleRefusal: null,\r\n moduleKey: \"discovery\",\r\n label: \"Network sweep (ICMP / ARP / SNMP / SSH)\",\r\n entry: \"./index.js\",\r\n ledgerModes: [\"scan\", \"scan --dry-run\", \"daemon:network\"],\r\n },\r\n {\r\n key: \"vmware\",\r\n domain: \"vmware\",\r\n consoleRefusal: null,\r\n moduleKey: \"vmware\",\r\n label: \"VMware vSphere\",\r\n entry: \"./vmware-index.js\",\r\n ledgerModes: [\"daemon:vmware\"],\r\n },\r\n {\r\n key: \"hyperv\",\r\n domain: \"hyperv\",\r\n consoleRefusal: null,\r\n moduleKey: \"hyperv\",\r\n label: \"Hyper-V\",\r\n entry: \"./hyperv-index.js\",\r\n ledgerModes: [\"daemon:hyperv\"],\r\n },\r\n {\r\n key: \"sql\",\r\n domain: \"sql\",\r\n consoleRefusal: null,\r\n moduleKey: \"sql\",\r\n label: \"SQL Server\",\r\n entry: \"./sql-index.js\",\r\n ledgerModes: [\"daemon:sql\"],\r\n },\r\n {\r\n key: \"lb\",\r\n domain: \"loadbalancer\",\r\n consoleRefusal: null,\r\n // The CLI key is `lb`; the module is sold as `load-balancer`.\r\n moduleKey: \"load-balancer\",\r\n label: \"Load balancers (A10)\",\r\n entry: \"./a10-index.js\",\r\n ledgerModes: [\"daemon:loadbalancer\"],\r\n },\r\n {\r\n key: \"storage\",\r\n domain: \"storage\",\r\n consoleRefusal: null,\r\n moduleKey: \"storage\",\r\n label: \"Storage arrays (NetApp / Dell EMC / EqualLogic)\",\r\n // Daemon-only: no one-shot entrypoint exists for this domain.\r\n entry: null,\r\n ledgerModes: [\"daemon:storage\"],\r\n },\r\n {\r\n key: \"firewall\",\r\n domain: \"firewall\",\r\n consoleRefusal: null,\r\n // The domain is `firewall`; the catalogue sells it as `firewall-audit`.\r\n moduleKey: \"firewall-audit\",\r\n label: \"Firewalls (FMC / FDM / PAN-OS)\",\r\n entry: null,\r\n ledgerModes: [\"daemon:firewall\"],\r\n },\r\n {\r\n key: \"wireless\",\r\n domain: \"wireless\",\r\n consoleRefusal: null,\r\n moduleKey: \"wireless\",\r\n label: \"Wireless controllers (WLC)\",\r\n entry: null,\r\n ledgerModes: [\"daemon:wireless\"],\r\n },\r\n {\r\n key: \"nac\",\r\n domain: \"nac\",\r\n consoleRefusal: null,\r\n moduleKey: \"nac\",\r\n label: \"Network access control (ISE / ClearPass)\",\r\n entry: null,\r\n ledgerModes: [\"daemon:nac\"],\r\n },\r\n {\r\n key: \"voice\",\r\n domain: \"voice\",\r\n consoleRefusal: null,\r\n moduleKey: \"voice\",\r\n label: \"Voice & Collaboration (CUCM / Unity / Webex)\",\r\n entry: \"./voice-index.js\",\r\n ledgerModes: [\"daemon:voice\"],\r\n },\r\n {\r\n key: \"identity\",\r\n domain: \"identity\",\r\n consoleRefusal: null,\r\n // The `identity` collector is the Microsoft Graph one; it feeds\r\n // `cloud-identity` (Entra / M365), NOT the on-prem `ad-identity` module.\r\n moduleKey: \"cloud-identity\",\r\n label: \"Identity & Cloud (Microsoft Entra ID)\",\r\n entry: \"./identity-index.js\",\r\n ledgerModes: [\"daemon:identity\"],\r\n },\r\n {\r\n key: \"azure\",\r\n domain: \"azure\",\r\n consoleRefusal: null,\r\n moduleKey: \"azure\",\r\n label: \"Azure Cloud Posture (CSPM)\",\r\n entry: \"./azure-index.js\",\r\n ledgerModes: [\"daemon:azure\"],\r\n },\r\n {\r\n // Google Cloud (docs/design/cloud-aws-gcp.md \u00A74.1): one service account,\r\n // every project it can see. The daemon driver is gcp/run.ts.\r\n key: \"gcp\",\r\n domain: \"gcp\",\r\n consoleRefusal: null,\r\n moduleKey: \"gcp\",\r\n label: \"GCP Cloud Posture\",\r\n entry: \"./gcp-index.js\",\r\n ledgerModes: [\"daemon:gcp\"],\r\n },\r\n {\r\n // AWS (docs/design/cloud-aws-gcp.md \u00A74.1): one account per credential set\r\n // (an IAM user's key, optionally assuming a role). The daemon driver is aws/run.ts.\r\n key: \"aws\",\r\n domain: \"aws\",\r\n consoleRefusal: null,\r\n moduleKey: \"aws\",\r\n label: \"AWS Cloud Posture\",\r\n entry: \"./aws-index.js\",\r\n ledgerModes: [\"daemon:aws\"],\r\n },\r\n {\r\n // Kubernetes in-cluster read (docs/design/cloud-containers-refresh-multicloud.md \u00A74):\r\n // namespaces, workloads, services, ingresses and node counts of every cluster this\r\n // collector holds a read-only `kubernetes` credential set for. Gated on the scan\r\n // module MODULE_FOR_SCAN_DOMAIN names (`discovery`); the daemon driver is kubernetes/run.ts.\r\n key: \"kubernetes\",\r\n domain: \"kubernetes\",\r\n consoleRefusal: null,\r\n moduleKey: \"discovery\",\r\n label: \"Kubernetes clusters (in-cluster read)\",\r\n entry: \"./kubernetes-index.js\",\r\n ledgerModes: [\"daemon:kubernetes\"],\r\n },\r\n {\r\n // Microsoft 365 Sharing (docs/design/m365-sharing.md \u00A72.3.1): what in\r\n // SharePoint and OneDrive has been shared, read through Microsoft Graph with\r\n // the `graph` vault set. Daemon-only (`core/domainScan.ts`\r\n // `runM365SharingScan`): it pushes through a run/batch/close sequence and\r\n // resumes per library, which a one-shot command would only duplicate. The\r\n // run's targets are its two switches: `sharepoint` and/or `onedrive`.\r\n key: \"m365-sharing\",\r\n domain: \"m365-sharing\",\r\n consoleRefusal: null,\r\n moduleKey: \"m365-sharing\",\r\n label: \"Microsoft 365 Sharing\",\r\n entry: null,\r\n ledgerModes: [\"daemon:m365-sharing\"],\r\n },\r\n {\r\n key: \"config-import\",\r\n domain: null,\r\n consoleRefusal:\r\n \"reads a directory of device configurations given as --path, which no button can supply \u2014 \" +\r\n \"run it from a shell, as: netdoc-collector scan config-import --path <directory>\",\r\n moduleKey: \"config-import\",\r\n label: \"Config import (offline device configs)\",\r\n entry: \"./configimport-index.js\",\r\n ledgerModes: [],\r\n },\r\n {\r\n // Sensitive-data discovery (PLAN-010, Phases 2-4). Its entrypoint arrived\r\n // without a row here, which left the packaged CLI unable to dispatch it \u2014\r\n // `netdoc-collector scan sensitive-data` is this line. Empty ledgerModes\r\n // like config-import: its run/batch/close ingest keeps its own records and\r\n // writes no use-log mode yet, so the status row honestly shows \"never\"\r\n // rather than guessing at a mode string the ledger never carries.\r\n //\r\n // Now that a scan classifies and PUSHES (sensitiveData/pushRun.ts), \"never\"\r\n // is a thinner answer than it was \u2014 the run is recorded in sdd_scan_runs at\r\n // the far end, just not in the local ledger this row reads. Giving it a real\r\n // mode is a small piece of work and the right one; it is deliberately not\r\n // being smuggled in with the ingest wiring.\r\n key: \"sensitive-data\",\r\n domain: \"sensitive-data\",\r\n // Runs from the button since 2026-09-12: the daemon drives this module's\r\n // own entry as a supervised child (core/sddJob.ts), so the resumable\r\n // run/batch/close protocol stays in one place and the Run button, the\r\n // schedule and the plane's queue all reach it. Targets are the file servers\r\n // to enumerate \u2014 names, addresses or CIDRs.\r\n consoleRefusal: null,\r\n moduleKey: \"sensitive-data\",\r\n label: \"Sensitive Data Discovery\",\r\n entry: \"./sensitive-data-index.js\",\r\n ledgerModes: [],\r\n },\r\n {\r\n // \u2500\u2500 THE OTHER HALF OF THE MODULE \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\r\n //\r\n // Same `moduleKey`, because a customer buys Sensitive Data Discovery\r\n // once. A separate ROW because the two scans are pointed at different\r\n // things and an operator has to choose: this one enumerates what named\r\n // FILE SERVERS publish and walks those shares; the row above reads the\r\n // user folders on the machines a sweep found, share or no share.\r\n //\r\n // Until 2026-09-18 there was one row doing both badly: a workstation\r\n // publishes nothing, so the machines in an estate came back \"nothing here\r\n // to scan\".\r\n key: \"smb-shares\",\r\n domain: \"smb-shares\",\r\n consoleRefusal: null,\r\n moduleKey: \"sensitive-data\",\r\n label: \"Sensitive Data Discovery (SMB shares)\",\r\n entry: \"./smb-shares-index.js\",\r\n ledgerModes: [],\r\n },\r\n];\r\n\r\n/** Look a module up by its CLI/UI key. */\r\nexport function findModule(key: string): CollectorModule | undefined {\r\n return COLLECTOR_MODULES.find((m) => m.key === key);\r\n}\r\n"],
|
|
5
|
+
"mappings": ";AAsGO,IAAM,oBAAgD;AAAA,EAC3D;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC,QAAQ,kBAAkB,gBAAgB;AAAA,EAC1D;AAAA,EACA;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC,eAAe;AAAA,EAC/B;AAAA,EACA;AAAA,IACE,KAAK;AAAA,IACL,QAAQ;AAAA,IACR,gBAAgB;AAAA,IAChB,WAAW;AAAA,IACX,OAAO;AAAA,IACP,OAAO;AAAA,IACP,aAAa,CAAC,eAAe;AAAA,EAC/B;AAAA,EACA;AAAA,IACE,KAAK;AAAA,IACL,QAA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