summaryrefslogtreecommitdiff
path: root/src/src/spf.c
diff options
context:
space:
mode:
authorPhilip Hazel <ph10@hermes.cam.ac.uk>2005-02-17 11:58:25 +0000
committerPhilip Hazel <ph10@hermes.cam.ac.uk>2005-02-17 11:58:25 +0000
commit8e669ac162fe3b1040297f1d021de10778dce9d9 (patch)
treecdfb2e5f859327fe7860f89a79e32df5ac1db4e1 /src/src/spf.c
parent6e2b4ccc44cc0e84337b9b74479c347985edab1c (diff)
downloadexim4-8e669ac162fe3b1040297f1d021de10778dce9d9.tar.gz
(1) Last-minute sieve patch (updates to latest spec).
(2) Last-minute typo fix in spec. (3) Trailing space removal ready for the release.
Diffstat (limited to 'src/src/spf.c')
-rw-r--r--src/src/spf.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/src/spf.c b/src/src/spf.c
index f3f8d7b56..1ef222aff 100644
--- a/src/src/spf.c
+++ b/src/src/spf.c
@@ -1,13 +1,13 @@
-/* $Cambridge: exim/src/src/spf.c,v 1.2 2004/12/16 15:11:47 tom Exp $ */
+/* $Cambridge: exim/src/src/spf.c,v 1.3 2005/02/17 11:58:26 ph10 Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
*************************************************/
-
+
/* Experimental SPF support.
Copyright (c) Tom Kistner <tom@duncanthrax.net> 2004
License: GPL */
-
+
/* Code for calling spf checks via libspf-alt. Called from acl.c. */
#include "exim.h"
@@ -23,15 +23,15 @@ SPF_dns_config_t spfdcid = NULL;
/* spf_init sets up a context that can be re-used for several
messages on the same SMTP connection (that come from the
same host with the same HELO string) */
-
+
int spf_init(uschar *spf_helo_domain, uschar *spf_remote_addr) {
uschar *p;
-
+
/* paranoia */
spfcid = NULL;
spfdcid_resolv = NULL;
spfdcid = NULL;
-
+
spfcid = SPF_create_config();
if ( spfcid == NULL ) {
debug_printf("spf: SPF_create_config() failed.\n");
@@ -62,7 +62,7 @@ int spf_init(uschar *spf_helo_domain, uschar *spf_remote_addr) {
spfdcid_resolv = NULL;
return 0;
}
-
+
return 1;
}
@@ -78,7 +78,7 @@ int spf_process(uschar **listptr, uschar *spf_envelope_sender) {
uschar spf_result_id_buffer[128];
SPF_output_t spf_output;
int rc = SPF_RESULT_ERROR;
-
+
if (!(spfcid && spfdcid)) {
/* no global context, assume temp error and skip to evaluation */
rc = SPF_RESULT_ERROR;
@@ -89,7 +89,7 @@ int spf_process(uschar **listptr, uschar *spf_envelope_sender) {
/* Invalid sender address. This should be a real rare occurence */
rc = SPF_RESULT_ERROR;
goto SPF_EVALUATE;
- }
+ }
/* get SPF result */
spf_output = SPF_result(spfcid, spfdcid);