SYNOPSIS |
#include <dkim.h>
DKIM_STAT dkim_sig_getsignedhdrs(
DKIM *DKIM,
DKIM_SIGINFO *sig,
unsigned char *hdrs,
size_t hdrlen,
unsigned int *nhdrs
);
Retrieve from a DKIM and signature handle the set of header fields that were
included in the hashes of a valid signature.
|
DESCRIPTION |
Called When |
dkim_sig_getsignedhdrs() can be called at any time after
signature validation is completed via a call to
dkim_eom() using a DKIM handle
that was created by dkim_verify().
Only a signature that fully validated is acceptable. |
|
---|
ARGUMENTS |
Argument | Description |
dkim |
A message validation handle previously created using
dkim_verify().
|
sig |
Signature-specific handle.
|
hdrs |
An array of fixed-length character strings that should be
filled by header fields that were included in this signature's
header hash.
|
hdrlen |
The number of bytes available in each element of the hdrs
array.
|
nhdrs |
This should contain a pointer to the number of elements available
in the hdrs array. It will be updated to contain
the number of header fields that were included in the signature.
If insufficient array elements were available, the array will not
be updated (but this value will) and an error code is returned.
If temporary memory could not be acquired, this value will be set
to zero and an error will be returned.
|
|
RETURN VALUES |
Value | Description |
DKIM_STAT_INTERNAL |
An internal error occurred.
|
DKIM_STAT_NORESOURCE |
The hdrs array was too small to contain the result, or
not enough temporary memory could be allocated. If on return
from this function nhdrs contains 0, the latter occurred;
otherwise, nhdrs will be updated to contain the size of
the array needed to get all the data out.
|
|
NOTES |
|