From https://www.fehcom.de/qmail/smtpauth.html#PATCHES
Generic SMTP authentication for qmail-smtpd and qmail-remote.
Complies to RFC 3848 and RFC 4409.
* Provides now CRAM-MD5 authentication for qmail-remote as well.
* Fine tuning of SMTPAUTH annoncements for qmail-smtpd and
SUBMISSION support.
* Sender based authentication according to 'Mail From:' and
authenticated smarthost relaying for qmail-remote.
* Fixed bug (0.8.2): qmail-smtpd secretly allows auth even when
disabled! (tx Chris P.)
* Fixed AMD64 bug for MD5 (0.8.3) and small others (tx Alan P.)
of qmail-lspawn, qmail-newmrh, qmail-newu, qmail-pop3d, qmail-popup,
qmail-rspawn, and qmail-smtpd. This fixes two known bugs:
- qmail-smtpd can be crashed by a client sending a sufficiently
long (e.g. 2GB) header line in an email.
- qmail_lspawn, qmail-newmrh, qmail-newu, and qmail-rspawn might
crash or otherwise misbehave on hosts with a smaller "int" type
than "char *" type, e.g. 64-bit hosts with 32-bit "int"s.
The other changes are unlikely to have any effect, except possibly on
unusual architectures and/or in the presence of rare optimizations.
This is Version 1 of this patch. It adds the changes to
cdbmake_add.c, spawn.c, and, correspondingly, Makefile, which pertain
to the second bug listed above.