opendmarc_get_policy_to_enforce()

[back to index]

SYNOPSIS
#include <dmarc.h>
OPENDMARC_STATUS_T opendmarc_get_policy_to_enforce(
	DMARC_POLICY_T *pctx
);
Query the library to find the policy to follow.
DESCRIPTION
Called When opendmarc_get_policy_to_enforce() is called after the DMARC record has been fetched and parsed.
ARGUMENTS
ArgumentDescription
pctx The address of a structure of type DMARC_POLICY_T as returned from opendmarc_policy_connect_init().
RETURN VALUES
  • DMARC_PARSE_ERROR_NULL_CTX -- If you passed in a pctx value that was NULL.
  • DMARC_POLICY_ABSENT -- No DMARC record was found.
  • DMARC_FROM_DOMAIN_ABSENT -- No From: domain was ever supplied to look up.
  • DMARC_POLICY_NONE -- Accept (only if other policy allows)
  • DMARC_POLICY_REJECT -- Policy advises to reject the message.
  • DMARC_POLICY_QUARANTINE -- Policy advises to quarantine the message.
  • DMARC_POLICY_PASS -- Policy advises to accept the message
NOTES
  • Call this function only after a DMARC record was fetched and parsed with opendmarc_policy_query_dmarc() or supplied to the library with opendmarc_policy_store_dmarc().
  • The "pct" value of the DMARC policy record is not applied by this function. That is, the applicable policy is always returned, and the caller must apply the semantics requested by a "pct" value other than 100.

Copyright (c) 2012, The Trusted Domain Project. All rights reserved.
By using this file, you agree to the terms and conditions set forth in the license.