Static Proactive Secret Sharing
Table of Contents
1. 背景介绍
使用 Shamir's Secret Sharing 方案可以把某个秘密值
攻击者需要攻破
注:如果我们有一个可信赖的第三方(“trusted dealer”),则这个事情将很简单:节点把各自的“部分秘密”发送给“trusted dealer”,“trusted dealer”恢复出原始秘密值
2. Herzberg's Method
1995 年,Herzberg 在论文 Proactive Secret Sharing Or: How to Cope With Perpetual Leakage 提出了 Share Renewal Protocol 和 Share Recovery Protocol,下面将介绍它。
假设,已经通过 Shamir's Secret Sharing 方案,设置门限为
f(1) = 2 # Alice's share f(2) = 1 # Bob's share f(3) = 2 # Carol's share f(4) = 5 # Dave's share
而秘密值
Figure 1: Shamir's Secret Sharing
2.1. Share Renewal Protocol
接着前面的例子,如何实现刷新 Alice/Bob/Carol/Dave 的“部分秘密”,但同时保持秘密值
第 1 步、随便某个人(比如 Alice),随机地生成一个 满足条件
g(1) = -1 # Alice 自己留着 g(2) = 0 # 发送给 Bob g(3) = 3 # 发送给 Carol g(4) = 8 # 发送给 Dave
Figure 2:
第 2 步、Alice/Bob/Carol/Dave 分别把各自保存的部分秘密
f'(1) = f(1) + g(1) = 1 # Alice's new share f'(2) = f(2) + g(2) = 1 # Bob's new share f'(3) = f(3) + g(3) = 5 # Carol's new share f'(4) = f(4) + g(4) = 13 # Dave's new share
由于生成
上面的步骤中,只有一个参与者(Alice)随机生成了一个 2 次多项式
当然,Alice 不应该被特殊化,也就是其他参与者都可以随机生成的一个 2 次多项式(但也要满足
Figure 3: Alice 生成
h(1) = -2 # 发送给 Alice h(2) = 0 # Bob 自己留着 h(3) = 6 # 发送给 Carol h(4) = 16 # 发送给 Dave
每个节点收到 Bob 发送来的数据后,更新自己的部分秘密:
f'(1) = f(1) + g(1) + h(1) = -1 # Alice's new share f'(2) = f(2) + g(2) + h(2) = 1 # Bob's new share f'(3) = f(3) + g(3) + h(3) = 11 # Carol's new share f'(4) = f(4) + g(4) + h(4) = 29 # Dave's new share
同样地,由于
类似地,Carol/Dave 也可以各自随机生成的一个 2 次多项式(但也要满足
2.1.1. 形式化描述
图 4 是 Herzberg 在论文中对 Share Renewal Protocol 的描述。
Figure 4: Herzberg's Share Renewal Protocol
2.1.2. 演示代码
在 https://asecuritysite.com/encryption/pro_sss2 中有个 Python 实现的 Proactive Secret Sharing 的演示代码。
2.2. Share Recovery Protocol
接着看节 2 中的例子:
f(1) = 2 # Alice's share, but missing f(2) = 1 # Bob's share f(3) = 2 # Carol's share f(4) = 5 # Dave's share
假设 Alice 保存的“部分秘密”丢失了(比如它的电脑磁盘坏了)。Bob/Carol/Dave 可以帮助 Alice 恢复出他丢失的“部分秘密”(即数字 2)吗?解决这个问题的协议被称为 Share Recovery Protocol。
有一种简单的办法,就是 Bob/Carol/Dave 直接把他们掌握的秘密发送给 Alice,Alice 可以通过拉格朗日插值还原出
其实,我们可以采用节 2.1 类似的思路来解决这个问题。
第 1 步,Bob 随机地生成一个
r(2) = 5 # Bob 自己留着 r(3) = 12 # 发送给 Carol r(4) = 21 # 发送给 Dave
第 2 步,Bob/Carol/Dave 分别把各自保存的部分秘密
f(2) + r(2) = 6 # Bob 把这个值发送给 Alice f(3) + r(3) = 14 # Carol把这个值发送给 Alice f(4) + r(4) = 26 # Dave 把这个值发送给 Alice
第 3 步,Alice 收到 Bob/Carol/Dave 发来的 3 个值,通过拉格朗日插值,可由 3 个点
注:和节 2.1 类似,除了 Bob 随机生成一个 2 次多项式外,Carol/Dave 也可以各自随机生成的一个 2 次多项式,满足
2.2.1. 形式化描述
图 5 是 Herzberg 在论文中对 Share Recovery Protocol 的描述。
Figure 5: Herzberg's Share Recovery Protocol