Commit Graph

20 Commits

Author SHA1 Message Date
cnbugs 3ce7c99bfe fix: resolve merge conflict in services/acme.go (debug logging + TrimSpace) 2026-07-25 00:39:35 +08:00
Your Name 9bae6b1d9b youhua 2026-07-25 00:09:24 +08:00
cnbugs a2923bdfc0 fix: upgrade lego to v4.23.0, fix CredentialID update on re-issuance, add Cloudflare token debug logging 2026-07-24 22:36:33 +08:00
cnbugs 9a315e1404 chore: update go.sum for lego v4.22.0 upgrade 2026-07-24 19:45:54 +08:00
cnbugs 6498903a7c fix: credential data corruption - Create handler mutating store pointer
- CreateCredential was setting cred.Data = cred.Masked directly on the
  store pointer, corrupting stored credentials with masked data
- Fixed by using a value copy for API response
- Also fix nextID starts at 1 to avoid ID=0 issue
2026-07-24 19:16:35 +08:00
cnbugs 471fe76384 fix: credential ID starts from 1 to avoid ID=0 issue
- InitCredentialStore nextID defaults to 1
- Auto-migrate existing ID=0 credentials on load
- Add public Save() method for migration persistence
2026-07-24 19:13:26 +08:00
cnbugs 285df5a12f fix: cert create form credential selection validation
- Explicitly set selectedCredId in onCredSelected
- Separate credential validation from manual input validation
2026-07-24 19:10:34 +08:00
cnbugs 3a2c494d64 fix: increase DNS-01 timeout and add DNSTimeout option
- Add dns01.AddDNSTimeout(15s) for more reliable DNS propagation check
- Improve error resilience for Cloudflare DNS-01 challenges
2026-07-24 19:07:39 +08:00
cnbugs bdb3ca856f feat: add DNS credential management with Web UI
- New config/credential_store.go: persistent credential storage (credentials.json)
- New API: CRUD for DNS credentials + credential-types endpoint
- Certificate model now supports credential_id reference
- Create certificate auto-resolves credential_id to DNS config
- New Vue page: Credentials.vue for managing saved DNS keys
- CertCreate.vue: select existing credential or manual input + save as new
- Secrets masked in API responses, never exposed in list
2026-07-24 18:56:03 +08:00
cnbugs adebf82aaa chore: remove pre-compiled binary from repo 2026-07-23 16:37:39 +08:00
cnbugs 3cb2178c44 chore: add pre-compiled linux amd64 binary for no-go environments 2026-07-23 16:36:16 +08:00
cnbugs b1fd3a8b9b fix: include frontend dist assets in repo, fix deploy.sh syntax
- Remove .gitignore exclusion for dist/assets/ and frontend/dist/
- Fix deploy.sh: add missing quote on echo line
- Fix deploy.sh: correct ADMIN_PASSWORD=*** syntax
- Make deploy.sh auto-detect go/npm availability
2026-07-23 16:35:57 +08:00
cnbugs bbf09fbc8d feat: add Web UI for notification config (feishu + email)
- New config/notify_store.go: persistent notification config (notify.json)
- New API: GET/PUT /api/notify/config, POST /api/notify/test-feishu, POST /api/notify/test-email
- New Vue page: NotifyConfig.vue with feishu webhook and SMTP settings
- Updated cron/init to read from persistent store instead of env vars
- Password masked as ******** in API responses, preserved on updates
2026-07-23 16:31:04 +08:00
cnbugs 2d70a15307 feat: add login authentication and certificate expiry notifications
- JWT-based login with ADMIN_USER/ADMIN_PASSWORD env config
- Login page with auth guard for Vue frontend
- Feishu bot webhook notification for expiring certificates
- SMTP email notification for expiring certificates
- Daily 8:00 AM cron for expiry checks
- Startup health check notification
2026-07-23 16:25:02 +08:00
cnbugs c453d3425d 修复MIME类型错误:静态资源404直接返回 + 支持自定义base路径 2026-05-13 11:08:18 +08:00
cnbugs a9842e9212 v0.01: 修复死锁Bug + DNS-01默认 + 超时调整 2026-05-13 10:58:29 +08:00
cnbugs 3fa77d9bc0 refactor: replace SQLite/GORM with JSON file storage
- Remove GORM and SQLite, use simple JSON file (data/certs.json) for persistence
- CertStore with sync.RWMutex for thread-safe in-memory cache
- All handlers updated to use config.Store instead of config.DB
- Cron job and stats updated accordingly
- go mod tidy removes unused gorm/sqlite dependencies
2026-05-12 15:27:10 +08:00
cnbugs d0e738e1ef fix: use SQLite upsert to eliminate race condition on domain uniqueness constraint
Previously the CreateCertificate handler checked domain existence and then
inserted separately, creating a race window where concurrent requests could
both pass the check and trigger 'UNIQUE constraint failed' on INSERT.

Now uses SQLite's native INSERT ... ON CONFLICT (upsert) which atomically
handles the uniqueness constraint at the database level, eliminating the
race condition entirely.
2026-05-12 15:22:30 +08:00
cnbugs 0703dffb90 fix: 处理域名重复申请问题,支持重试失败/过期的证书 2026-05-12 15:01:07 +08:00
cnbugs 1775d4b4fc feat: AutoSSL certificate management tool with Web UI 2026-05-12 14:55:10 +08:00