Commit Graph

7 Commits

Author SHA1 Message Date
Le b37fa1804e security: go mat khau Gitea plaintext khoi ARCHITECTURE.md
Bang mat khau 4 tai khoan Gitea (hanlap, nguyendao, tulinh, namcunguyen) da
bi lo trong lich su git ke tu commit 85ca5c4. Go khoi ban hien tai va them
huong dan xu ly day du (rotate mat khau + tuy chon rewrite lich su git) --
viec rotate mat khau that tren Gitea van can admin thuc hien thu cong.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-03 21:33:18 +07:00
Le 6c1edcda34 fix: vá lỗ hổng RBAC + hardcode sàn ở /orders/place, nâng cấp mã hoá và CORS
- orders.place_order: yêu cầu role trader/admin (get_current_trader_user)
  thay vì bất kỳ user đã đăng nhập nào — viewer không còn đặt được lệnh thật
- orders.place_order: resolve exchange theo OrderRequest.exchange thay vì
  hardcode "mexc", fallback về credential active gần nhất nếu không truyền
- security.py: mã hoá API key chuyển AES-256-CBC -> AES-256-GCM (có xác thực
  toàn vẹn), giữ đường giải mã cũ để credential đã lưu trước đây không hỏng
- main_api.py: CORS_ORIGINS rỗng -> deny-all thay vì fallback "*" (kèm
  allow_credentials=True là cấu hình nguy hiểm)
- docker-compose.yml: đồng bộ DB_PASSWORD giữa backend-api/scheduler và db
- frontend: OrderPanel/DashboardPage truyền kèm exchange đang chọn khi đặt lệnh

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-03 21:27:47 +07:00
hanlap 88ce9cdd2d docs: thêm chi tiết backend-core, backend-API, frontend docs 2026-07-03 13:28:20 +00:00
hanlap 7af50cb397 docs: thêm modules-reference.md — tài liệu toàn bộ codebase 2026-07-03 13:25:48 +00:00
hanlap 85ca5c4581 docs: thêm Gitea + Infrastructure vào kiến trúc hệ thống 2026-07-03 13:23:46 +00:00
hanlap 841b8e2271 Update .gitignore: exclude all secrets, logs, models, reports 2026-07-03 13:08:48 +00:00
hanlap 34a1e91541 Initial commit: Trading Portal - FastAPI + React + PostgreSQL 2026-07-03 13:08:22 +00:00