[exim-cvs] cvs commit: exim/exim-src/src dkim.c dkim.h funct…

Etusivu
Poista viesti
Vastaa
Lähettäjä: Tom Kistner
Päiväys:  
Vastaanottaja: exim-cvs
Aihe: [exim-cvs] cvs commit: exim/exim-src/src dkim.c dkim.h functions.h transport.c exim/exim-src/src/pdkim sha1.c sha1.h
tom 2009/02/24 18:43:59 GMT

  Modified files:        (Branch: DEVEL_PDKIM)
    exim-src/src         dkim.c dkim.h functions.h transport.c 
    exim-src/src/pdkim   sha1.c sha1.h 
  Log:
  wip


  Revision  Changes    Path
  1.1.2.2   +13 -2     exim/exim-src/src/dkim.c
  1.1.2.2   +5 -0      exim/exim-src/src/dkim.h
  1.43.2.2  +1 -3      exim/exim-src/src/functions.h
  1.1.2.2   +2 -2      exim/exim-src/src/pdkim/sha1.c
  1.1.2.2   +1 -1      exim/exim-src/src/pdkim/sha1.h
  1.23.2.2  +1 -1      exim/exim-src/src/transport.c


  Index: dkim.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/Attic/dkim.c,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- dkim.c    24 Feb 2009 15:57:55 -0000    1.1.2.1
  +++ dkim.c    24 Feb 2009 18:43:59 -0000    1.1.2.2
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/dkim.c,v 1.1.2.1 2009/02/24 15:57:55 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/dkim.c,v 1.1.2.2 2009/02/24 18:43:59 tom Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -16,6 +16,17 @@


#include "pdkim/pdkim.h"

  +
  +void dkim_exim_verify_init(void) {
  +}
  +
  +void dkim_exim_verify_finish(void) {
  +}
  +
  +int dkim_exim_verify_result(uschar *domain, uschar **result, uschar **error) {
  +  return OK;
  +}
  +
   uschar *dkim_exim_sign(int dkim_fd,
                          uschar *dkim_private_key,
                          uschar *dkim_domain,
  @@ -29,6 +40,7 @@
     int sread;
     char buf[4096];
     int save_errno = 0;
  +  int old_pool = store_pool;


     dkim_domain = expand_string(dkim_domain);
     if (dkim_domain == NULL) {
  @@ -80,7 +92,6 @@
         goto CLEANUP;
       }
     }
  -  dkim_exim_sign_headers = dkim_sign_headers;


     /* Get private key to use. */
     dkim_private_key = expand_string(dkim_private_key);
  @@ -117,7 +128,7 @@


     pdkim_set_optional(ctx,
                        PDKIM_INPUT_SMTP,
  -                     (char *)dkim_exim_sign_headers,
  +                     (char *)dkim_sign_headers,
                        NULL,
                        pdkim_canon,
                        pdkim_canon,


  Index: dkim.h
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/Attic/dkim.h,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- dkim.h    24 Feb 2009 15:57:55 -0000    1.1.2.1
  +++ dkim.h    24 Feb 2009 18:43:59 -0000    1.1.2.2
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/dkim.h,v 1.1.2.1 2009/02/24 15:57:55 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/dkim.h,v 1.1.2.2 2009/02/24 18:43:59 tom Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -14,3 +14,8 @@
                          uschar *,
                          uschar *);


  +void dkim_exim_verify_init(void);
  +void dkim_exim_verify_finish(void);
  +int dkim_exim_verify_result(uschar *domain,
  +                            uschar **,
  +                            uschar **);


  Index: functions.h
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/functions.h,v
  retrieving revision 1.43.2.1
  retrieving revision 1.43.2.2
  diff -u -r1.43.2.1 -r1.43.2.2
  --- functions.h    24 Feb 2009 15:57:55 -0000    1.43.2.1
  +++ functions.h    24 Feb 2009 18:43:59 -0000    1.43.2.2
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/functions.h,v 1.43.2.1 2009/02/24 15:57:55 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/functions.h,v 1.43.2.2 2009/02/24 18:43:59 tom Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -86,9 +86,7 @@
   #ifndef DISABLE_DKIM
   extern BOOL    dkim_transport_write_message(address_item *, int, int,
                      int, uschar *, uschar *, uschar *, uschar *, rewrite_rule *,
  -                   int, uschar *, uschar *, uschar *, uschar *, uschar *, uschar *,
  -                   uschar *, uschar *, uschar *, uschar *, uschar *, uschar *
  -                   );
  +                   int, uschar *, uschar *, uschar *, uschar *, uschar *, uschar *);
   #endif
   extern dns_address *dns_address_from_rr(dns_answer *, dns_record *);
   extern void    dns_build_reverse(uschar *, uschar *);


  Index: transport.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/transport.c,v
  retrieving revision 1.23.2.1
  retrieving revision 1.23.2.2
  diff -u -r1.23.2.1 -r1.23.2.2
  --- transport.c    24 Feb 2009 15:57:55 -0000    1.23.2.1
  +++ transport.c    24 Feb 2009 18:43:59 -0000    1.23.2.2
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/transport.c,v 1.23.2.1 2009/02/24 15:57:55 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/transport.c,v 1.23.2.2 2009/02/24 18:43:59 tom Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -1059,7 +1059,6 @@
         }
       }
     }
  -  #endif


     /* Fetch file positition (the size) */
     size = lseek(dkim_fd,0,SEEK_CUR);
  @@ -1129,6 +1128,7 @@
     errno = save_errno;
     return rc;
   }
  +
   #endif




  Index: sha1.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/pdkim/Attic/sha1.c,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- sha1.c    24 Feb 2009 13:13:47 -0000    1.1.2.1
  +++ sha1.c    24 Feb 2009 18:43:59 -0000    1.1.2.2
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/pdkim/sha1.c,v 1.1.2.1 2009/02/24 13:13:47 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/pdkim/sha1.c,v 1.1.2.2 2009/02/24 18:43:59 tom Exp $ */
   /*
    *  FIPS-180-1 compliant SHA-1 implementation
    *
  @@ -309,7 +309,7 @@
   /*
    * output = SHA-1( input buffer )
    */
  -void sha1( unsigned char *input, int ilen, unsigned char output[20] )
  +void sha1_oneshot( unsigned char *input, int ilen, unsigned char output[20] )
   {
       sha1_context ctx;


@@ -362,7 +362,7 @@

       if( keylen > 64 )
       {
  -        sha1( key, keylen, sum );
  +        sha1_oneshot( key, keylen, sum );
           keylen = 20;
           key = sum;
       }


  Index: sha1.h
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/pdkim/Attic/sha1.h,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- sha1.h    24 Feb 2009 13:13:47 -0000    1.1.2.1
  +++ sha1.h    24 Feb 2009 18:43:59 -0000    1.1.2.2
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/pdkim/sha1.h,v 1.1.2.1 2009/02/24 13:13:47 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/pdkim/sha1.h,v 1.1.2.2 2009/02/24 18:43:59 tom Exp $ */
   /**
    * \file sha1.h
    *
  @@ -72,7 +72,7 @@
    * \param ilen     length of the input data
    * \param output   SHA-1 checksum result
    */
  -void sha1( unsigned char *input, int ilen, unsigned char output[20] );
  +void sha1_oneshot( unsigned char *input, int ilen, unsigned char output[20] );


   /**
    * \brief          Output = SHA-1( file contents )