A Cryptographic Hash Algorithm, in Python.
Outputs a 256-bit 64 character hash, 'hash-graph', and metadata, given a file.
- Version: 2.0
- Repository: https://github.com/torresjrjr/CryptoHashAlgorithm
- Author: @torresjrjr
Warning. Unstable and in progress
An example of a hash-graph, generated in 22.099 seconds from a 45 KB file:
- Set up or rename a copy of the file you want to hash as
meal.txt
.
- This can be any document file, or a simple text file with just a password.
- It is recommended you create a new directory (
/my-hashes
for example) with yourmeal.txt
andNOM256.py
:
- Run NOM256, in the same directory as your
meal.txt
file.
- You can run it in the command prompt:
$ python NOM256.py
- Once running, you'll be shown the estimated time left to complete. The hash rate is approximately 0.0425 seconds per 1,000 bytes (approximately 1,000 ASCII characters).
Time/seconds | Size/bytes or Total Characters |
---|---|
4.25e-5 | 1 |
0.0425 | 1,000 |
0.425 | 10,000 |
4.25 | 100,000 |
42.5 | 1,000,000 |
- The following files will be written in the same directory/folder:
outhash.txt
with the hash as a single 64 character hexadecimal alphanumeric string.
Example:B62F0E417874A438574C54B927B25DAFF30EB75872E3512D05F34503D8EF4742
outhash-history.txt
with the history of hashes within the directory as multiple lines of hash strings, including the last hash.outhash-test.txt
. Similar toouthash-history.txt
, with useful metadata.outhash.png
with the hash as a unique 'hash-graph' PNG image file. Its colour will change depending on the hash too.
my-hashes
|-- NOM256.py
|-- README.md
|-- meal.txt
|-- outhash-history.txt
|-- outhash-testing.txt
|-- outhash.png
`-- outhash.txt
Hash-graphs are generated with a pseudorandom variable colour, generated by their hash, to aid in quicker dicernment between hashes at a glance.
These hashes were generated from a 45 KB file with a single character changed.
Python libraries:
- matplotlib
python -m pip install -U pip
python -m pip install -U matplotlib