7

在加密中,如果两个对称算法的密钥大小相等,它们的安全性是否会被认为是相等的?(即 64 位 RC2 算法是否提供与 64 位 AES 算法相同的安全性?)

使用 64 位 RC2 算法有多安全(或不安全)?

我预计暴力攻击需要多长时间才能破解这种加密?

使用此算法可以保护哪些类型的数据?(例如,我猜信用卡信息不能用这个算法加密,因为算法不够安全)。

4

2 回答 2

12

一般来说,等效的密钥大小并不意味着等效的安全性,原因有很多:

首先,只是某些算法已知攻击而其他算法不知道的情况。密钥的大小只是破解密码所需努力的上限;在最坏的情况下,您始终可以尝试所有可能的密钥并在检查一半密钥空间后(平均)成功。这并不意味着这是最好的攻击方式。这是一个示例:具有 128 位密钥的 AES 使用 10 轮。如果您使用 AES 和 128 位密钥,但只使用一轮,即使密钥大小相同,它也很容易被破解。对于许多算法,已知的攻击可以在搜索整个关键空间时更快地破坏算法。

在分组密码的情况下,还有其他考虑因素。这是因为分组密码以比特块的形式处理数据。在您开始加密大量数据后,有各种组合属性开始发挥作用。例如,使用常见的 CBC 模式,在加密大约 2^(n/2) 个块后开始遇到问题(这个问题是 CBC 固有的)。对于像 RC2 这样的 64 位密码,这意味着 2^32 个 64 位块,或 32 GiB,虽然很大很容易想象(例如,你用它加密磁盘映像)。而对于像 AES 这样的 128 位密码,问题仅在大约 2^64 个 128 位块或大约 295 艾字节后才开始出现。在这种情况下,使用 64 位密钥的 AES 实际上比使用 64 位密钥的 RC2 安全得多。

在这里,我们得到答案的认识论部分:即使没有已知的攻击,也不意味着没有攻击可能。RC2比较老,很少用;即使它是一个相当流行的密码,对它的分析也比 DES 少得多。在过去的 5 年中,很可能没有人费心回过头来研究如何使用最新的攻击技术来破解 RC2,这仅仅是因为在现代公共密码学研究所依据的相对学术的发布或灭亡模型中,存在获得的收益更少;如果你正在寻求任期(或希望提高你的声誉以获得更多的咨询工作)发布攻击 AES 的微小改进,这比彻底拆除 RC2 要好得多,因为没有人再使用它了。

使用 64 位密钥,您会立即将自己限制在该上限,而 2^64 的工作量确实很低;可能不仅对情报机构,甚至对规模合理的公司(或僵尸网络牧民)都触手可及。

最后,我要指出的是,RC2 被设计为在 286/386 时代的处理器上运行得很快。在现代机器上,它比过去 10 年设计的 AES 或类似密码慢很多(大约 4-6 倍)。

我真的看不出将 RC2 用于任何事情的任何好处,我能想象的唯一有意义的用途是与某些古老的(计算机时间)系统兼容。使用 AES(或其他 4 个 AES 决赛入围者之一,如果必须)。

于 2010-09-08T18:00:57.790 回答
2

Here is my personal explanation about the expression "attack on n out of p rounds" that you can find on the page http://en.wikipedia.org/wiki/Block_cipher_security_summary . But beware: I am actually posting this as an answer so that people can tell me if I'm wrong. No-one ever explained this to me, and I am not a specialist, this is just the only explanation that makes sense that I could figure.

Cryptographers consider any algorithm that require less than brute force operations to be a successful attack. When a cipher is said to have an attack on "n out of p rounds", I guess that it means that if the cipher was defined as n rounds of the basic function it is actually defined as p rounds of, there would be an attack for it. Perhaps the algorithm actually keeps working for more than n rounds, but the cut-off point where it becomes more expensive than brute-force is n. In other words, this is a very fine distinction for an algorithm that is not broken, and it tells us how close we are to understanding abstractly the mathematical function it implements. This explains the seemingly arbitrary numbers than occur as values of "n" when this expression is employed.

To reiterate, a cipher that has an attack on n out of p rounds is a cipher that is not broken.

Also, an algorithm that is "broken" because it has an attack in 2100 operations for a 128-bit key can still be useful. The worry is in this case that further mathematical discoveries can continue to eat at the number of operations it takes to crack it. But 2100 is just as impractical as 2128.

于 2010-09-08T17:36:41.000 回答