#include <dkim.h>
DKIM_STAT dkim_chunk(
DKIM *dkim,
unsigned char *chunkp,
size_t len
);
Handle a chunk of message input. The input is a buffer of message data
which may contain headers or body. An entire message may be fed to the API
in one buffer using this function. The API will determine automatically
the boundary between header fields and the body of the message and process
it accordingly.
Lines in the data chunk are expected to be CRLF-terminated in the
standard way. For input that is not, consider setting the
DKIM_LIBFLAGS_FIXCRLF (see
dkim_options()), which will
cause this function to attempt to auto-detect based on the first line
whether the input is CRLF-terminated or not, and adapt accordingly.
dkim_eoh() will be called implicitly
by this function upon encountering the end of the message's header block,
but the caller must still use
dkim_eom() to complete processing of
the message. Also, this function should be called with a NULL value for
chunkp and/or a zero value for len when no more chunks
are to be passed to the API, prior to calling dkim_eom().
|