21 Commits

Author SHA1 Message Date
58f23ddcb8 Security hardening: fix RCE, auth and SSRF issues
Critical:
- backup: prevent Zip Slip path traversal and zip bombs in restore/convert
  via safe_extract(); serialize get_backup() with backup_lock and always
  restore CWD so concurrent requests can't corrupt the os.chdir state
- app: only enable the Werkzeug debugger/reloader when ENVIRONMENT=dev;
  always init rate limits (also under WSGI), not just under __main__
- apikey: fix create_key never committing (session.commit -> commit()),
  validate roles against an allowlist, and fix revoke_key/update_last_used
  operating on detached instances so revocation actually persists
- env_provider: redact DB_PASSWORD and SESSION_SECRET_KEY in summerize()

High:
- markdown: filter private/protected docs for non-admins in the listing,
  get_home, get_index and search endpoints (was an anonymous data leak);
  escape LIKE metacharacters and cap search results
- webhooks: validate target URL to block SSRF (loopback/private/link-local/
  metadata IPs), disable redirects, safely parse additional_header
- auth: validate JWT issuer and require exp/iat; add timeout to JWKS fetch;
  harden Authorization header parsing against malformed values
- log: require admin for GET /api/log and auth for POST; bound entry size

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-16 16:12:43 +01:00
692c0794c5 upgrade react-query to v5 2025-05-09 00:44:53 +01:00
85d8124a0c improve: upgrade node to 20, upgrade react-query to v4 2025-04-27 00:36:42 +01:00
0186a95dd4 fix: template defects 2025-04-17 21:44:45 +01:00
fa855bc7bb add: template editor 2025-04-14 17:02:22 +01:00
acb1e2260f add: load backup 2025-03-05 17:33:17 +00:00
e87ec256bb add: provide backup archive feature 2025-01-16 14:05:19 +00:00
41ff76e6c9 improve: add production stage 2024-12-09 07:01:22 +00:00
eaa2350b72 add: api for rate control 2024-12-06 16:12:44 +00:00
b3ec244e06 Save Markdowns 2024-12-06 15:13:20 +00:00
48dd59f8e4 kc token public key/token issue, path root set to 1 2024-12-06 10:04:03 +00:00
178219f097 read configs from env 2024-12-05 13:39:08 +00:00
9d0fd5b33c config for oauth 2024-12-04 14:06:30 +00:00
ba2f5bb483 fix OAuth2 issue 2024-12-04 08:03:14 +00:00
dc8ee49c9e fix render issue 2024-12-03 16:36:32 +00:00
969f200753 requirements 2024-12-03 12:42:09 +00:00
e929f67f4e api limiter & auto bp register 2024-12-03 11:28:40 +00:00
a93bd5d870 resource impl 2024-12-03 00:10:47 +00:00
5557b3434b log impl 2024-12-02 19:50:34 +00:00
83c5662fcb api impl 2024-12-02 18:33:39 +00:00
ae84e9e26f init commit 2024-12-02 15:22:11 +00:00