• 请不要在回答技术问题时复制粘贴 AI 生成的内容
yfgeek
V2EX  ›  程序员

如何在短时间内快速找到字符串经过 sha1 算法的前 16 位的碰撞

  •  
  •   yfgeek · Oct 26, 2016 · 2882 views
    This topic created in 3512 days ago, the information mentioned may be changed or developed.

    问题描述

    如何在短时间内快速找到字符串经过 sha1 算法的前 16 位的碰撞

    最近的一个作业,写了一个 linux shell 。

    #!/bin/sh
    for((i=0;i<1000000000;i++));
    do
    echo -n $i | sha1sum - | cut -c1-15 >> d0
    done
    

    做运算,可是速度太慢,要跑 3 天 3 夜,于是寻找资料:

    工具

    • sha1_nearcoll_attack.zip 编译 boost 要很久很久 查找相近 sha1 碰撞工具

    https://marc-stevens.nl/p/hashclash/downloads.php

    • Malicious SHA-1 sha1 的文件碰撞生成工具

    https://malicioussha1.github.io/

    • hashclash 的 linux 64 编译后工具

    https://github.com/ohadcn/hashclash/tree/master/hashclash

    文章

    • 58 步逼近 sha1 算法

    https://cryptome.org/sha1-attacks.htm

    http://blog.rexdf.org/2014/07/hash%E6%91%98%E8%A6%81%E7%AE%97%E6%B3%95%E7%9A%84%E6%94%BB%E5%87%BB/

    大家有什么好想法吗

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5484 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 33ms · UTC 07:59 · PVG 15:59 · LAX 00:59 · JFK 03:59
    ♥ Do have faith in what you're doing.