Skip to content

SmartMOM v1.1.0

Latest

Choose a tag to compare

@HoneyMeta HoneyMeta released this 01 Dec 17:57
· 4 commits to main since this release

Security

  • The generic entity API (/api/e/<entity> list, record and CSV export) returned sys_user.password_hash to users with read access to users. Password, key, token, PIN and secret hashes are no longer returned. Please upgrade. If your instance was reachable by people you do not fully trust, consider asking users to change their passwords.
  • X-Forwarded-For / X-Real-IP are now trusted only when the request comes from 127.0.0.1 / ::1 or from an address in MOM_TRUSTED_PROXIES. Before, a forged header could get past an API key's IP allow-list. If your reverse proxy runs on another host, or reaches SmartMOM through a published Docker port, set MOM_TRUSTED_PROXIES.

New

  • Sign-in lock. 5 failed sign-ins lock a user name for 15 minutes; 30 failures from one address lock that address. Configure with MOM_LOGIN_MAX_FAILS, MOM_LOGIN_IP_MAX_FAILS, MOM_LOGIN_LOCK_MINUTES (0 = off).
  • AI cost control. AI features are either on demand (the model is called only when someone asks) or background / scheduled. Background features are off by default. A daily limit on model calls and tokens (default 300 / 400,000) stops AI with a clear message when it is reached. Today's usage is shown under System → AI features and returned by GET /api/ai/usage.
  • No PyMuPDF. Label PDFs are written by SmartMOM itself; pymupdf (AGPL) is no longer a dependency. CI checks that no Python dependency is GPL or AGPL.
  • Login page: plain description of the system; the user name is not pre-filled with admin on installs without demo accounts.

Upgrade notes

  • Migration v0510 (table ai_usage) runs at start.
  • AI watch and automation are switched off once if they were on. Turn them on again under System → AI features if you want them. The scheduled daily report and scheduled skills need the new switches daily_auto / skills_schedule for AI commentary.
  • The deprecated honeymom alias still works in 1.1.0 and will be removed in 1.2.0.
  • Docker image: ghcr.io/honeymeta/smartmom:1.1.0.

Full list in CHANGELOG.md.


安全

  • 通用实体接口(/api/e/<实体> 列表、详情、CSV 导出)会把 sys_user.password_hash 返回给能读用户表的用户。现在密码、密钥、令牌、PIN 等哈希字段一律不返回,请尽快升级。如果实例曾对不完全信任的人开放,建议让用户改一次密码。
  • X-Forwarded-For / X-Real-IP 只在请求来自 127.0.0.1 / ::1 或 MOM_TRUSTED_PROXIES 里的地址时才采用。以前伪造这个请求头可以绕过 API 密钥的 IP 白名单。反向代理不在同一台机器上、或经 Docker 映射端口访问时,请设置 MOM_TRUSTED_PROXIES。

新增

  • 登录失败锁定。 同一账号失败 5 次锁 15 分钟;同一地址失败 30 次锁该地址。用 MOM_LOGIN_MAX_FAILS、MOM_LOGIN_IP_MAX_FAILS、MOM_LOGIN_LOCK_MINUTES 调整,设为 0 关闭。
  • AI 用量控制。 AI 功能分为“按需”(有人用时才调用大模型)和“后台定时”两类,后台定时默认关闭。每天的调用次数和 token 有上限(默认 300 次 / 40 万),到了就停止并说明原因。当天用量在 系统 → AI 功能 查看,接口 GET /api/ai/usage。
  • 去掉 PyMuPDF。 标签 PDF 由 SmartMOM 自己生成,不再依赖 pymupdf(AGPL)。CI 检查 Python 依赖里没有 GPL / AGPL 许可证。
  • 登录页改成平实的系统说明;没有演示账号的正式安装不再预填 admin。

升级说明

  • 启动时自动执行迁移 v0510(新表 ai_usage)。
  • 原来开着的 AI 值守、自动化在升级后会被关闭一次,需要的话在 系统 → AI 功能 重新打开。定时日报和技能定时运行的 AI 解读需要打开新开关 daily_auto / skills_schedule。
  • 旧的 honeymom 别名在 1.1.0 仍可用,1.2.0 删除。
  • Docker 镜像:ghcr.io/honeymeta/smartmom:1.1.0。