---
name: "libmd"
section: "7"
platform: "linux"
package: "libmd"
version: "1.3.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/libmd"
---

# libmd(7)

Message Digest functions from BSD systems

## NAME

**libmd** – Message Digest functions from BSD systems

## DESCRIPTION

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)](/pkgconf/1.md) entry named *libmd*.

## ALGORITHMS

The library supports the following message digest algorithms:

- MD2

  - MD4

  - MD5

  - RIPEMD-160

  - SHA-1

  - SHA-2 (SHA-224, SHA-256, SHA-384, SHA-512/224, SHA-512/256, SHA-512)

  - SHA-3 (SHA3-224, SHA3-256, SHA3-384, SHA3-512, SHAKE-128, SHAKE-256)

  ## HEADERS

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

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

- In md2.h

  - In md4.h

  - In md5.h

  - In rmd160.h

  - In sha1.h

  - In sha2.h

  The following headers are provided for compatibility with NetBSD.

- In sha3.h

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

- In ripemd.h

  - In sha.h

  - In sha256.h

  - In sha512.h

  ## SEE ALSO

[md2(3)](/md2/3.md), [md4(3)](/md4/3.md), [md5(3)](/md5/3.md), [rmd160(3)](/rmd160/3.md), [sha1(3)](/sha1/3.md), [sha2(3)](/sha2/3.md), [sha3(3)](/sha3/3.md).

## HISTORY

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
