Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions docs/audit/2026-09-08-audit-report.html
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,9 @@ <h2>Trạng thái xử lý - cập nhật đến Round 4 (2026-09-16)</h2>
<tr><td><span class="badge b-crit">ĐÃ FIX (Round 3)</span></td><td>HI-06, HI-11, HI-14 (phần hardening), HI-02/03, HI-21, HI-22, MD-10/11/12, MD-13/14/15, MD-01</td><td>Cron auth timing-safe fail-closed (7 routes); reminder re-check booking + cancel stale reminders; rate limit 6 auth mutations + HSTS/CSP headers; MCP tenant scoping + fromReschedule + conflict guard; SSRF self-hosted + opt-out; video token fail-closed; timing-safe webhook compares</td></tr>
<tr><td><span class="badge b-crit">ĐÃ FIX (Round 4 - verify lại 2026-09-16)</span></td><td>MD-03, MD-05/06, LO-02, LO-03, MD-29</td><td>MD-03: PBAC checkPermission giờ query membership thật, throw FORBIDDEN (aa68fd3acc). MD-05/06: partial expression index trên metadata dosOrgId/dosTeamId + WebhookScheduledTriggers drain take:100 + await + deleteMany sau dispatch (efb232e52f). LO-02: 3 barrels chết đã xoá (a058d89d53). LO-03: restore membership ADMIN/OWNER check (aa68fd3acc). MD-29: fork env vars vào turbo globalEnv (ccf9b85785)</td></tr>
<tr><td><span class="badge b-crit">ĐÃ FIX (Round 4 - 2026-09-16)</span></td><td>HI-09, CR-08 (hoàn tất), LO-13 (một phần)</td><td>HI-09: workflow mới <code>fork-ci.yml</code> (type-check + lint + unit test) chạy trên PR + push dev/main của DOS/Crove-Cal; <code>deploy-docker.yml</code> thêm job <code>ci-gate</code> (type-check) mà build-and-push phải chờ. CR-08: Dockerfile/docker-compose bỏ default secret từ Round trước; Round 4 thay 4 giá trị secret thật trong <code>apps/api/v2/.env.example</code> bằng placeholder. LO-13: JWT example trong README-PLATFORM.md thay bằng placeholder</td></tr>
<tr><td><span class="badge b-crit">ĐÃ FIX (Round 5 - 2026-09-16, PR #74)</span></td><td>HI-12 phần runner</td><td>Runner stage chạy <code>USER node</code> (app tree copy với <code>--chown=node:node</code>, không tạo layer copy-up) sau bước apt chạy root; <code>.dockerignore</code> chặn <code>.env*</code>/<code>*.pem</code>/<code>*.key</code>/<code>*.p12</code>/<code>*.pfx</code>/<code>.husky</code> - bảo vệ cả image web lẫn api/v2 (cùng context root). Verify: <code>docker build --check</code> sạch (4 warning là ARG build-time placeholder đã xử lý ở CR-08), image build + publish sau gate thành công trên dev (run 35127273831)</td></tr>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Using / as a separator between file patterns (e.g., <code>.env*</code>/<code>*.pem</code>/...) can be confusing in a Docker/security context, as / is the standard directory separator in path patterns. A reader might misinterpret this as a nested path pattern like .env*/*.pem (which matches files inside a directory). Using commas as separators would be much clearer and prevent any ambiguity.

Suggested change
<tr><td><span class="badge b-crit">ĐÃ FIX (Round 5 - 2026-09-16, PR #74)</span></td><td>HI-12 phần runner</td><td>Runner stage chạy <code>USER node</code> (app tree copy với <code>--chown=node:node</code>, không tạo layer copy-up) sau bước apt chạy root; <code>.dockerignore</code> chặn <code>.env*</code>/<code>*.pem</code>/<code>*.key</code>/<code>*.p12</code>/<code>*.pfx</code>/<code>.husky</code> - bảo vệ cả image web lẫn api/v2 (cùng context root). Verify: <code>docker build --check</code> sạch (4 warning là ARG build-time placeholder đã xử lý ở CR-08), image build + publish sau gate thành công trên dev (run 35127273831)</td></tr>
<tr><td><span class="badge b-crit">ĐÃ FIX (Round 5 - 2026-09-16, PR #74)</span></td><td>HI-12 phần runner</td><td>Runner stage chạy <code>USER node</code> (app tree copy với <code>--chown=node:node</code>, không tạo layer copy-up) sau bước apt chạy root; <code>.dockerignore</code> chặn <code>.env*</code>, <code>*.pem</code>, <code>*.key</code>, <code>*.p12</code>, <code>*.pfx</code>, <code>.husky</code> - bảo vệ cả image web lẫn api/v2 (cùng context root). Verify: <code>docker build --check</code> sạch (4 warning là ARG build-time placeholder đã xử lý ở CR-08), image build + publish sau gate thành công trên dev (run 35127273831)</td></tr>

<tr><td><span class="badge b-med">CHỜ QUYẾT ĐỊNH</span></td><td>HI-13, HI-14, HI-16, HI-10</td><td>HI-13: 61 migrations cần biết DB prod dùng schema nào (lưu ý: upstream đã đóng source 2026-04 nên áp lực sync giảm). HI-14: wire workflows dispatcher là quyết định feature - tham khảo Cal.com Workflows 2.0 (v6.9) trong report feature-gap cùng ngày. HI-16: branding hardcode - giờ upstream đóng source nên việc giữ branding riêng có chủ đích là phương án hợp lý, cần chốt. HI-10: bật crons cần cấu hình secrets riêng (CRON_SECRET v.v.) trước. Khi deploy: rotate secret Supabase + env mới (CRON_SECRET, OIDC_*, BREVO/CROVE/DOS_SYNC_WEBHOOK_SECRET, DATABASE_SSL_REJECT_UNAUTHORIZED=false nếu pooler cần) + prisma migrate deploy</td></tr>
<tr><td><span class="badge b-low">CÒN LẠI (TAIL)</span></td><td>Docker phần dở + perf/cosmetic</td><td>HI-12 phần dở (USER non-root, .dockerignore thiếu .env/*.pem/*.key), LO-13 phần dở (prisma/.env symlink, pin trigger.dev), MD-16…22 (frontend perf), MD-27/28 (CI supply-chain hygiene), MD-30 (Stripe png), MD-31/32 (latent), LO-01/04/05/06/07 (một phần)/08/09/11/14</td></tr>
<tr><td><span class="badge b-low">CÒN LẠI (TAIL)</span></td><td>Docker phần dở + perf/cosmetic</td><td>HI-12 phần còn lại (pin actions theo SHA - trùng MD-28; turbo prune để bỏ dev deps khỏi image), LO-13 phần dở (prisma/.env symlink, pin trigger.dev), MD-16…22 (frontend perf), MD-27/28 (CI supply-chain hygiene), MD-30 (Stripe png), MD-31/32 (latent), LO-01/04/05/06/07 (một phần)/08/09/11/14</td></tr>
</tbody>
</table>

Expand Down Expand Up @@ -444,7 +445,7 @@ <h2>Danh sách phát hiện</h2>
"CR-08":"Round 2 bỏ ARG defaults + comment studio; Round 4 (2026-09-16) thay 4 giá trị thật trong apps/api/v2/.env.example bằng placeholder.",
"HI-09":"Round 4 (2026-09-16): fork-ci.yml (type-check + lint + unit) chạy trên PR/push dev/main; deploy-docker.yml thêm ci-gate. Cron xem HI-10.",
"HI-10":"Cần cấu hình secrets riêng cho fork (CRON_SECRET…) rồi mới bật được - không bật khi thiếu secret.",
"HI-12":"Đã fix: studio disable, cache-to mode=min, bỏ ARG defaults. Còn mở: USER non-root + .dockerignore thiếu .env/*.pem/*.key.",
"HI-12":"Đã fix: studio disable, cache-to mode=min, bỏ ARG defaults, API v2 URL; Round 5 (PR #74): USER node + .dockerignore chặn secrets. Còn mở: pin actions theo SHA (MD-28) + turbo prune bỏ dev deps khỏi image.",
"HI-13":"Upstream đã đóng source (2026-04) nên áp lực sync giảm; vẫn cần chốt schema DB prod trước khi đụng 61 file.",
"HI-14":"scheduleRemindersForBooking vẫn 0 production caller. Tham khảo hướng đi: Cal.com Workflows 2.0 (v6.9) - xem report feature-gap ngày 2026-09-16.",
"HI-16":"Upstream đóng source (2026-04) nên lý do 'revert cho dễ sync' yếu đi - giờ là quyết định giữ branding riêng có chủ đích hay không.",
Expand Down
Loading