Skip to content

OpenAI's Codex Security CLI and TypeScript SDK for finding, validating, and fixing security vulnerabilities. npm: https://www.npmjs.com/package/@openai/codex-security

Fix "Could not save the Codex Security scan" (#67)

Alessio Doriaa3e4c7a23a65
diff --git a/sdk/typescript/src/config.ts b/sdk/typescript/src/config.ts
index 3445de960..db6a4be88 100644
--- a/sdk/typescript/src/config.ts
+++ b/sdk/typescript/src/config.ts
@@ -33,6 +33,10 @@ export const DEFAULT_CODEX_CONFIG: Readonly<JsonObject> = {
max_concurrent_threads_per_session: 9,
},
},
+ // Named filesystem profiles need an active Windows sandbox backend.
+ windows: {
+ sandbox: "unelevated",
+ },
};
deepFreezeJson(DEFAULT_CODEX_CONFIG);
diff --git a/sdk/typescript/tests-ts/config.test.ts b/sdk/typescript/tests-ts/config.test.ts
index 94d80f2d7..3e1e5c1df 100644
--- a/sdk/typescript/tests-ts/config.test.ts
+++ b/sdk/typescript/tests-ts/config.test.ts
@@ -32,6 +32,7 @@ describe("Codex configuration", () => {
codexOverrides: {
features: { multi_agent_v2: { max_concurrent_threads_per_session: 4 } },
model_reasoning_effort: "high",
+ windows: { sandbox: "elevated" },
},
});
expect(merged["features"]).toEqual({
@@ -45,6 +46,7 @@ describe("Codex configuration", () => {
expect(merged["agents"]).toBeUndefined();
expect(merged["model"]).toBe("gpt-5.6-sol");
expect(merged["model_reasoning_effort"]).toBe("high");
+ expect(merged["windows"]).toEqual({ sandbox: "elevated" });
});
test("rejects prototype-bearing override keys", async () => {
@@ -92,6 +94,9 @@ describe("Codex configuration", () => {
expect(await mergedCodexConfig({})).toMatchObject({
model: "gpt-5.6-sol",
model_reasoning_effort: "xhigh",
+ windows: {
+ sandbox: "unelevated",
+ },
});
});