gpt4 book ai didi

security - 是否可以使用两种不同的算法创建具有相同校验和的伪造文件?

转载 作者:行者123 更新时间:2023-12-02 20:15:31 25 4
gpt4 key购买 nike

这篇博文 http://blogs.technet.com/dmelanchthon/archive/2009/07/23/windows-7-rtm.aspx 给我带来了一些启发(德语)

当前的观念是 md5 和 sha1 都有些损坏。并不容易和快速,但至少对于 md5 来说是可行的。 (我根本不是加密货币专家,所以也许我在类似的事情上是错的)。

所以我问自己是否可以创建一个具有相同大小相同 md5 和以及相同 sha1 的文件 A'和作为原始文件A。

首先,这可能吗?

第二,使用当前的硬件/软件,这在现实中是否可能?

如果不是,那么始终使用两种不同的算法(即使它们有某种弱点)不是保证文件完整性的最简单方法吗?

更新:

只是澄清一下:这个想法是有一个满足条件的文件 A 和文件 A':

size(A) == size(A') && md5sum(A) == md5sum(A') && sha1sum(A) == sha1sum(A')

最佳答案

“这可能吗?” - 是的,如果校验和的总大小小于文件的总大小,则无法避免冲突。

“在现实中,使用当前的硬件/软件有可能吗?” - 如果可以构造一个文本来匹配每个正在使用的校验和的给定校验和,那么可以。

参见wikipedia on concatenation of cryptographic hash functions ,这对于 Google 来说也是一个有用的术语。

从该页面:

"However, for Merkle-Damgård hash functions, the concatenated function is only as strong as the best component, not stronger. Joux noted that 2-collisions lead to n-collisions: if it is feasible to find two messages with the same MD5 hash, it is effectively no more difficult to find as many messages as the attacker desires with identical MD5 hashes. Among the n messages with the same MD5 hash, there is likely to be a collision in SHA-1. The additional work needed to find the SHA-1 collision (beyond the exponential birthday search) is polynomial. This argument is summarized by Finney."

关于security - 是否可以使用两种不同的算法创建具有相同校验和的伪造文件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1177337/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com