This library allows you to compute MD5 message digests of arbitrary messages
in Elm. All input and output is given in lists of integers (List Int
), where
each Int
is assumed to be a byte. The hard work of this package was
done by Mark Orr and TruQu, for a more practical MD5, please see their
package.
fromBytes : List Basics.Int -> List Basics.Int
Given a list of integers of arbitrary length, returns a list of integers representing the hash as a series of individual bytes.
import String.UTF8
fromBytes (String.UTF8.toBytes "hello world")
--> [ 0x5e , 0xb6 , 0x3b , 0xbb
--> , 0xe0 , 0x1e , 0xee , 0xd0
--> , 0x93 , 0xcb , 0x22 , 0xbb
--> , 0x8f , 0x5a , 0xcd , 0xc3
--> ]