Files
nexus/wiki/concepts/self-hosted-password-manager.md

86 lines
2.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Self-Hosted Password Manager
## Aliases
- Self-Hosted Password Manager
- 自托管密码管理器
- 私有密码管理器
- 自建密码服务
## Type
Concept / Architecture Pattern
## Description
自托管密码管理器是指用户在自己的基础设施上部署和运行密码管理服务,而非使用第三方云服务,所有数据存储在用户可控的服务器或平台中。
## Deployment Architectures
### Traditional Self-Hosting
```
用户设备 → 自托管服务器 (VPS/Dedicated) → 数据库
```
- 需要维护服务器OS 更新、安全补丁)
- 需要管理数据库备份
- 示例Bitwarden 自托管、Vaultwarden
### Serverless Self-Hosting
```
用户设备 → 云函数/边缘计算 (Cloudflare Workers) → 云数据库 (D1/R2)
```
- 无需维护服务器
- 平台负责底层运维
- 示例NodeWarden
### Local-Only
```
用户设备 → 本地数据库
```
- 完全离线,不同步
- 示例KeePass
## Comparison Matrix
| 方案 | 服务器 | 数据控制 | 维护成本 | 跨设备同步 | 成本 |
|------|--------|----------|----------|------------|------|
| 官方云服务 | 厂商 | 厂商 | 无 | ✅ | 订阅制 |
| Bitwarden 自托管 | 用户 | 用户 | 高 | ✅ | 服务器成本 |
| NodeWarden | 无 | 用户 | 低 | ✅ | 接近免费 |
| KeePass | 无 | 用户 | 无 | 手动 | 免费 |
## Key Considerations
### Security
- 数据加密(服务端加密、传输加密)
- 访问控制强密码、2FA
- 审计日志
### Privacy
- 数据主权(谁控制服务器)
- 合规要求GDPR、HIPAA 等)
- 数据存储位置
### Reliability
- 备份策略
- 灾难恢复
- 可用性 SLA
### Cost
- 服务器/云资源成本
- 域名费用
- 维护人力成本
## Related Concepts
- [[TOTP]] — 双因素认证,通常与密码管理器配合使用
- [[Passkey]] — 新一代无密码认证标准
- [[Serverless Computing]] — NodeWarden 使用的架构范式
- [[Edge Computing]] — 边缘计算平台Cloudflare Workers
## Popular Self-Hosted Options
- [[Bitwarden]] — 官方自托管服务器Docker
- [[NodeWarden]] — Cloudflare Workers 版本([[Cloudflare Workers]]
- [[Vaultwarden]] — Bitwarden API 兼容实现,轻量级 Rust 版本
## Source
- [[nodewarden-把-bitwarden-搬上-cloudflare-workers-彻底告别服务器]]