Skip to content

Python code for a cryptographic hash function. Incomplete and unsecure (March 2019).

Notifications You must be signed in to change notification settings

torresjrjr/CryptoHashAlgorithm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

::: NOM256 :::

A Cryptographic Hash Algorithm, in Python.
Outputs a 256-bit 64 character hash, 'hash-graph', and metadata, given a file.

Warning. Unstable and in progress

An example of a hash-graph, generated in 22.099 seconds from a 45 KB file:
An example of a hash-graph.

Usage

  1. 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 your meal.txt and NOM256.py:
  1. 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
  1. 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 to outhash-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.
A red hash-graph A green hash-graph A blue hash-graph

Dependancies

Python libraries:

  • matplotlib
python -m pip install -U pip
python -m pip install -U matplotlib

About

Python code for a cryptographic hash function. Incomplete and unsecure (March 2019).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages