This pure-Lua module computes md5 in Lua 5.1, Lua 5.2 and LuaJIT, using native bit-manipulation libraries when available, and falling back to table-based manipulation of integers in 5.1.
It implements md5.sum and md5.sumhex like the kernel project md5 package, but it's done completely in Lua, with no dependencies on other libs or C files.
Usage
local md5 = require 'md5'
local md5_as_hex = md5.sumhexa(message) -- returns a hex string
local md5_as_data = md5.sum(message) -- returns raw bytes