P1 security batch: quota execution checks, cost accounting, goal/coordinator semantics, PR channel, orphan signature, control-plane and console hardening

- Docker quota watchdog + fail-closed quota checks, system tasks need real owner
- max_cost_usd actually accumulated, cancel records cost, estimated rows excluded from unpriced cap, cache_write declared non-billed
- goal-resume keeps original verify on breakpoint resume, goal retry falls back to resume, goal_max_rounds capped at 100 at create and execution
- coordinator children inherit parent model/effort, orphans marked interrupted with audit
- PR jobs on docker workers return explicit needs_local_worker instead of silent empty
- worker code signature covers 6 files and is checked before claim, fail-closed
- sub2api lazy provisioning with rotation, backup whitelist + 0600, push SSRF block, repos/workers desensitized, key/project audits and limits, console buttons/quota/status wording, coordinator/automation quota reserve
This commit is contained in:
host committed 2026-10-27 16:27:50 +00:00
1 parent d254240d84
commit 1402dc67fd
20 files changed
+2616 -179

No files matched your search

+11 -1
View File
@@ -95,13 +95,23 @@ class ServerGithubReposTestCase(unittest.TestCase):
def test_list_returns_seeded_installations(self):
self._seed_installations()
# P1:repos 只返回调用者成员项目对应的仓库;先把项目仓库
# 绑到其中一个已安装仓库,再断言只返回该仓库,非成员为空。
s, d = _req(self.port, "PATCH",
"/projects/" + self.project_id,
{"repo_url": "https://github.com/openqj/codex-app-server.git"},
self.owner_key)
self.assertEqual(s, 200, d)
s, d = _req(self.port, "GET", "/github/repos", key=self.owner_key)
self.assertEqual(s, 200, d)
names = [r["repo_full_name"] for r in d["repos"]]
self.assertEqual(names, ["openqj/codex-app-server", "openqj/demo"])
self.assertEqual(names, ["openqj/codex-app-server"])
self.assertEqual(
d["repos"][0]["clone_url"],
"https://github.com/openqj/codex-app-server.git")
s, d = _req(self.port, "GET", "/github/repos", key=self.other_key)
self.assertEqual(s, 200, d)
self.assertEqual(d["repos"], [])
def test_patch_repo_url_owner(self):
url = "https://github.com/openqj/demo.git"