SPDX: license tags (mostly by guesswork)
[exim.git] / src / src / spf.h
1 /*************************************************
2 *     Exim - an Internet mail transport agent    *
3 *************************************************/
4
5 /* Experimental SPF support.
6    Copyright (c) The Exim Maintainers 2016 - 2022
7    Copyright (c) Tom Kistner <tom@duncanthrax.net> 2004
8    License: GPL
9    SPDX-License-Identifier: GPL-2.0-only
10 */
11
12 #ifdef SUPPORT_SPF
13
14 /* Yes, we do have ns_type. spf.h redefines it if we don't set this. Doh */
15 #if !defined(HAVE_NS_TYPE) && defined(NS_INADDRSZ)
16 # define HAVE_NS_TYPE
17 #endif
18 #include <spf2/spf.h>
19
20 #include <spf2/spf_dns_resolv.h>
21 #include <spf2/spf_dns_cache.h>
22
23 typedef struct spf_result_id {
24   uschar *name;
25   int    value;
26 } spf_result_id;
27
28 /* prototypes */
29 gstring * spf_lib_version_report(gstring *);
30 BOOL spf_init(void);
31 BOOL spf_conn_init(uschar *, uschar *);
32 int  spf_process(const uschar **, uschar *, int);
33 void spf_response_debug(SPF_response_t *);
34
35 #define SPF_PROCESS_NORMAL  0
36 #define SPF_PROCESS_GUESS   1
37 #define SPF_PROCESS_FALLBACK    2
38
39 #endif