MD5 library for x64 written in assembler
Requirements to compile:
make
gcc
nasm
All of the above should be available to install in your distribution of choice's package manager. If you use Windows, you might be able to use MinGW with varying degrees of success.
This library is a proof-of-concept at this point. All that is supported right now is the hashing of strings < 56 characters in length. The test program generated by the make process takes a string as an argument and prints out the hash.
This library has been designed with thread safety in mind, with the end goal of implemented in a multi-threaded program to generate hashes as fast as possible. To link this library into your own programs, the following simple commands can be used:
nasm -felf64 -o fastmd5.o
gcc your_program.c fastmd5.o -o your_program
Read fastmd5.h for function definitions. The caller must prepare and zero-pad their own input buffer.
#Todo:
- Improve wrapper code to make the library as simple to call as possible
- Allow arbitrary length messages to be hashed
- Improve assembler padding code.