globus_connect_gridftp_server  17.0~rc3
md5_internal

A standalone MD5 (RFC 1321) implementation, so the server can compute MD5 checksums without going through OpenSSL. OpenSSL refuses MD5 when the host is in FIPS mode. MD5 is used here just to verify that files match.

Internal Interface

gfs_md5.h defines the interface for using our internal MD5. Its a small abstraction which allows us to hide some symbols that conflict with OpenSSL symbols, and allows us to change the implementation if we want to at somepoint.

openbsd_compat.h is added as a minor compatibility layer to the upstream code.

Upstream Code

Uses OpenBSD's libc md5 implementation. This version was chosen because it is widely used (adapted to libmd), public domain, self-contained, and free of symbol collisions with libcrypto while following a the same call structure.

Applies the following minor patch to OpenBSD's libc:

<tt>$OpenBSD: md5.h,v 1.17 2012/12/05 23:19:57 deraadt Exp $</tt>

+++ md5.c -#include <md5.h> +#include "md5.h"

+++ md5.h +/* ignore BSD-style attributes */ +#pragma GCC diagnostic ignored "-Wattributes"

  • +#include "openbsd_compat.h"

+