@intutic/cli 2.5.0 → 2.5.1
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/README.md +27 -16
- package/dist/cli.js +24 -11
- package/dist/cli.js.map +1 -1
- package/dist/commands/attenuate.d.ts +9 -8
- package/dist/commands/attenuate.d.ts.map +1 -1
- package/dist/commands/attenuate.js +18 -11
- package/dist/commands/attenuate.js.map +1 -1
- package/dist/commands/budget.d.ts.map +1 -1
- package/dist/commands/budget.js +3 -6
- package/dist/commands/budget.js.map +1 -1
- package/dist/commands/chaos.js +3 -2
- package/dist/commands/chaos.js.map +1 -1
- package/dist/commands/connect.d.ts +7 -0
- package/dist/commands/connect.d.ts.map +1 -1
- package/dist/commands/connect.js +79 -31
- package/dist/commands/connect.js.map +1 -1
- package/dist/commands/disconnect.d.ts +11 -1
- package/dist/commands/disconnect.d.ts.map +1 -1
- package/dist/commands/disconnect.js +18 -3
- package/dist/commands/disconnect.js.map +1 -1
- package/dist/commands/doctor.d.ts +7 -0
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +21 -17
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/enforce.d.ts +14 -1
- package/dist/commands/enforce.d.ts.map +1 -1
- package/dist/commands/enforce.js +21 -3
- package/dist/commands/enforce.js.map +1 -1
- package/dist/commands/gateway.d.ts.map +1 -1
- package/dist/commands/gateway.js +3 -3
- package/dist/commands/gateway.js.map +1 -1
- package/dist/commands/guardrails.d.ts.map +1 -1
- package/dist/commands/guardrails.js +10 -8
- package/dist/commands/guardrails.js.map +1 -1
- package/dist/commands/integrity.d.ts.map +1 -1
- package/dist/commands/integrity.js +4 -1
- package/dist/commands/integrity.js.map +1 -1
- package/dist/commands/judge.d.ts.map +1 -1
- package/dist/commands/judge.js +6 -9
- package/dist/commands/judge.js.map +1 -1
- package/dist/commands/login.js +4 -4
- package/dist/commands/login.js.map +1 -1
- package/dist/commands/policy.d.ts +16 -0
- package/dist/commands/policy.d.ts.map +1 -1
- package/dist/commands/policy.js +86 -7
- package/dist/commands/policy.js.map +1 -1
- package/dist/commands/siem.d.ts.map +1 -1
- package/dist/commands/siem.js.map +1 -1
- package/dist/commands/skill.d.ts +52 -1
- package/dist/commands/skill.d.ts.map +1 -1
- package/dist/commands/skill.js +147 -40
- package/dist/commands/skill.js.map +1 -1
- package/dist/commands/sops.d.ts +61 -50
- package/dist/commands/sops.d.ts.map +1 -1
- package/dist/commands/sops.js +425 -166
- package/dist/commands/sops.js.map +1 -1
- package/dist/commands/start.d.ts.map +1 -1
- package/dist/commands/start.js +2 -1
- package/dist/commands/start.js.map +1 -1
- package/dist/commands/status.d.ts.map +1 -1
- package/dist/commands/status.js +2 -1
- package/dist/commands/status.js.map +1 -1
- package/dist/commands/traces.d.ts.map +1 -1
- package/dist/commands/traces.js +4 -3
- package/dist/commands/traces.js.map +1 -1
- package/dist/config/paths.d.ts +15 -9
- package/dist/config/paths.d.ts.map +1 -1
- package/dist/config/paths.js +24 -10
- package/dist/config/paths.js.map +1 -1
- package/dist/harness/ag2.d.ts +4 -2
- package/dist/harness/ag2.d.ts.map +1 -1
- package/dist/harness/ag2.js +4 -2
- package/dist/harness/ag2.js.map +1 -1
- package/dist/harness/autogen.d.ts +10 -11
- package/dist/harness/autogen.d.ts.map +1 -1
- package/dist/harness/autogen.js +14 -15
- package/dist/harness/autogen.js.map +1 -1
- package/dist/harness/detector.d.ts.map +1 -1
- package/dist/harness/detector.js +5 -2
- package/dist/harness/detector.js.map +1 -1
- package/dist/harness/windsurf.d.ts.map +1 -1
- package/dist/harness/windsurf.js +4 -2
- package/dist/harness/windsurf.js.map +1 -1
- package/dist/lib/api.d.ts +7 -3
- package/dist/lib/api.d.ts.map +1 -1
- package/dist/lib/caTrust.d.ts +43 -1
- package/dist/lib/caTrust.d.ts.map +1 -1
- package/dist/lib/caTrust.js +109 -9
- package/dist/lib/caTrust.js.map +1 -1
- package/dist/lib/ciscoScanner.d.ts +9 -4
- package/dist/lib/ciscoScanner.d.ts.map +1 -1
- package/dist/lib/ciscoScanner.js +42 -8
- package/dist/lib/ciscoScanner.js.map +1 -1
- package/dist/lib/decisionsLogRefresh.d.ts.map +1 -1
- package/dist/lib/decisionsLogRefresh.js +6 -2
- package/dist/lib/decisionsLogRefresh.js.map +1 -1
- package/dist/lib/enforcementState.d.ts +7 -0
- package/dist/lib/enforcementState.d.ts.map +1 -1
- package/dist/lib/enforcementState.js +9 -0
- package/dist/lib/enforcementState.js.map +1 -1
- package/dist/lib/mdmManifest.d.ts.map +1 -1
- package/dist/lib/mdmManifest.js +33 -3
- package/dist/lib/mdmManifest.js.map +1 -1
- package/dist/lib/proxyBinary.d.ts +11 -0
- package/dist/lib/proxyBinary.d.ts.map +1 -1
- package/dist/lib/proxyBinary.js +16 -0
- package/dist/lib/proxyBinary.js.map +1 -1
- package/dist/lib/sopFrontMatter.d.ts +35 -0
- package/dist/lib/sopFrontMatter.d.ts.map +1 -1
- package/dist/lib/sopFrontMatter.js +60 -0
- package/dist/lib/sopFrontMatter.js.map +1 -1
- package/package.json +5 -5
- package/resources/sandbox/firecracker-launch.sh +8 -7
package/dist/commands/sops.d.ts
CHANGED
|
@@ -1,74 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What `sops push <name>` reads: the folder `.intutic/sops/<name>/` when
|
|
3
|
+
* there is one, else the single file `.intutic/sops/<name>.md` (or `<name>`
|
|
4
|
+
* given with its `.md`). The file form is the layout `sops pull` writes and
|
|
5
|
+
* the proxy enforces, so a pulled, edited SOP pushes back by its file name.
|
|
6
|
+
*/
|
|
7
|
+
export declare function resolvePushTarget(sopsRoot: string, name: string): Promise<{
|
|
8
|
+
dir: string;
|
|
9
|
+
files: string[];
|
|
10
|
+
} | {
|
|
11
|
+
error: string;
|
|
12
|
+
}>;
|
|
1
13
|
/**
|
|
2
14
|
* `intutic sops push <name>` — one control-plane SOP per file under
|
|
3
|
-
* `.intutic/sops/<name>/*.md
|
|
4
|
-
* `title:`/`risk_tier:`/`version:`
|
|
5
|
-
*
|
|
15
|
+
* `.intutic/sops/<name>/*.md` (or the single file `.intutic/sops/<name>.md`),
|
|
16
|
+
* each carrying that file's own declared `title:`/`risk_tier:`/`version:`
|
|
17
|
+
* front matter.
|
|
6
18
|
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* `
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
19
|
+
* A file that records the SOP it was synced with (`intutic_id:`, written by
|
|
20
|
+
* `sops pull` and by a previous push) updates that SOP in place through
|
|
21
|
+
* `PUT /api/v1/sops/:id`, the same edit path as the dashboard: a DRAFT is
|
|
22
|
+
* edited in place, and an approved SOP gets a new DRAFT version while the
|
|
23
|
+
* approved one keeps enforcing until the draft is promoted. The recorded
|
|
24
|
+
* `intutic_revision:` goes along as `version_counter`, so an edit made on the
|
|
25
|
+
* server since the file was synced is refused (409) instead of overwritten;
|
|
26
|
+
* `--force` sends the server's current counter instead. A file with no record
|
|
27
|
+
* creates a new SOP. Either way, a successful push writes the SOP's id and
|
|
28
|
+
* counter back into the file's front matter (a forked DRAFT's id, when the
|
|
29
|
+
* edit forked one), keeping every other line of the file.
|
|
14
30
|
*
|
|
15
|
-
* Front matter is stripped before the body is sent as `
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* Declarative enforcement keys (`deny_tools:`, `requires_before:`, ...) have
|
|
20
|
-
* no `sop_registry` column, so they are lost from the DB-plane row exactly
|
|
21
|
-
* as they always were — this fixes what already had somewhere to go
|
|
22
|
-
* (title, risk tier, version), not what does not.
|
|
31
|
+
* Front matter is stripped before the body is sent as `markdown_content` —
|
|
32
|
+
* the judge reads that field verbatim. Declarative enforcement keys
|
|
33
|
+
* (`deny_tools:`, `requires_before:`, ...) have no `sop_registry` column, so
|
|
34
|
+
* they stay file-plane only.
|
|
23
35
|
*/
|
|
24
36
|
export declare function runSopsPush(name: string, opts: {
|
|
25
37
|
dev?: boolean;
|
|
26
38
|
org?: boolean;
|
|
39
|
+
force?: boolean;
|
|
40
|
+
create?: boolean;
|
|
27
41
|
}): Promise<void>;
|
|
28
42
|
/**
|
|
29
|
-
* `intutic sops pull` —
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
* `
|
|
43
|
+
* `intutic sops pull` — every workspace SOP on the control plane, written
|
|
44
|
+
* with front matter reconstructed from the row (`title:`, `risk_tier:`,
|
|
45
|
+
* `version:`) plus the sync record `sops push` reads: `intutic_id:` (the
|
|
46
|
+
* SOP) and `intutic_revision:` (its `version_counter`).
|
|
47
|
+
*
|
|
48
|
+
* A SOP lands in the local file that already records its id — flat or in a
|
|
49
|
+
* `<name>/` folder — and otherwise in `.intutic/sops/<slug-of-title>.md`. An
|
|
50
|
+
* existing file keeps its other front-matter lines (the enforcing keys the
|
|
51
|
+
* proxy reads); only the synced keys and the body are replaced. An approved
|
|
52
|
+
* version is skipped when a local file already tracks its DRAFT successor,
|
|
53
|
+
* so a push that forked a draft does not come back as a second file.
|
|
33
54
|
*
|
|
34
55
|
* Refuses to overwrite a file it did not itself write most recently, unless
|
|
35
56
|
* `--force` is passed. The check is a recorded hash, not a live diff: every
|
|
36
|
-
* file this command writes carries `content_hash: sha256(body)
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
* pull; a match means nothing local changed, so pulling fresh content from
|
|
41
|
-
* the plane (which may itself have changed) is safe. A file with no
|
|
42
|
-
* recorded hash at all — hand-authored, or only ever pushed — is treated as
|
|
43
|
-
* unverifiable and always requires `--force`, since overwriting a
|
|
44
|
-
* hand-written SOP the first time this command sees it would be the
|
|
45
|
-
* expensive direction to get wrong.
|
|
57
|
+
* file this command writes carries `content_hash: sha256(body)`, and a later
|
|
58
|
+
* pull compares that against the CURRENT local body's hash. A mismatch means
|
|
59
|
+
* a human edited the file since; a file with no recorded hash at all —
|
|
60
|
+
* hand-authored — is treated as unverifiable and always requires `--force`.
|
|
46
61
|
*/
|
|
47
62
|
export declare function runSopsPull(opts: {
|
|
48
63
|
dev?: boolean;
|
|
49
64
|
force?: boolean;
|
|
50
65
|
}): Promise<void>;
|
|
51
66
|
/**
|
|
52
|
-
* `intutic sops status` — drift between
|
|
53
|
-
* control plane, read-only against the file
|
|
54
|
-
*
|
|
67
|
+
* `intutic sops status` — drift between the local SOP files (flat and
|
|
68
|
+
* `<name>/` folders) and the control plane, read-only against the file
|
|
69
|
+
* system.
|
|
55
70
|
*
|
|
56
|
-
*
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
* edited after an old pull"
|
|
71
|
+
* A file that records its SOP (`intutic_id:`) is compared with that SOP; a
|
|
72
|
+
* file without one is matched by title, the heuristic `pull` used before
|
|
73
|
+
* files carried ids. `intutic_revision:` tells whether the server moved since
|
|
74
|
+
* the file was synced, so a file edited on both sides reports `diverged`
|
|
75
|
+
* rather than `local-ahead`. A file with no `content_hash:` marker cannot be
|
|
76
|
+
* told apart as "never pulled" or "edited after an old pull", so it reports
|
|
77
|
+
* `diverged` when its content differs.
|
|
62
78
|
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
*
|
|
66
|
-
*
|
|
67
|
-
* second project", per `apps/docs/guide/gitops-sops.md`), but a human or CI
|
|
68
|
-
* job running this command on a schedule now leaves the compliance probe
|
|
69
|
-
* (`sop_git_drift`) something to read instead of nothing. Report failures
|
|
70
|
-
* never fail the command — the read-only status output above is already
|
|
71
|
-
* complete and correct on its own.
|
|
79
|
+
* Every matched (non-`push-only`) result is reported to
|
|
80
|
+
* `POST /api/v1/sops/git-drift-report`, best-effort, so the compliance probe
|
|
81
|
+
* (`sop_git_drift`) has something to read. Report failures never fail the
|
|
82
|
+
* command.
|
|
72
83
|
*/
|
|
73
84
|
export declare function runSopsStatus(opts: {
|
|
74
85
|
dev?: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sops.d.ts","sourceRoot":"","sources":["../../src/commands/sops.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sops.d.ts","sourceRoot":"","sources":["../../src/commands/sops.ts"],"names":[],"mappings":"AA6BA;;;;;GAKG;AACH,wBAAsB,iBAAiB,CACrC,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,GACX,OAAO,CAAC;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GAAG;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CAkB/D;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAsB,WAAW,CAC/B,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE;IAAE,GAAG,CAAC,EAAE,OAAO,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAC;IAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IAAC,MAAM,CAAC,EAAE,OAAO,CAAA;CAAE,GACxE,OAAO,CAAC,IAAI,CAAC,CAgCf;AAiWD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAsB,WAAW,CAAC,IAAI,EAAE;IAAE,GAAG,CAAC,EAAE,OAAO,CAAC;IAAC,KAAK,CAAC,EAAE,OAAO,CAAA;CAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CA+GzF;AAID;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,aAAa,CAAC,IAAI,EAAE;IAAE,GAAG,CAAC,EAAE,OAAO,CAAA;CAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAoG1E;AAUD;;;;;;;;GAQG;AACH,wBAAsB,cAAc,CAAC,IAAI,EAAE;IAAE,GAAG,CAAC,EAAE,OAAO,CAAA;CAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAuB3E;AAED;;;;;;;GAOG;AACH,wBAAsB,YAAY,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE;IAAE,GAAG,CAAC,EAAE,OAAO,CAAA;CAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAa3F"}
|