سامانه صدور فاکتور و حسابداری

docs: record approved no-card local encrypted backup design and safety constraints

davoodmehraban89 committed Oct 14, 2026 at 22:21 UTC 9d0c28a727e15e330de05c0c49343c1fe65b19ef
1 file changed +7
PROJECT_STATE.md
+7
@@ -674,3 +674,10 @@ Owner reports login blocked with generic 'check internet/VPN' network error on l
674 - Live read-only TinyFish dashboard showed expired organization subscription for an account expected to have lifetime entitlement; license truth is not independently verified against live database. `js/organization-rbac.js` replaces profile subscription with organization license; `js/core.js` `canWrite()` prevents edits when expired. Do not bypass license or change financial data.
675 - Company editor action state updated in `js/companies.js`: require nonempty name, subsidiary parent, actual edit changes and `canWrite()` before enabling save. Save handler still enforces `requireWrite()`; button tooltip explains blocked license. Source originated PR #140; old branch was behind `main` by one merge and GitHub returned `405` requiring 3 missing status checks despite green Quality/Security workflows. Rebased changes on current `main` in a new PR branch, without bypassing branch protection.
676 - Verification: previous head `2a8dc526ec4b3eaae077d0614b060e421c081d91` Quality and Security both SUCCESS, but fresh branch CI and production real DOM not yet verified. Next: verify CI and merge gates; test real DOM without modifying production accounting records; investigate organization entitlement only with authorized live DB access.
677 +
678 +
679 +### 2026-10-14 owner-approved card-free offline encrypted database backup — WORK IN PROGRESS
680 +- **User request:** implement a zero-new-subscription, no-card, no-usage-billing backup solution for Finora ERP Production. Cloudflare R2 activation requires a card and was declined; do not attempt to reuse or store any card details.
681 +- **Verified deployment locator:** production Supabase project `hcsixhqbyuhpshfwqpjx` belongs to the newly named `Finora – Production / Finora ERP – Production` organization/project. The authenticated Supabase connection available to this assistant currently lists only other inactive projects; it does **not** provide production admin or DB-password access. Remote Desktop Commander `DESKTOP-71SJ63M` was offline during this slice.
682 +- **Design authority:** implement a client-side PostgreSQL `pg_dump` custom archive streamed directly into `age` encryption without any plaintext dump file, ciphertext hash manifest, read-only validation, and opt-in localhost disposable restore check. Owner retains private age key and two independent offline copies outside the Git repository. No production changes, credential logging, sensitive secrets in repo, automatic data deletion, or billable service activation.
683 +- **Acceptance remains open:** synthetic tests and code review are not a live production backup. Production operation must be run with securely entered database credentials and supported PostgreSQL client on an authorized machine, an off-device second copy must be verified, and an isolated restore test must pass before backup is declared operational.