# dkim_getuser()

[back to index]

SYNOPSIS

    #include <dkim.h>

    const char * dkim_getuser(
    	DKIM *dkim
    );

Retrieve the sending user associated with a message.

DESCRIPTION

Called When | `dkim_getuser()` can be called at any time after a handle is initialized with a call to `dkim_sign()` or `dkim_verify()`.

ARGUMENTS

Argument | Description
--- | ---
dkim | Message-specific handle, returned by `dkim_sign()` or `dkim_verify()`.

RETURN VALUES

Value | Description
--- | ---
`NULL` | The sending user has not or could not be determined from the message represented by this handle.
otherwise | A pointer to the sending user.

NOTES

- This user is selected by finding the first header field matching the sender header field name list as set by the `DKIM_OPTS_SENDERHDRS` option or its default (see `dkim_options`). Note that it is not guaranteed that this field was included in the set of fields fed to the DKIM signature hashes (assuming it was signed), and in any case its value may or may not have been valid at the time the message was generated.

Copyright (c) 2007 Sendmail, Inc. and its suppliers. All rights reserved.
Copyright (c) 2010, 2011, The OpenDKIM Project. All rights reserved.
By using this file, you agree to the terms and conditions set forth in the respective licenses.