问题描述: 之前的实现在勾选"包含服务器备份"时,会选择全部3个参与方 (2个用户设备 + 1个服务器),导致后端报错: "need exactly 2 parties for threshold 2, got 3" 根本原因: buildSigningParticipantList() 方法在 includeServerParties=true 时, 返回了所有参与方,没有排除丢失的设备。 修复内容: 1. buildSigningParticipantList() 新增 currentPartyId 参数 2. includeServerBackup=true 时的新逻辑: - 只选择当前设备 (currentPartyId) - 加上服务器方 (co-managed-party-*) - 排除另一个丢失的用户设备 - 总共正好 2 个参与方,满足 threshold t=2 3. 增强调试日志: - [PARTICIPANT-LIST] Device lost mode - Selected X parties for signing 测试场景: - 不勾选:2个用户设备参与(默认行为) - 勾选:1个当前设备 + 1个服务器 = 2方(设备丢失场景) 修改文件: - TssRepository.kt (lines 3719-3744, 3796-3804) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| .claude | ||
| api-gateway | ||
| infrastructure | ||
| mpc-system | ||
| scripts | ||
| services | ||
| .env.windows | ||
| docker-compose.windows.yml | ||