关于「失联与共谋:异质持有人、同址共灾与熟人网络」,《数字资产灾难恢复与门限分片》给出的定量结论是什么?
结论:第三章处理异质持有人、同址共灾与熟人串通:五取三按三加二分在两处,丢失概率 0.012547,比放在一处还差。
数据口径:书中所有秘密都是玩具整数,参数均为示意,全部计算由书中程序生成;本书是数学模型与演练清单,不连接也不描述任何真实服务器,生产环境的备份与密钥操作须人工放行,不构成个人化法律或理财建议。 第一章在每份每年丢失 0.05、泄露 0.02 的示意参数下,算出三份副本的年丢失概率 0.000125、泄露概率 0.058808,三取二分别为 0.007250 与 0.001184,五取二是两项都胜过三份副本的最小方案。
对照数据表
下表数字由本章 Python 程序原样打印,可重新运行复现。 程序只用 Python 标准库与结论吻合的打印值: 0.012547
| site disaster 0.010, break-in 0.005, piece q 0.05, p 0.02 | ||
| layout | P(lost) | P(leaked) |
| 3 copies, one house | 0.010124 | 0.063514 |
| 3 copies, 3 sites | 0.000211 | 0.072855 |
| 3-of-5, one house | 0.011147 | 0.005077 |
| 3-of-5, sites 3+2 | 0.012547 | 0.005369 |
| 3-of-5, sites 2+2+1 | 0.004355 | 0.000745 |
| 3-of-5, 5 sites | 0.001923 | 0.000149 |
| 2-of-5, sites 2+2+1 | 0.000295 | 0.014144 |
| 2-of-5, 5 sites | 0.000060 | 0.005897 |
查看完整验算程序
# Chapter 3. p32: shares that share a building fail together.
# Model: pieces sit at sites. A site disaster (fire, flood, seizure of a
# building) destroys every piece there with probability D per year; a
# site break-in exposes every piece there with probability B. On top,
# each piece is lost with q and leaked with p on its own. Exact by
# enumerating site outcomes, then a binomial over the surviving pieces.
# D = 0.01, B = 0.005, q = 0.05, p = 0.02 are illustrative.
import itertools
import math
D, B, Q, P = 0.01, 0.005, 0.05, 0.02
def tail(n, r, x):
if x <= 0:
return 1.0
terms = [math.comb(n, j) * r ** j * (1 - r) ** (n - j)
for j in range(x, n + 1)]
return math.fsum(terms)
def risk(layout, k):
n = int(math.fsum(layout))
lo, le = [], []
for hit in itertools.product((0, 1), repeat=len(layout)):
w_d = math.prod(D if h else 1 - D for h in hit)
w_b = math.prod(B if h else 1 - B for h in hit)
hit_n = int(math.fsum(c for c, h in zip(layout, hit) if h))
alive = n - hit_n
# as disasters: fewer than k surviving pieces stay usable
lo.append(w_d * tail(alive, Q, alive - k + 1))
# as break-ins: exposed pieces plus independent leaks reach k
le.append(w_b * tail(alive, P, max(0, k - hit_n)))
return math.fsum(lo), math.fsum(le)
CASES = [("3 copies, one house", [3], 1),
("3 copies, 3 sites", [1, 1, 1], 1),
("3-of-5, one house", [5], 3),
("3-of-5, sites 3+2", [3, 2], 3),
("3-of-5, sites 2+2+1", [2, 2, 1], 3),
("3-of-5, 5 sites", [1, 1, 1, 1, 1], 3),
("2-of-5, sites 2+2+1", [2, 2, 1], 2),
("2-of-5, 5 sites", [1, 1, 1, 1, 1], 2)]
print("site disaster %.3f, break-in %.3f, piece q %.2f, p %.2f"
% (D, B, Q, P))
print("layout P(lost) P(leaked)")
for name, lay, k in CASES:
lo, le = risk(lay, k)
print("%-20s %9.6f %11.6f" % (name, lo, le))唯一数据源与引用
范雅福(Fan, Y.). (2026). 《数字资产灾难恢复与密钥分片、沙米尔秘密共享门限与异地增量快照单点失联自救母典》第 3 章「失联与共谋:异质持有人、同址共灾与熟人网络」(版本 1.0.0). 5D Library. DOI 待发布
DOI 待发布 · 专著页正式发布后上线(本站暂无专著页) · 5DL-B-272 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026272,
author = {Fan, Yafu},
title = {Disaster Recovery for Digital Assets: Shamir Secret-Sharing Thresholds, Off-Site Incremental Snapshots and Self-Rescue from Single Points of Loss},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
note = {DOI pending}
}