Repository navigation
v1.2.0 – Web Vault, Send & Multi-User Administration
Release Notes
v1.2.0 - 2026-03-01
This is a major feature release. The headline addition is the built-in Web Vault — a full web-based password manager that works directly in any browser without installing a Bitwarden client. Alongside it comes complete Send support and a full multi-user administration system.
✨ New Features
Web Vault (webapp)
- New built-in web client served at the Worker's root URL (
/). - Vault page: browse, create, edit, delete, and restore ciphers (login, card, identity, secure note, SSH key).
- Full cipher detail view with field decryption, TOTP live code display, and one-click copy for passwords, usernames, TOTPs, and SSH keys.
- Folder management: create, rename, delete; filter vault items by folder.
- Attachment upload and download support.
- Vault lock / unlock flow: vault auto-locks after idle timeout; master password required to decrypt without re-authenticating.
- Settings page: change master password, enable/disable per-account TOTP 2FA, view recovery code, manage authorized devices.
- Sends page: create, view, edit, and delete text and file Sends.
- Public Send viewer (
/send/:accessId#keyPart): access password-protected or open Sends without an account. - JWT secret safety check: displays a warning page if the server is misconfigured.
- Admin panel: list users, invite new users, enable/disable accounts, delete accounts, manage and revoke invites.
- Toast notification system for all async operations.
- Confirmation dialog for destructive actions.
Internationalization (i18n)
- Full Chinese (zh-CN) and English (en) UI support.
- Language auto-detected from browser preferences.
Send (backend + frontend)
- Text and file Send creation, editing, deletion.
- Password-protected Sends with client-side PBKDF2 hash verification (plaintext password never sent to server).
- Access count limits and expiration dates enforced server-side with atomic SQL counter.
- Public Send access endpoints:
POST /api/sends/access/:accessId, v2 bearer variant, and file download flow.
Multi-User Administration
- Admin user management: list all users, change account status (enable/disable), delete accounts with full R2 file cleanup.
- Invite system: admin can generate single-use invite codes; registration requires a valid code after the first user.
- TOTP recovery code: per-user recovery code generation and verification for 2FA account recovery.
- Authorized device management: view and revoke trusted 2FA-remember devices.
🔒 Security Improvements
- Server-side password re-hashing: client PBKDF2 hash is re-hashed with PBKDF2-SHA256 (100k iterations) before storage, tagged with
$s$prefix; legacy raw hashes migrated transparently on next login. - Constant-time comparison for TOTP tokens and recovery codes (prevents timing attacks).
- Login rate limiting extended to IP + email dual dimension.
- API rate limiting unified and moved to Cloudflare Cache API (zero D1 writes under attack).
- KDF parameter validation on registration and password change (PBKDF2 ≥ 100,000 iterations, Argon2id ≥ 2/16/1).
handleSetKeysnow requires master password verification before replacing encryption keys.- CORS: removed trust for
origin: null(sandboxed iframe attack vector). - Content-Security-Policy header added (restricts script/connect/frame sources).
- Security response headers added globally (
X-Content-Type-Options,X-Frame-Options, etc.). - Send access count race condition fixed with atomic
UPDATE ... WHERE access_count < max_access_count. - Admin delete user now cleans up all R2 attachment and Send files before removing DB records.
- Import endpoint limited to 5,000 items per request.
- Request body size hard-capped at 25 MB for all non-upload endpoints.
- DB initialization errors no longer forwarded to clients (generic message only).
- TOTP secret removed from localStorage after successful enrollment.
🛠 Changes & Improvements
- New favicon and project logo assets.
- Build pipeline: Vite webapp builds into
dist/before Wrangler deploy;npm run deployis now the single deploy command. - Production builds disable source maps and use manual chunk splitting (
vendor,query,icons) to reduce per-deploy upload size. - Routing regex patterns hardened for more precise path matching.
- Removed bundled legacy Bitwarden web-client subprojects from the repository.
本版本是重大功能版本,核心新增内置 Web 密码库——无需安装任何 Bitwarden 客户端,直接在浏览器中管理密码。同时完整实现 Send 功能和 多用户管理 体系。
✨ 新功能
Web 密码库(webapp)
- 内置网页客户端,通过 Worker 根 URL(
/)直接访问。 - 密码库页:浏览、新建、编辑、删除、恢复密码项(登录、银行卡、身份信息、安全笔记、SSH 密钥)。
- 密码项详情视图:字段解密显示、TOTP 实时验证码、一键复制密码/用户名/TOTP/SSH 密钥。
- 文件夹管理:新建、重命名、删除文件夹;按文件夹过滤密码库。
- 附件上传与下载。
- 密码库锁定/解锁流程:闲置超时自动锁定,输入主密码即可解锁(无需重新登录)。
- 设置页:修改主密码、启用/禁用个人 TOTP 两步验证、查看恢复码、管理已授权设备。
- Send 页:创建、查看、编辑、删除文本和文件 Send。
- 公开 Send 查看页(
/send/:accessId#keyPart):无账号即可访问开放或密码保护的 Send。 - JWT 密钥安全检测:服务端配置不安全时显示警告页面。
- 管理员面板:用户列表、邀请新用户、启用/禁用账号、删除账号(含 R2 文件清理)、管理邀请码。
- 全局 Toast 通知。
- 危险操作确认对话框。
国际化(i18n)
- 完整支持中文(zh-CN)和英文(en)界面。
- 根据浏览器语言偏好自动选择。
Send(后端 + 前端)
- 文本和文件 Send 的创建、编辑、删除。
- 密码保护 Send:客户端 PBKDF2 哈希验证,明文密码不发往服务端。
- 访问次数限制和过期时间服务端原子 SQL 计数强制执行。
- 公开 Send 访问端点:
POST /api/sends/access/:accessId、v2 bearer 变体及文件下载流程。
多用户管理
- 管理员用户管理:查看所有用户、修改账号状态(启用/禁用)、删除账号(同步清理 R2 文件)。
- 邀请码系统:管理员生成一次性邀请码,首用户后的注册均需有效邀请码。
- TOTP 恢复码:每用户独立恢复码,用于两步验证账号恢复。
- 已授权设备管理:查看并撤销已信任的 2FA 记住设备。
🔒 安全改进
- 服务端密码二次哈希:客户端 PBKDF2 哈希在存储前再次用 PBKDF2-SHA256(10 万次迭代)哈希,加
$s$前缀标识;旧格式哈希在下次登录时透明迁移。 - TOTP 令牌与恢复码均改为恒定时间比较,防止时序攻击。
- 登录限流扩展为 IP + 邮箱双维度。
- API 限流统一移至 Cloudflare Cache API,攻击时零 D1 写入。
- 注册和改密码时校验 KDF 参数下限(PBKDF2 ≥ 100,000 次,Argon2id ≥ 2/16/1)。
handleSetKeys替换加密密钥前需验证主密码。- CORS 移除对
origin: null的信任。 - 新增 Content-Security-Policy 响应头。
- 新增全局安全响应头(
X-Content-Type-Options、X-Frame-Options等)。 - Send 访问计数竞态条件修复,改为原子 SQL。
- 管理员删除用户时先清理 R2 附件和 Send 文件。
- 导入接口限制单次最多 5,000 条。
- 非文件上传接口请求体大小上限 25 MB。
- DB 初始化错误不再直接透传给客户端。
- TOTP 密钥注册成功后立即从 localStorage 删除。
🛠 变更与改进
- 新增 favicon 和项目 Logo 资源。
- 构建流程:Vite 编译 webapp 到
dist/后 Wrangler 打包部署,npm run deploy一键完成。 - 生产构建关闭 source map,手动分包(
vendor、query、icons)减少每次部署上传量。 - 路由正则表达式收紧,提升路径匹配精度。
- 移除仓库内遗留的旧版 Bitwarden 网页客户端子项目。