Commit Graph
3 Commits
Author SHA1 Message Date
Draculabo 6328378da5 chore: make release manual and publish on release 2026-02-01 17:55:06 +08:00
vin 02080588b7 fix(security): add safeStorage fallback for production builds (#38) (#43)
Summary
  - Replace hard keytar dependency with a multi-strategy key storage:
    1) safeStorage (Electron built-in) — preferred
    2) keytar (system keychain) — fallback
    3) file-based encryption — last resort
  - Dynamically import keytar to avoid asar load failures
  - Refactor cloudHandler to use const (clean code)
  - Fix “Failed to load cloud accounts” in packaged app

  Rationale
  The keytar native module can fail to load from asar archives in production builds. This ensures the app works even when system keychain access is unavailable.

  Additional changes
  - Replace sync file ops with async (fs/promises)
  - Add atomic file writes to prevent data races
  - Implement concurrency lock for key generation
  - Add security error codes for better diagnostics
  - Add warnings for file-based fallback mode
  - Align error handling after merge
  - Migrate legacy encrypted account data

  References
  - Issue: #38
  - Commit: 92dc2f6
2026-01-27 03:05:41 +08:00
Draculabo d2945a6e8a ci: setup semantic release configuration and github actions workflow 2026-01-25 05:07:39 +08:00