@openai/codex-security 0.1.21 → 0.1.23
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 +529 -0
- package/_bundled_plugin/.codex-plugin/plugin.json +1 -1
- package/_bundled_plugin/mcp/server.mjs.br.part-000 +0 -0
- package/_bundled_plugin/mcp/server.mjs.br.part-001 +0 -0
- package/_bundled_plugin/references/config-preflight.md +2 -30
- package/_bundled_plugin/references/core-scan.md +1 -1
- package/_bundled_plugin/references/final-report.md +1 -1
- package/_bundled_plugin/references/finding-detail-fields.md +5 -10
- package/_bundled_plugin/references/sarif-adapter.md +1 -1
- package/_bundled_plugin/scripts/config_preflight.py +2 -8
- package/_bundled_plugin/scripts/finalize_scan_contract.py +114 -24
- package/_bundled_plugin/scripts/finding_preview.py +22 -4
- package/_bundled_plugin/scripts/generate_in_scope_files.py +27 -1
- package/_bundled_plugin/scripts/windows_scan_local_files.py +101 -7
- package/_bundled_plugin/scripts/workbench_cli.py +21 -1
- package/_bundled_plugin/scripts/workbench_dashboard.py +115 -0
- package/_bundled_plugin/scripts/workbench_db.py +29 -2
- package/_bundled_plugin/scripts/workbench_finding_index.py +42 -24
- package/_bundled_plugin/scripts/workbench_finding_workflows.py +190 -0
- package/_bundled_plugin/scripts/workbench_findings.py +216 -0
- package/_bundled_plugin/scripts/workbench_saved_results.py +30 -5
- package/_bundled_plugin/scripts/workbench_schema.py +263 -58
- package/_bundled_plugin/scripts/workbench_target.py +22 -3
- package/_bundled_plugin/skills/track-findings/SKILL.md +2 -0
- package/dist/api.d.ts +2 -0
- package/dist/api.d.ts.map +1 -1
- package/dist/api.js +115 -27
- package/dist/api.js.map +1 -1
- package/dist/cli.d.ts +4 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +124 -58
- package/dist/cli.js.map +1 -1
- package/dist/cloud-publish.js +5 -1
- package/dist/cloud-publish.js.map +1 -1
- package/dist/contract.d.ts +1 -0
- package/dist/contract.d.ts.map +1 -1
- package/dist/contract.js +9 -0
- package/dist/contract.js.map +1 -1
- package/dist/custom-publish.d.ts +22 -0
- package/dist/custom-publish.d.ts.map +1 -0
- package/dist/custom-publish.js +47 -0
- package/dist/custom-publish.js.map +1 -0
- package/dist/custom-validation-prompt.js +1 -1
- package/dist/custom-validation-prompt.js.map +1 -1
- package/dist/deduplication/checkpointed-review.d.ts +16 -0
- package/dist/deduplication/checkpointed-review.d.ts.map +1 -0
- package/dist/deduplication/checkpointed-review.js +76 -0
- package/dist/deduplication/checkpointed-review.js.map +1 -0
- package/dist/deduplication/codex-review.d.ts +21 -0
- package/dist/deduplication/codex-review.d.ts.map +1 -0
- package/dist/deduplication/codex-review.js +252 -0
- package/dist/deduplication/codex-review.js.map +1 -0
- package/dist/deduplication/deduplication-prompts.d.ts +8 -0
- package/dist/deduplication/deduplication-prompts.d.ts.map +1 -0
- package/dist/deduplication/deduplication-prompts.js +35 -0
- package/dist/deduplication/deduplication-prompts.js.map +1 -0
- package/dist/deduplication/deduplication-reviewer.d.ts +46 -0
- package/dist/deduplication/deduplication-reviewer.d.ts.map +1 -0
- package/dist/deduplication/deduplication-reviewer.js +105 -0
- package/dist/deduplication/deduplication-reviewer.js.map +1 -0
- package/dist/deduplication/deduplication.d.ts +6 -0
- package/dist/deduplication/deduplication.d.ts.map +1 -0
- package/dist/deduplication/deduplication.js +85 -0
- package/dist/deduplication/deduplication.js.map +1 -0
- package/dist/deduplication/scan.d.ts +16 -0
- package/dist/deduplication/scan.d.ts.map +1 -0
- package/dist/deduplication/scan.js +101 -0
- package/dist/deduplication/scan.js.map +1 -0
- package/dist/finding-dedupe-groups.d.ts +7 -0
- package/dist/finding-dedupe-groups.d.ts.map +1 -0
- package/dist/finding-dedupe-groups.js +2 -0
- package/dist/finding-dedupe-groups.js.map +1 -0
- package/dist/finding-retrieval.d.ts +13 -0
- package/dist/finding-retrieval.d.ts.map +1 -0
- package/dist/finding-retrieval.js +2 -0
- package/dist/finding-retrieval.js.map +1 -0
- package/dist/finding-workflow.d.ts +53 -0
- package/dist/finding-workflow.d.ts.map +1 -0
- package/dist/finding-workflow.js +117 -0
- package/dist/finding-workflow.js.map +1 -0
- package/dist/findings-client.d.ts +15 -0
- package/dist/findings-client.d.ts.map +1 -0
- package/dist/findings-client.js +60 -0
- package/dist/findings-client.js.map +1 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/publication.js +28 -40
- package/dist/publication.js.map +1 -1
- package/dist/runtime.d.ts +5 -1
- package/dist/runtime.d.ts.map +1 -1
- package/dist/runtime.js +113 -12
- package/dist/runtime.js.map +1 -1
- package/dist/saved-scan.d.ts +15 -0
- package/dist/saved-scan.d.ts.map +1 -0
- package/dist/saved-scan.js +68 -0
- package/dist/saved-scan.js.map +1 -0
- package/dist/scan-comparison.d.ts +3 -2
- package/dist/scan-comparison.d.ts.map +1 -1
- package/dist/scan-comparison.js +1 -1
- package/dist/scan-comparison.js.map +1 -1
- package/dist/server/dashboard/THIRD_PARTY_NOTICES.txt +276 -0
- package/dist/server/dashboard/app.css +2 -0
- package/dist/server/dashboard/app.js +66 -0
- package/dist/server/dashboard/index.html +18 -0
- package/dist/server/dashboard-types.d.ts +45 -0
- package/dist/server/dashboard-types.d.ts.map +1 -0
- package/dist/server/dashboard-types.js +2 -0
- package/dist/server/dashboard-types.js.map +1 -0
- package/dist/server/dashboard.d.ts +6 -0
- package/dist/server/dashboard.d.ts.map +1 -0
- package/dist/server/dashboard.js +45 -0
- package/dist/server/dashboard.js.map +1 -0
- package/dist/server/embeddings.d.ts +16 -0
- package/dist/server/embeddings.d.ts.map +1 -0
- package/dist/server/embeddings.js +114 -0
- package/dist/server/embeddings.js.map +1 -0
- package/dist/server/errors.d.ts +5 -0
- package/dist/server/errors.d.ts.map +1 -0
- package/dist/server/errors.js +8 -0
- package/dist/server/errors.js.map +1 -0
- package/dist/server/findings-service.d.ts +20 -0
- package/dist/server/findings-service.d.ts.map +1 -0
- package/dist/server/findings-service.js +31 -0
- package/dist/server/findings-service.js.map +1 -0
- package/dist/server/index.d.ts +2 -0
- package/dist/server/index.d.ts.map +1 -0
- package/dist/server/index.js +32 -0
- package/dist/server/index.js.map +1 -0
- package/dist/server/routes.d.ts +6 -0
- package/dist/server/routes.d.ts.map +1 -0
- package/dist/server/routes.js +86 -0
- package/dist/server/routes.js.map +1 -0
- package/dist/server/server.d.ts +10 -0
- package/dist/server/server.d.ts.map +1 -0
- package/dist/server/server.js +17 -0
- package/dist/server/server.js.map +1 -0
- package/dist/server/sqlite-store.d.ts +22 -0
- package/dist/server/sqlite-store.d.ts.map +1 -0
- package/dist/server/sqlite-store.js +82 -0
- package/dist/server/sqlite-store.js.map +1 -0
- package/dist/server/storage.d.ts +32 -0
- package/dist/server/storage.d.ts.map +1 -0
- package/dist/server/storage.js +2 -0
- package/dist/server/storage.js.map +1 -0
- package/dist/server/validation.d.ts +17 -0
- package/dist/server/validation.d.ts.map +1 -0
- package/dist/server/validation.js +53 -0
- package/dist/server/validation.js.map +1 -0
- package/dist/trusted-executable.d.ts.map +1 -1
- package/dist/trusted-executable.js +2 -1
- package/dist/trusted-executable.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/version.js.map +1 -1
- package/package.json +17 -5
|
@@ -150,6 +150,10 @@ def _worker_candidate_key(
|
|
|
150
150
|
if isinstance(provenance, dict)
|
|
151
151
|
else finding.get("identity")
|
|
152
152
|
)
|
|
153
|
+
if not isinstance(identity, dict):
|
|
154
|
+
normalized = dict(finding)
|
|
155
|
+
_ensure_finding_identity(normalized)
|
|
156
|
+
identity = normalized.get("identity")
|
|
153
157
|
anchor = identity.get("anchor") if isinstance(identity, dict) else None
|
|
154
158
|
instance = identity.get("instance") if isinstance(identity, dict) else None
|
|
155
159
|
return worker_id, candidate_id, finding.get("ruleId"), anchor, instance
|
|
@@ -215,12 +219,13 @@ def merge_saved_results(
|
|
|
215
219
|
stopped: bool,
|
|
216
220
|
reason: str,
|
|
217
221
|
frozen_source_digests: dict[str, str] | None = None,
|
|
222
|
+
allow_frozen_legacy_parent: bool = False,
|
|
218
223
|
) -> tuple[dict[str, Any], dict[str, Any], dict[str, Any]] | None:
|
|
219
224
|
"""Read only bound parent/worker files; return an unsealed loss-preserving union."""
|
|
220
225
|
initial_warnings = set(warnings)
|
|
221
226
|
parent: dict[str, Any] | None = None
|
|
222
227
|
parent_manifest: dict[str, Any] | None = None
|
|
223
|
-
if frozen_source_digests is None:
|
|
228
|
+
if frozen_source_digests is None or allow_frozen_legacy_parent:
|
|
224
229
|
try:
|
|
225
230
|
parent_manifest = _read_scan_local_json(
|
|
226
231
|
scan_dir, "scan-manifest.json", "Saved parent manifest"
|
|
@@ -587,7 +592,9 @@ def merge_saved_results(
|
|
|
587
592
|
and coverage.get("completeness") in {"complete", "unknown"}
|
|
588
593
|
):
|
|
589
594
|
coverage["completeness"] = "partial"
|
|
590
|
-
if superseded and not stopped
|
|
595
|
+
if superseded and not stopped and all(
|
|
596
|
+
valid_finding(finding) for finding in (parent["findings"] if parent else [])
|
|
597
|
+
):
|
|
591
598
|
continue
|
|
592
599
|
if "threatModel" not in manifest["scan"] and isinstance(draft.get("threatModel"), dict):
|
|
593
600
|
manifest["scan"]["threatModel"] = copy.deepcopy(draft["threatModel"])
|
|
@@ -668,9 +675,7 @@ def merge_saved_results(
|
|
|
668
675
|
mapped_key = represented[key]
|
|
669
676
|
historical_contents = represented_history.get(key, set())
|
|
670
677
|
elif worker_id and candidate_id:
|
|
671
|
-
candidate_key = _worker_candidate_key(
|
|
672
|
-
worker_id, candidate_id, finding
|
|
673
|
-
)
|
|
678
|
+
candidate_key = _worker_candidate_key(worker_id, candidate_id, finding)
|
|
674
679
|
if candidate_key not in represented_candidates:
|
|
675
680
|
represented_candidates[candidate_key] = key
|
|
676
681
|
mapped_key = represented_candidates[candidate_key]
|
|
@@ -1002,6 +1007,12 @@ def preserve_scan_results_locked(db: Any, connection: Any, scan_id: str) -> bool
|
|
|
1002
1007
|
f"{scan['failure_message'] or ''}"
|
|
1003
1008
|
).strip(),
|
|
1004
1009
|
frozen_source_digests=frozen_source_digests,
|
|
1010
|
+
allow_frozen_legacy_parent=(
|
|
1011
|
+
frozen_source_digests == {}
|
|
1012
|
+
and isinstance(existing_scan, dict)
|
|
1013
|
+
and existing_scan.get("sealedAt") is not None
|
|
1014
|
+
and "preservedSources" not in existing_scan
|
|
1015
|
+
),
|
|
1005
1016
|
)
|
|
1006
1017
|
if documents is None:
|
|
1007
1018
|
unpublished_warnings = list(dict.fromkeys([*warnings, *publication_follow_up_warnings]))
|
|
@@ -1013,6 +1024,20 @@ def preserve_scan_results_locked(db: Any, connection: Any, scan_id: str) -> bool
|
|
|
1013
1024
|
(json.dumps(unpublished_warnings), db.now(), scan_id),
|
|
1014
1025
|
)
|
|
1015
1026
|
return False
|
|
1027
|
+
if frozen_source_digests is None:
|
|
1028
|
+
retained_sources = documents[0].get("scan", {}).get("preservedSources")
|
|
1029
|
+
if not isinstance(retained_sources, dict) or not all(
|
|
1030
|
+
isinstance(relative, str) and isinstance(digest, str)
|
|
1031
|
+
for relative, digest in retained_sources.items()
|
|
1032
|
+
):
|
|
1033
|
+
raise ContractError("Stopped scan source digests could not be frozen.")
|
|
1034
|
+
frozen_source_digests = retained_sources
|
|
1035
|
+
with connection:
|
|
1036
|
+
connection.execute(
|
|
1037
|
+
"UPDATE scans SET retained_source_digests_json = ? "
|
|
1038
|
+
"WHERE id = ? AND retained_source_digests_json IS NULL",
|
|
1039
|
+
(json.dumps(retained_sources, sort_keys=True), scan_id),
|
|
1040
|
+
)
|
|
1016
1041
|
prepared = _prepare_scan_finalization(
|
|
1017
1042
|
scan_dir,
|
|
1018
1043
|
expected_coverage_mode=db.expected_coverage_mode(scan),
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"""SQLite schema history for the Codex Security workbench."""
|
|
2
2
|
|
|
3
3
|
import argparse
|
|
4
|
+
import json
|
|
4
5
|
import sqlite3
|
|
5
6
|
from collections.abc import Callable
|
|
6
7
|
|
|
@@ -697,9 +698,186 @@ MIGRATIONS = (
|
|
|
697
698
|
ALTER TABLE deep_scan_runs ADD COLUMN publication_error_message TEXT;
|
|
698
699
|
""",
|
|
699
700
|
),
|
|
701
|
+
(
|
|
702
|
+
33,
|
|
703
|
+
"store complete findings and embeddings without a scan",
|
|
704
|
+
"""
|
|
705
|
+
ALTER TABLE findings ADD COLUMN details_json TEXT;
|
|
706
|
+
|
|
707
|
+
UPDATE findings SET details_json = (
|
|
708
|
+
SELECT details_json FROM finding_occurrences
|
|
709
|
+
WHERE finding_id = findings.id AND details_json != '{}'
|
|
710
|
+
ORDER BY created_at DESC, id DESC LIMIT 1
|
|
711
|
+
);
|
|
712
|
+
|
|
713
|
+
CREATE TABLE finding_embeddings (
|
|
714
|
+
finding_id TEXT PRIMARY KEY REFERENCES findings(id) ON DELETE CASCADE,
|
|
715
|
+
model TEXT NOT NULL,
|
|
716
|
+
vector_json TEXT NOT NULL
|
|
717
|
+
);
|
|
718
|
+
|
|
719
|
+
CREATE TRIGGER invalidate_finding_embedding
|
|
720
|
+
AFTER UPDATE OF details_json ON findings
|
|
721
|
+
WHEN OLD.details_json IS NOT NEW.details_json
|
|
722
|
+
BEGIN
|
|
723
|
+
DELETE FROM finding_embeddings WHERE finding_id = NEW.id;
|
|
724
|
+
END;
|
|
725
|
+
""",
|
|
726
|
+
),
|
|
727
|
+
(
|
|
728
|
+
34,
|
|
729
|
+
"associate findings with repositories",
|
|
730
|
+
"""
|
|
731
|
+
CREATE TABLE finding_repositories (
|
|
732
|
+
repository_id TEXT NOT NULL,
|
|
733
|
+
finding_id TEXT NOT NULL REFERENCES findings(id) ON DELETE CASCADE,
|
|
734
|
+
PRIMARY KEY (repository_id, finding_id)
|
|
735
|
+
);
|
|
736
|
+
|
|
737
|
+
INSERT OR IGNORE INTO finding_repositories (repository_id, finding_id)
|
|
738
|
+
SELECT scans.target_id, finding_occurrences.finding_id
|
|
739
|
+
FROM finding_occurrences JOIN scans ON scans.id = finding_occurrences.scan_id
|
|
740
|
+
WHERE scans.target_id IS NOT NULL;
|
|
741
|
+
""",
|
|
742
|
+
),
|
|
743
|
+
(
|
|
744
|
+
35,
|
|
745
|
+
"persist finding dedupe groups",
|
|
746
|
+
"""
|
|
747
|
+
CREATE TABLE finding_dedupe_groups (
|
|
748
|
+
id TEXT PRIMARY KEY,
|
|
749
|
+
created_at TEXT NOT NULL
|
|
750
|
+
);
|
|
751
|
+
|
|
752
|
+
CREATE TABLE finding_dedupe_group_members (
|
|
753
|
+
group_id TEXT NOT NULL REFERENCES finding_dedupe_groups(id) ON DELETE CASCADE,
|
|
754
|
+
finding_id TEXT NOT NULL REFERENCES findings(id),
|
|
755
|
+
PRIMARY KEY (group_id, finding_id)
|
|
756
|
+
);
|
|
757
|
+
|
|
758
|
+
CREATE INDEX finding_dedupe_groups_by_finding
|
|
759
|
+
ON finding_dedupe_group_members(finding_id, group_id);
|
|
760
|
+
""",
|
|
761
|
+
),
|
|
762
|
+
(
|
|
763
|
+
36,
|
|
764
|
+
"persist local findings workflows",
|
|
765
|
+
"""
|
|
766
|
+
CREATE TABLE finding_workflows (
|
|
767
|
+
id TEXT PRIMARY KEY,
|
|
768
|
+
state_json TEXT NOT NULL,
|
|
769
|
+
created_at TEXT NOT NULL,
|
|
770
|
+
updated_at TEXT NOT NULL
|
|
771
|
+
);
|
|
772
|
+
""",
|
|
773
|
+
),
|
|
774
|
+
(
|
|
775
|
+
37,
|
|
776
|
+
"checkpoint validated dedupe reviews",
|
|
777
|
+
"""
|
|
778
|
+
CREATE TABLE finding_workflow_reviews (
|
|
779
|
+
workflow_id TEXT NOT NULL REFERENCES finding_workflows(id) ON DELETE CASCADE,
|
|
780
|
+
review_key TEXT NOT NULL,
|
|
781
|
+
binding_json TEXT NOT NULL,
|
|
782
|
+
result_json TEXT NOT NULL,
|
|
783
|
+
created_at TEXT NOT NULL,
|
|
784
|
+
PRIMARY KEY (workflow_id, review_key)
|
|
785
|
+
);
|
|
786
|
+
""",
|
|
787
|
+
),
|
|
788
|
+
(
|
|
789
|
+
38,
|
|
790
|
+
"store findings workflow metadata in columns",
|
|
791
|
+
"""
|
|
792
|
+
ALTER TABLE finding_workflows RENAME COLUMN state_json TO results_json;
|
|
793
|
+
ALTER TABLE finding_workflows ADD COLUMN repository_path TEXT;
|
|
794
|
+
ALTER TABLE finding_workflows ADD COLUMN scan_request_digest TEXT;
|
|
795
|
+
ALTER TABLE finding_workflows ADD COLUMN scan_id TEXT;
|
|
796
|
+
ALTER TABLE finding_workflows ADD COLUMN scan_dir TEXT;
|
|
797
|
+
ALTER TABLE finding_workflows ADD COLUMN artifact_digest TEXT;
|
|
798
|
+
ALTER TABLE finding_workflows ADD COLUMN destination TEXT;
|
|
799
|
+
ALTER TABLE finding_workflows ADD COLUMN scope_repository_id TEXT;
|
|
800
|
+
ALTER TABLE finding_workflows ADD COLUMN scope_all_repositories INTEGER;
|
|
801
|
+
ALTER TABLE finding_workflows ADD COLUMN scan_status TEXT NOT NULL DEFAULT 'pending';
|
|
802
|
+
ALTER TABLE finding_workflows ADD COLUMN scan_error TEXT;
|
|
803
|
+
ALTER TABLE finding_workflows ADD COLUMN publish_status TEXT NOT NULL DEFAULT 'pending';
|
|
804
|
+
ALTER TABLE finding_workflows ADD COLUMN publish_error TEXT;
|
|
805
|
+
ALTER TABLE finding_workflows ADD COLUMN dedupe_status TEXT NOT NULL DEFAULT 'pending';
|
|
806
|
+
ALTER TABLE finding_workflows ADD COLUMN dedupe_error TEXT;
|
|
807
|
+
""",
|
|
808
|
+
),
|
|
809
|
+
(
|
|
810
|
+
39,
|
|
811
|
+
"store dedupe checkpoint bindings in columns",
|
|
812
|
+
"""
|
|
813
|
+
ALTER TABLE finding_workflow_reviews RENAME COLUMN binding_json TO prompt_digest;
|
|
814
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN review_contract_version INTEGER;
|
|
815
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN codex_version TEXT;
|
|
816
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN source_repository_path TEXT;
|
|
817
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN source_revision TEXT;
|
|
818
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN source_refs_digest TEXT;
|
|
819
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN source_content_digest TEXT;
|
|
820
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN scope_repository_id TEXT;
|
|
821
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN scope_all_repositories INTEGER;
|
|
822
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN model TEXT;
|
|
823
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN effort TEXT;
|
|
824
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN settings_digest TEXT;
|
|
825
|
+
ALTER TABLE finding_workflow_reviews ADD COLUMN contract_digest TEXT;
|
|
826
|
+
""",
|
|
827
|
+
),
|
|
700
828
|
)
|
|
701
829
|
|
|
702
830
|
|
|
831
|
+
def migrate_finding_workflow_review_columns(connection: sqlite3.Connection) -> None:
|
|
832
|
+
for row in connection.execute(
|
|
833
|
+
"SELECT workflow_id, review_key, prompt_digest FROM finding_workflow_reviews"
|
|
834
|
+
).fetchall():
|
|
835
|
+
binding = json.loads(row["prompt_digest"])
|
|
836
|
+
source = binding["source"]
|
|
837
|
+
scope = binding["scope"]
|
|
838
|
+
connection.execute(
|
|
839
|
+
"""UPDATE finding_workflow_reviews SET review_contract_version = ?, codex_version = ?,
|
|
840
|
+
source_repository_path = ?, source_revision = ?, source_refs_digest = ?,
|
|
841
|
+
source_content_digest = ?, scope_repository_id = ?, scope_all_repositories = ?,
|
|
842
|
+
model = ?, effort = ?, settings_digest = ?, prompt_digest = ?, contract_digest = ?
|
|
843
|
+
WHERE workflow_id = ? AND review_key = ?""",
|
|
844
|
+
(
|
|
845
|
+
binding["version"], binding["codexVersion"], source["repository"],
|
|
846
|
+
source["revision"], source["refsDigest"], source["content"],
|
|
847
|
+
scope.get("repositoryId"), scope.get("allRepositories"), binding["model"],
|
|
848
|
+
binding["effort"], binding.get("settingsDigest"), binding["promptDigest"],
|
|
849
|
+
binding["contractDigest"], row["workflow_id"], row["review_key"],
|
|
850
|
+
),
|
|
851
|
+
)
|
|
852
|
+
|
|
853
|
+
|
|
854
|
+
def migrate_finding_workflow_columns(connection: sqlite3.Connection) -> None:
|
|
855
|
+
# Rename/backfill in place so existing checkpoint foreign keys and rows survive.
|
|
856
|
+
for row in connection.execute("SELECT id, results_json FROM finding_workflows").fetchall():
|
|
857
|
+
state = json.loads(row["results_json"])
|
|
858
|
+
scope = state.get("scope", {})
|
|
859
|
+
stages = state["stages"]
|
|
860
|
+
results = {stage: value["result"] for stage, value in stages.items() if "result" in value}
|
|
861
|
+
if "pendingWrite" in stages["dedupe"]:
|
|
862
|
+
results["dedupePendingWrite"] = stages["dedupe"]["pendingWrite"]
|
|
863
|
+
connection.execute(
|
|
864
|
+
"""UPDATE finding_workflows SET
|
|
865
|
+
repository_path = ?, scan_request_digest = ?, scan_id = ?, scan_dir = ?,
|
|
866
|
+
artifact_digest = ?, destination = ?, scope_repository_id = ?, scope_all_repositories = ?,
|
|
867
|
+
scan_status = ?, scan_error = ?, publish_status = ?, publish_error = ?,
|
|
868
|
+
dedupe_status = ?, dedupe_error = ?, results_json = ? WHERE id = ?""",
|
|
869
|
+
(
|
|
870
|
+
state.get("repositoryPath"), state.get("scanRequestDigest"),
|
|
871
|
+
state.get("scanId"), state.get("scanDir"), state.get("artifactDigest"),
|
|
872
|
+
state.get("destination"), scope.get("repositoryId"), scope.get("allRepositories"),
|
|
873
|
+
stages["scan"]["status"], stages["scan"].get("error"),
|
|
874
|
+
stages["publish"]["status"], stages["publish"].get("error"),
|
|
875
|
+
stages["dedupe"]["status"], stages["dedupe"].get("error"),
|
|
876
|
+
json.dumps(results, allow_nan=False), row["id"],
|
|
877
|
+
),
|
|
878
|
+
)
|
|
879
|
+
|
|
880
|
+
|
|
703
881
|
def apply_migrations(
|
|
704
882
|
connection: sqlite3.Connection,
|
|
705
883
|
migrations: tuple[tuple[int, str, str], ...],
|
|
@@ -780,6 +958,10 @@ def apply_migrations(
|
|
|
780
958
|
else:
|
|
781
959
|
for statement in sql_statements(sql):
|
|
782
960
|
connection.execute(statement)
|
|
961
|
+
if version == 38:
|
|
962
|
+
migrate_finding_workflow_columns(connection)
|
|
963
|
+
elif version == 39:
|
|
964
|
+
migrate_finding_workflow_review_columns(connection)
|
|
783
965
|
connection.execute(
|
|
784
966
|
"INSERT INTO schema_migrations (version, name, applied_at) VALUES (?, ?, ?)",
|
|
785
967
|
(version, name, now()),
|
|
@@ -797,19 +979,30 @@ def apply_migrations(
|
|
|
797
979
|
def normalize_pre_release_execution_profile_migrations(
|
|
798
980
|
connection: sqlite3.Connection, timestamp: str
|
|
799
981
|
) -> None:
|
|
982
|
+
scan_columns = {
|
|
983
|
+
row["name"] for row in connection.execute("PRAGMA table_info(scans)")
|
|
984
|
+
}
|
|
985
|
+
workspace_columns = {
|
|
986
|
+
row["name"] for row in connection.execute("PRAGMA table_info(workspaces)")
|
|
987
|
+
}
|
|
988
|
+
legacy_columns = {"execution_model", "reasoning_effort"}
|
|
989
|
+
renamed_columns = {
|
|
990
|
+
"legacy_execution_model",
|
|
991
|
+
"legacy_reasoning_effort",
|
|
992
|
+
}
|
|
800
993
|
execution_migrations = {
|
|
801
994
|
row["version"]: row["name"]
|
|
802
995
|
for row in connection.execute(
|
|
803
|
-
"SELECT version, name FROM schema_migrations WHERE version IN (11, 12, 25
|
|
996
|
+
"SELECT version, name FROM schema_migrations WHERE version IN (11, 12, 25)"
|
|
804
997
|
)
|
|
805
998
|
}
|
|
806
|
-
|
|
807
|
-
11: "scan execution profiles",
|
|
808
|
-
12:
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
999
|
+
supported_execution_migrations = {
|
|
1000
|
+
11: {"deep scan orchestration state", "scan execution profiles"},
|
|
1001
|
+
12: {
|
|
1002
|
+
"scan continuation threads",
|
|
1003
|
+
"scan execution profiles",
|
|
1004
|
+
"dynamic scan execution profiles",
|
|
1005
|
+
},
|
|
813
1006
|
}
|
|
814
1007
|
model_migration_name = "persist scan model settings"
|
|
815
1008
|
if execution_migrations.get(25) == "dynamic scan execution profiles":
|
|
@@ -818,50 +1011,36 @@ def normalize_pre_release_execution_profile_migrations(
|
|
|
818
1011
|
(model_migration_name, "dynamic scan execution profiles"),
|
|
819
1012
|
)
|
|
820
1013
|
execution_migrations[25] = model_migration_name
|
|
821
|
-
has_legacy_profile_history =
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
1014
|
+
has_legacy_profile_history = any(
|
|
1015
|
+
execution_migrations.get(version) in legacy_names
|
|
1016
|
+
for version, legacy_names in (
|
|
1017
|
+
(11, {"scan execution profiles"}),
|
|
1018
|
+
(12, {"scan execution profiles", "dynamic scan execution profiles"}),
|
|
1019
|
+
)
|
|
1020
|
+
)
|
|
1021
|
+
has_legacy_profile_columns = any(
|
|
1022
|
+
column in columns
|
|
1023
|
+
for column, columns in (
|
|
1024
|
+
("execution_model", scan_columns),
|
|
1025
|
+
("execution_model", workspace_columns),
|
|
1026
|
+
("reasoning_effort", workspace_columns),
|
|
1027
|
+
)
|
|
831
1028
|
)
|
|
832
1029
|
if not (has_legacy_profile_history or has_legacy_profile_columns):
|
|
833
1030
|
return
|
|
834
1031
|
|
|
835
|
-
if (
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
not in (None, released_names[version], legacy_names[version])
|
|
839
|
-
for version in (11, 12)
|
|
840
|
-
)
|
|
841
|
-
or (
|
|
842
|
-
has_legacy_profile_history
|
|
843
|
-
and execution_migrations.get(12)
|
|
844
|
-
not in (None, legacy_names[12], released_names[12])
|
|
845
|
-
)
|
|
846
|
-
or (
|
|
847
|
-
not has_legacy_profile_history
|
|
848
|
-
and execution_migrations.get(12) == legacy_names[12]
|
|
849
|
-
)
|
|
1032
|
+
if any(
|
|
1033
|
+
execution_migrations.get(version) not in ({None} | supported_names)
|
|
1034
|
+
for version, supported_names in supported_execution_migrations.items()
|
|
850
1035
|
):
|
|
851
1036
|
raise SystemExit(
|
|
852
1037
|
"The Codex Security database has an unsupported execution-profile migration history."
|
|
853
1038
|
)
|
|
854
1039
|
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
}
|
|
860
|
-
if has_legacy_profile_columns and (
|
|
861
|
-
not expected_legacy_columns.issubset(scan_columns)
|
|
862
|
-
or not expected_legacy_columns.issubset(workspace_columns)
|
|
863
|
-
or renamed_legacy_columns.intersection(scan_columns)
|
|
864
|
-
or renamed_legacy_columns.intersection(workspace_columns)
|
|
1040
|
+
if has_legacy_profile_columns and not (
|
|
1041
|
+
legacy_columns <= scan_columns
|
|
1042
|
+
and legacy_columns <= workspace_columns
|
|
1043
|
+
and not renamed_columns.intersection(scan_columns | workspace_columns)
|
|
865
1044
|
):
|
|
866
1045
|
raise SystemExit(
|
|
867
1046
|
"The Codex Security database has an unsupported execution-profile migration history."
|
|
@@ -878,7 +1057,7 @@ def normalize_pre_release_execution_profile_migrations(
|
|
|
878
1057
|
|
|
879
1058
|
# Keep the historical values and constraints for recovery while moving
|
|
880
1059
|
# them out of the namespace used by the current independent scan settings.
|
|
881
|
-
for table in ("workspaces", "scans")
|
|
1060
|
+
for table in ("workspaces", "scans"):
|
|
882
1061
|
connection.execute(
|
|
883
1062
|
f"ALTER TABLE {table} RENAME COLUMN execution_model TO legacy_execution_model"
|
|
884
1063
|
)
|
|
@@ -887,22 +1066,22 @@ def normalize_pre_release_execution_profile_migrations(
|
|
|
887
1066
|
)
|
|
888
1067
|
add_column_if_missing(connection, "scans", "model", "TEXT")
|
|
889
1068
|
add_column_if_missing(connection, "scans", "reasoning_effort", "TEXT")
|
|
890
|
-
|
|
1069
|
+
connection.execute(
|
|
1070
|
+
"""
|
|
1071
|
+
UPDATE scans
|
|
1072
|
+
SET model = COALESCE(model, legacy_execution_model),
|
|
1073
|
+
reasoning_effort = COALESCE(reasoning_effort, legacy_reasoning_effort)
|
|
1074
|
+
"""
|
|
1075
|
+
)
|
|
1076
|
+
for version, name in (
|
|
1077
|
+
(11, "scan execution profiles"),
|
|
1078
|
+
(12, "scan execution profiles"),
|
|
1079
|
+
(12, "dynamic scan execution profiles"),
|
|
1080
|
+
):
|
|
891
1081
|
connection.execute(
|
|
892
|
-
""
|
|
893
|
-
|
|
894
|
-
SET model = COALESCE(model, legacy_execution_model),
|
|
895
|
-
reasoning_effort = legacy_reasoning_effort
|
|
896
|
-
WHERE legacy_execution_model IS NOT NULL
|
|
897
|
-
OR legacy_reasoning_effort IS NOT NULL
|
|
898
|
-
"""
|
|
1082
|
+
"DELETE FROM schema_migrations WHERE version = ? AND name = ?",
|
|
1083
|
+
(version, name),
|
|
899
1084
|
)
|
|
900
|
-
if has_legacy_profile_history:
|
|
901
|
-
for version, name in legacy_names.items():
|
|
902
|
-
connection.execute(
|
|
903
|
-
"DELETE FROM schema_migrations WHERE version = ? AND name = ?",
|
|
904
|
-
(version, name),
|
|
905
|
-
)
|
|
906
1085
|
if execution_migrations.get(25) is None:
|
|
907
1086
|
connection.execute(
|
|
908
1087
|
"INSERT INTO schema_migrations (version, name, applied_at) VALUES (?, ?, ?)",
|
|
@@ -911,6 +1090,8 @@ def normalize_pre_release_execution_profile_migrations(
|
|
|
911
1090
|
|
|
912
1091
|
|
|
913
1092
|
def normalize_pre_release_migrations(connection: sqlite3.Connection, timestamp: str) -> None:
|
|
1093
|
+
normalize_mirror_lineage_migrations(connection)
|
|
1094
|
+
|
|
914
1095
|
completion_warning_migration = connection.execute(
|
|
915
1096
|
"SELECT name FROM schema_migrations WHERE version = 25"
|
|
916
1097
|
).fetchone()
|
|
@@ -1137,6 +1318,30 @@ def normalize_pre_release_migrations(connection: sqlite3.Connection, timestamp:
|
|
|
1137
1318
|
)
|
|
1138
1319
|
|
|
1139
1320
|
|
|
1321
|
+
def normalize_mirror_lineage_migrations(connection: sqlite3.Connection) -> None:
|
|
1322
|
+
mirror_names = {
|
|
1323
|
+
29: "freeze stopped scan source digests",
|
|
1324
|
+
30: "separate deep scan publication failures",
|
|
1325
|
+
}
|
|
1326
|
+
migrations = {
|
|
1327
|
+
row["version"]: row["name"]
|
|
1328
|
+
for row in connection.execute(
|
|
1329
|
+
"SELECT version, name FROM schema_migrations WHERE version BETWEEN 29 AND 32"
|
|
1330
|
+
)
|
|
1331
|
+
}
|
|
1332
|
+
if not any(migrations.get(version) == name for version, name in mirror_names.items()):
|
|
1333
|
+
return
|
|
1334
|
+
if migrations != mirror_names:
|
|
1335
|
+
raise SystemExit(
|
|
1336
|
+
"The Codex Security database has an unsupported mirror migration history."
|
|
1337
|
+
)
|
|
1338
|
+
for old_version, new_version in ((30, 32), (29, 31)):
|
|
1339
|
+
connection.execute(
|
|
1340
|
+
"UPDATE schema_migrations SET version = ? WHERE version = ? AND name = ?",
|
|
1341
|
+
(new_version, old_version, mirror_names[old_version]),
|
|
1342
|
+
)
|
|
1343
|
+
|
|
1344
|
+
|
|
1140
1345
|
def repair_deep_scan_migration(connection: sqlite3.Connection) -> None:
|
|
1141
1346
|
scan_columns = {row["name"] for row in connection.execute("PRAGMA table_info(scans)")}
|
|
1142
1347
|
owner_column_missing = "deep_scan_owner_thread_id" not in scan_columns
|
|
@@ -414,14 +414,31 @@ def git_directory_snapshot_paths(target: Path) -> list[Path] | None:
|
|
|
414
414
|
return sorted(set(paths))
|
|
415
415
|
|
|
416
416
|
|
|
417
|
-
def
|
|
417
|
+
def source_directory_snapshot_paths(target: Path) -> list[Path]:
|
|
418
|
+
paths: list[Path] = []
|
|
419
|
+
pending = [target]
|
|
420
|
+
while pending:
|
|
421
|
+
for path in pending.pop().iterdir():
|
|
422
|
+
if path.name == ".git":
|
|
423
|
+
continue
|
|
424
|
+
paths.append(path)
|
|
425
|
+
metadata = path.lstat()
|
|
426
|
+
# Name-surrogate reparse points include Windows directory junctions.
|
|
427
|
+
if stat.S_ISDIR(metadata.st_mode) and not getattr(metadata, "st_reparse_tag", 0) & 0x20000000:
|
|
428
|
+
pending.append(path)
|
|
429
|
+
return sorted(paths)
|
|
430
|
+
|
|
431
|
+
|
|
432
|
+
def directory_content_digest(
|
|
433
|
+
target: Path, *, excluded: tuple[Path, ...] = (), include_ignored: bool = False
|
|
434
|
+
) -> str:
|
|
418
435
|
excluded_relative = []
|
|
419
436
|
for path in excluded:
|
|
420
437
|
try:
|
|
421
438
|
excluded_relative.append(path.relative_to(target))
|
|
422
439
|
except ValueError:
|
|
423
440
|
continue
|
|
424
|
-
paths = git_directory_snapshot_paths(target)
|
|
441
|
+
paths = source_directory_snapshot_paths(target) if include_ignored else git_directory_snapshot_paths(target)
|
|
425
442
|
if paths is None:
|
|
426
443
|
paths = sorted(target.rglob("*"))
|
|
427
444
|
digest = hashlib.sha256()
|
|
@@ -440,7 +457,9 @@ def directory_content_digest(target: Path, *, excluded: tuple[Path, ...] = ()) -
|
|
|
440
457
|
raw_path = os.fsencode(relative_path.as_posix())
|
|
441
458
|
update_digest_field(digest, b"path", raw_path)
|
|
442
459
|
update_digest_field(digest, b"mode", str(stat.S_IMODE(metadata.st_mode)).encode())
|
|
443
|
-
if stat.S_ISLNK(metadata.st_mode)
|
|
460
|
+
if stat.S_ISLNK(metadata.st_mode) or (
|
|
461
|
+
include_ignored and getattr(metadata, "st_reparse_tag", 0) & 0x20000000
|
|
462
|
+
):
|
|
444
463
|
update_digest_field(digest, b"kind", b"symlink")
|
|
445
464
|
update_digest_field(digest, b"content", os.fsencode(os.readlink(path)))
|
|
446
465
|
elif stat.S_ISDIR(metadata.st_mode):
|
|
@@ -132,6 +132,8 @@ Treat failed requests, incomplete exact-identifier searches, unread plausible ma
|
|
|
132
132
|
|
|
133
133
|
### 4. Preview The Exact Writes
|
|
134
134
|
|
|
135
|
+
Follow the Writing Rules in `../../references/finding-detail-fields.md`. Explain the problem, how to reproduce it, the cause, the proposed fix, and validation. Put source locations and scan identifiers last.
|
|
136
|
+
|
|
135
137
|
Present a compact review before any mutation. For every finding show:
|
|
136
138
|
|
|
137
139
|
- finding id and fingerprint
|
package/dist/api.d.ts
CHANGED
|
@@ -16,6 +16,8 @@ export interface DeepScanOptions {
|
|
|
16
16
|
maxTimeHours?: number;
|
|
17
17
|
}
|
|
18
18
|
export interface ScanOptions extends DeepScanOptions {
|
|
19
|
+
/** Opt into a durable scan -> custom publication -> dedupe workflow. */
|
|
20
|
+
workflowId?: string;
|
|
19
21
|
auth?: ScanAuthMode;
|
|
20
22
|
/** Stable, privacy-preserving end-user ID for this scan's model requests. */
|
|
21
23
|
safetyIdentifier?: string;
|
package/dist/api.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":";AAkCA,OAAO,EAEL,gBAAgB,EAGhB,KAAK,aAAa,EACnB,MAAM,WAAW,CAAC;AAMnB,OAAO,EAOL,KAAK,mBAAmB,EACxB,KAAK,UAAU,EAEhB,MAAM,aAAa,CAAC;AACrB,OAAO,EAIL,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACtB,MAAM,WAAW,CAAC;AA+BnB,OAAO,EACL,UAAU,EAIX,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAA2B,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAMhF,OAAO,EAGL,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACtB,MAAM,sBAAsB,CAAC;AAG9B,OAAO,EAWL,iBAAiB,EAiBjB,KAAK,kBAAkB,EAIxB,MAA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