security: server-owned audit logs + fullscreen custom pages

Port upstream PR #22 + Lite style updates:
- lib/audit.js: server-side logAudit(req, action, userId), records
  IP from x-forwarded-for / cf-connecting-ip
- login/register/create_post/create_reply record server-side
- Remove client logEvent calls (AppProvider/NewPost/ReplyList)
- Remove forgeable POST /api/event-logs endpoint
- CustomPage: fullscreen immersive (fixed, 100vh-nav, mobile 56px
  nav offset) matching upstream Lite
This commit is contained in:
lezi-fun committed 2026-08-12 09:06:50 +08:00
1 parent 45ace3ba75
commit b9d6ca5da8
11 files changed
+73 -24

No files matched your search

+1 -1
View File
@@ -49,7 +49,7 @@ export default function CustomPage({ pageName }) {
</html>`;
return (
<div style={{ padding: '84px 32px 40px', background: 'var(--bg)', minHeight: '100vh' }}>
<div className="custom-page-container" style={{ padding: '84px 32px 40px', background: 'var(--bg)', minHeight: '100vh' }}>
<iframe
style={{ width: '100%', minHeight: '70vh', border: 'none', borderRadius: 8, background: 'var(--surface)' }}
sandbox="allow-scripts allow-modals allow-same-origin"