🔨 Some tools to (try to) break "Magic Hashes" https://git.forestier.app/HorlogeSkynet/MagicHashes
This repository has been archived on 2023-11-03. You can view files and clone it, but cannot push or open issues or pull requests.
Go to file
2023-11-03 22:02:56 +01:00
.gitignore There is a first time for everything ; Finally publish this project 2019-04-06 18:23:50 +02:00
LICENSE.md Fixes typo in LICENSE.md 2019-05-03 22:35:24 +02:00
magic_hashes_iterative.c Major optimization of the C "iterative" method, see details below : 2019-05-03 16:49:58 +02:00
magic_hashes_random.c There is a first time for everything ; Finally publish this project 2019-04-06 18:23:50 +02:00
magic_hashes_random.py There is a first time for everything ; Finally publish this project 2019-04-06 18:23:50 +02:00
README.md Removes "Improvements" README section 2023-11-03 22:02:56 +01:00

MagicHashes

Some tools to (try to) break "Magic Hashes".

Introduction

If you wonder what a "magic hash" is, please check this link.
At the time of writing, no such hashes have been found against the SHA-2 family.

This repository contains three different (pretty naive) brute-forcing implementations.

They have been developed to output exactly the same piece of information, when matching.

Usage

C

# Install dependency (Debian example) :
aptitude install libssl-dev

# Compilation time :
gcc -Wall -Wextra -O3 -std=c99 -o magic_hashes_random.out    magic_hashes_random.c    -lssl -lcrypto
gcc -Wall -Wextra -O3 -std=c99 -o magic_hashes_iterative.out magic_hashes_iterative.c -lssl -lcrypto

# Execution time :
./magic_hashes_random.out
./magic_hashes_iterative.out

Python

python3 magic_hashes_random.py

Performances

As far as I can tell, and on my setups only :

  • The random C implementation is ~75% faster than the Python one.
  • The iterative C implementation is ~10% faster than the C random one.