1 /* $Cambridge: exim/src/src/dk.h,v 1.2 2006/02/07 11:19:00 ph10 Exp $ */
3 /*************************************************
4 * Exim - an Internet mail transport agent *
5 *************************************************/
7 /* Copyright (c) University of Cambridge 1995 - 2006 */
8 /* See the file NOTICE for conditions of use and distribution. */
10 /* Code for DomainKeys support. Other DK relevant code is in
11 receive.c, transport.c and transports/smtp.c */
13 #ifdef EXPERIMENTAL_DOMAINKEYS
15 #include <domainkeys.h>
17 #define DK_EXIM_ADDRESS_NONE 0
18 #define DK_EXIM_ADDRESS_FROM_FROM 1
19 #define DK_EXIM_ADDRESS_FROM_SENDER 2
21 #define DK_EXIM_RESULT_ERR 0
22 #define DK_EXIM_RESULT_BAD_FORMAT 1
23 #define DK_EXIM_RESULT_NO_KEY 2
24 #define DK_EXIM_RESULT_NO_SIGNATURE 3
25 #define DK_EXIM_RESULT_REVOKED 4
26 #define DK_EXIM_RESULT_NON_PARTICIPANT 5
27 #define DK_EXIM_RESULT_GOOD 6
28 #define DK_EXIM_RESULT_BAD 7
30 typedef struct dk_exim_verify_block {
33 uschar *result_string;
40 } dk_exim_verify_block;
42 int dk_receive_getc(void);
43 int dk_receive_ungetc(int);
44 void dk_exim_verify_init(void);
45 void dk_exim_verify_finish(void);
46 int dk_exim_verify_result(uschar **);
47 uschar *dk_exim_sign(int, uschar *, uschar *, uschar *, uschar *);
49 extern dk_exim_verify_block *dk_verify_block;