Scroll to navigation

libmd(7) Miscellaneous Information Manual libmd(7)


libmdMessage Digest functions from BSD systems


The libmd library provides message digest functions found on BSD systems either on their libc or libmd libraries and lacking on others like GNU systems, thus making it easier to port projects with strong BSD origins, without needing to embed the same code over and over again on each project.

The library provides a compatibility interface for the Aladding Enterprises MD5 implementation, but the interface is not exposed by default to avoid polluting the namespace. The LIBMD_MD5_ALADDIN pre-processor variable needs to be defined to expose this interface.

The library provides a pkgconf(1) entry named libmd.


The libmd library provides compatibility with various BSD headers and interfaces.

The following headers are provided for compatibility with NetBSD and OpenBSD.


The following headers are provided for compatibility with FreeBSD and DragonFly.



md2(3), md4(3), md5(3), rmd160(3), sha1(3), sha2(3).


The libmd project started in the Debian GNU/kFreeBSD port as part of the libbsd library, as a way to ease porting code from FreeBSD to the GNU-based system. It was subsequently split into a project created on Hadrons.Org (mirrored on FreeDesktop.Org) for other distributions and projects to use, and further extended to match the other BSD interfaces.

It is now distributed as part of most non-BSD distributions

October 5, 2021 Linux 5.14.21-150500.55.52-default