【密码学】基于 fastcoll 实现 MD5 碰撞快速生成(MD5碰撞)

【密码学】基于 fastcoll 实现 MD5 碰撞快速生成(MD5碰撞)

原理

MD5碰撞

MD5碰撞是指两个不同的输入数据通过MD5哈希算法生成相同的哈希值。这种情况会导致哈希值无法唯一标识原始数据,从而破坏哈希函数的完整性和安全性。

步骤

  1. 准备一个可执行文件 helloworld.exe,测试运行

    bash 复制代码
    .\helloworld.exe
  2. 运行 fastcoll,以 helloworld.exe 为基础,生成 helloworld1.exe 和 helloworld2.exe 两个文件

    bash 复制代码
    fastcoll -p .\helloworld.exe -o helloworld1.exe helloworld2.exe

验证

  1. 运行 helloworld1.exe 和 helloworld2.exe

    bash 复制代码
    .\helloworld1.exe
    bash 复制代码
    .\helloworld2.exe

    都能正常运行

  2. 使用 Ultra Compare 比较 helloworld1.exe 和 helloworld2.exe

    发现存在差异

  3. 使用 Ultra Compare 比较 helloworld.exe 和 helloworld1.exe

    发现 helloworld1.exe 是在 helloworld.exe 的文件末尾拼接了一段数据

  4. 使用 certutil 计算 helloworld1.exe 和 helloworld2.exe 的 MD5 单向散列值

    bash 复制代码
    certutil -hashfile .\helloworld1.exe md5
    bash 复制代码
    certutil -hashfile .\helloworld2.exe md5

    发现一致

  5. 使用 certutil 计算 helloworld.exe 和 helloworld1.exe 的 MD5 单向散列值

    bash 复制代码
    certutil -hashfile .\helloworld.exe md5
    bash 复制代码
    certutil -hashfile .\helloworld1.exe md5

    不一致

声明

本博客上发布的所有关于网络攻防技术的文章,仅用于教育和研究目的 。所有涉及到的实验操作都在虚拟机或者专门设计的靶机上进行,并且严格遵守了相关法律法规

博主坚决反对任何形式的非法黑客行为 ,包括但不限于未经授权的访问、攻击或破坏他人的计算机系统。博主强烈建议每位读者在学习网络攻防技术时,必须遵守法律法规不得用于任何非法目的 。对于因使用这些技术而导致的任何后果,博主不承担任何责任

相关推荐
Sagittarius_A*9 小时前
流密码基础(四):相关攻击与 Geffe 生成器
信息安全·密码学·数论
汽车网络安全爱好者2 天前
Public Key Infrastructure(二)— 深入理解 X.509 证书:从 RFC 5280 到 OpenSSL 实践
运维·服务器·算法·网络安全·汽车·密码学·可信计算技术
Sagittarius_A*5 天前
[LitCTF2026] lit_xor_two_story
python·算法·密码学
hxhy006 天前
密码学速查指南
密码学
Draina7 天前
CBC填充预言攻击-CBC Padding Oracle Crypto Attack
python·安全·web安全·网络安全·密码学·安全性测试
二宝哥9 天前
MySQL 修改密码策略详解:从基础到高级配置
mysql·密码学
Sagittarius_A*15 天前
现代密码学的数学地基:从模运算到离散对数
网络·算法·密码学
AI科技星18 天前
基于全域数学公理体系求解三元约束极值题【乖乖数学】
人工智能·算法·机器学习·密码学·拓扑学·乖乖数学·全域数学
云水一下21 天前
DVWA从入门到精通(十八):Cryptography(密码学问题)
web安全·密码学·dvwa
MartinYeung521 天前
W3C Agent Identity 最新标准:从密码学视角的深度解析
密码学