docs(awooop): 記錄 tenants 脫敏正式驗證 [skip ci]
This commit is contained in:
@@ -1,3 +1,40 @@
|
||||
## 2026-06-14|AwoooP Tenants source namespace 脫敏正式驗證完成
|
||||
|
||||
**背景**:`/zh-TW/awooop/tenants` 的「原始碼 / 專案庫範圍」曾直接顯示 raw repository owner / namespace,屬於前台資訊揭露缺口。這次先做 P0 低摩擦修補:產品 API 與前台只顯示脫敏範圍代號,raw owner / namespace 仍只允許留在內部只讀 evidence 文件,不出現在產品頁或瀏覽器 API payload。
|
||||
|
||||
**修正內容**:
|
||||
- `GET /api/v1/platform/tenants` 的 `asset_inventory.source_repos` 對外欄位已改成 `SRC-###` 範圍代號,新增 `source_scope_id` 與 `source_namespace_redacted=true`。
|
||||
- tenants asset boundaries 新增 `repo_owner_namespace_redacted=true`、`raw_repository_namespace_visible=false`、`public_api_raw_repo_namespace_allowed=false`。
|
||||
- `/zh-TW/awooop/tenants` 前台欄位改為「脫敏原始碼範圍 / 範圍代號」,不再渲染 raw `github_repo`。
|
||||
- `apps/api/tests/test_awooop_tenant_asset_inventory.py` 改成要求 response payload 不得包含 raw owner / namespace。
|
||||
- `security-mirror-progress-guard.py` 已鎖住 tenants 頁、API schema、API builder 與繁中文案的 redaction 訊號。
|
||||
|
||||
**本地驗證**:
|
||||
- `PYTHONPATH=apps/api /Users/ogt/.pyenv/shims/python3 -m pytest apps/api/tests/test_awooop_tenant_asset_inventory.py -q`:`2 passed`(使用 dummy `DATABASE_URL`,未連線 live DB、未收集任何 secret)。
|
||||
- `PYTHONPATH=apps/api /Users/ogt/.pyenv/shims/python3 -m py_compile apps/api/src/services/platform_operator_service.py apps/api/src/api/v1/platform/tenants.py apps/api/tests/test_awooop_tenant_asset_inventory.py scripts/security/security-mirror-progress-guard.py` 通過。
|
||||
- `pnpm --dir apps/web typecheck` 通過。
|
||||
- `python3 scripts/security/security-mirror-progress-guard.py --root .` → `SECURITY_MIRROR_PROGRESS_GUARD_OK`。
|
||||
- `git diff --check` 通過。
|
||||
- 前台 / API 相關檔案敏感 namespace 掃描:`owenhytsai`、`nexu-io` 無命中。
|
||||
- 本地 builder payload:`source_repo_count=10`、第一筆 `SRC-001`、`contains_raw_namespace=False`、前三個 redaction boundaries 可見。
|
||||
|
||||
**正式部署與 production 驗證(2026-06-14 22:12 CST)**:
|
||||
- Code commit:`4bbc5269 fix(awooop): 脫敏 tenants 原始碼範圍`。
|
||||
- Deploy marker:`605fde43 chore(cd): deploy 4bbc526 [skip ci]`。
|
||||
- Gitea Actions:`code-review.yaml #2979` Success;`cd.yaml #2978` Success。
|
||||
- Production API:`https://awoooi.wooo.work/api/v1/platform/tenants` 回 `200`,`contains_raw_namespace=False`;第一筆 source repo 為 `SRC-001`,`source_namespace_redacted=true`;boundaries 前四筆為 `read_only_inventory_only=true`、`repo_owner_namespace_redacted=true`、`raw_repository_namespace_visible=false`、`public_api_raw_repo_namespace_allowed=false`。
|
||||
- Production HTML:`https://awoooi.wooo.work/zh-TW/awooop/tenants?_v=4bbc5269-redaction-prod-html` 回 `200`,HTML 不含 raw owner / namespace,且可讀到脫敏範圍標記。
|
||||
- In-app browser desktop / current viewport:`https://awoooi.wooo.work/zh-TW/awooop/tenants?_v=4bbc5269-redaction-prod-check`,`containsRaw=false`、`hasScopeCode=true`、`hasRedactedColumn=true`、`hasRedactionBoundary=true`、`innerWidth=1006`、`scrollWidth=1000`、`horizontalOverflow=false`。
|
||||
- In-app browser mobile viewport `390x844`:`https://awoooi.wooo.work/zh-TW/awooop/tenants?_v=4bbc5269-redaction-prod-mobile`,`containsRaw=false`、`hasScopeCode=true`、`hasRedactedColumn=true`、`hasRedactionBoundary=true`、`innerWidth=390`、`scrollWidth=384`、`horizontalOverflow=false`。
|
||||
|
||||
**完成度與邊界**:
|
||||
- AwoooP Tenants raw namespace information disclosure fix:`100%`。
|
||||
- AwoooP Tenants source scope redaction guard:`100%`。
|
||||
- Production API / HTML / desktop / mobile verification:`100%`。
|
||||
- IwoooS headline:維持 `64%`;active runtime gate:維持 `0`。
|
||||
- Owner response received / accepted、repo creation、refs sync、workflow modification、secret value collection、host write、production write、runtime execution、action buttons 全部仍維持 `0 / false`。
|
||||
- 這次修補只關閉前台與瀏覽器 API 的 raw namespace 外洩,不代表任何 GitHub primary、Gitea 停用、專案庫建立、Nginx / firewall / host 變更或資安 runtime 已授權。
|
||||
|
||||
## 2026-06-15|SSH / Firewall / Network Access owner response acceptance 只讀帳本本地完成
|
||||
|
||||
**背景**:110 端口關閉曾造成多個服務異常,代表 SSH、known_hosts、firewall、port close / open、NetworkPolicy、NodePort、WireGuard、sudo 與 deploy SSH 不能只停在 repo-only 清冊或 request draft。既有 SSH / network inventory 與 owner request draft 已完成,本段補 owner response acceptance 只讀帳本,避免把未驗收回覆誤判成 SSH、keyscan、known_hosts patch、firewall / port change、NetworkPolicy apply、NodePort change 或 WireGuard cutover 授權。
|
||||
|
||||
Reference in New Issue
Block a user