[exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim…

Top Page
Delete this message
Reply to this message
Author: Nigel Metheringham
Date:  
To: exim-cvs
Subject: [exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim/exim-src/src exim.c functions.h tls-gnu.c tls-openssl.c
nm4 2009/10/14 14:52:49 BST

  Modified files:
    exim-doc/doc-txt     ChangeLog 
    exim-src/src         exim.c functions.h tls-gnu.c 
                         tls-openssl.c 
  Log:
  TLS version reporting.  fixes: #745


  Revision  Changes    Path
  1.568     +2 -0      exim/exim-doc/doc-txt/ChangeLog
  1.63      +8 -0      exim/exim-src/src/exim.c
  1.45      +1 -0      exim/exim-src/src/functions.h
  1.22      +20 -0     exim/exim-src/src/tls-gnu.c
  1.15      +24 -0     exim/exim-src/src/tls-openssl.c


  Index: ChangeLog
  ===================================================================
  RCS file: /home/cvs/exim/exim-doc/doc-txt/ChangeLog,v
  retrieving revision 1.567
  retrieving revision 1.568
  diff -u -r1.567 -r1.568
  --- ChangeLog    14 Oct 2009 13:43:40 -0000    1.567
  +++ ChangeLog    14 Oct 2009 13:52:48 -0000    1.568
  @@ -1,4 +1,4 @@
  -$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.567 2009/10/14 13:43:40 nm4 Exp $
  +$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.568 2009/10/14 13:52:48 nm4 Exp $


Change log file for Exim from version 4.21
-------------------------------------------
@@ -105,6 +105,8 @@

NM/18 Bugzilla 894: Fix issue with very long lines including comments in lsearch

+NM/18 Bugzilla 745: TLS version reporting
+

Exim version 4.69
-----------------

  Index: exim.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/exim.c,v
  retrieving revision 1.62
  retrieving revision 1.63
  diff -u -r1.62 -r1.63
  --- exim.c    10 Jun 2009 07:34:04 -0000    1.62
  +++ exim.c    14 Oct 2009 13:52:48 -0000    1.63
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/exim.c,v 1.62 2009/06/10 07:34:04 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/exim.c,v 1.63 2009/10/14 13:52:48 nm4 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -1055,6 +1055,14 @@
     }


fprintf(f, "Size of off_t: %d\n", sizeof(off_t));
+
+/* This runtime check is to help diagnose library linkage mismatches which
+result in segfaults and the like; as such, it's left until the end,
+just in case. There will still be a "Configuration file is" line still to
+come. */
+#ifdef SUPPORT_TLS
+tls_version_report(f);
+#endif
}



  Index: functions.h
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/functions.h,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -r1.44 -r1.45
  --- functions.h    10 Jun 2009 07:34:04 -0000    1.44
  +++ functions.h    14 Oct 2009 13:52:48 -0000    1.45
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/functions.h,v 1.44 2009/06/10 07:34:04 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/functions.h,v 1.45 2009/10/14 13:52:48 nm4 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -35,6 +35,7 @@
   extern BOOL    tls_smtp_buffered(void);
   extern int     tls_ungetc(int);
   extern int     tls_write(const uschar *, size_t);
  +extern void    tls_version_report(FILE *);
   #endif




  Index: tls-gnu.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/tls-gnu.c,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- tls-gnu.c    10 Jun 2009 07:34:04 -0000    1.21
  +++ tls-gnu.c    14 Oct 2009 13:52:48 -0000    1.22
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/tls-gnu.c,v 1.21 2009/06/10 07:34:04 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/tls-gnu.c,v 1.22 2009/10/14 13:52:48 nm4 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -1298,4 +1298,24 @@
   tls_active = -1;
   }


  +
  +
  +
  +/*************************************************
  +*         Report the library versions.           *
  +*************************************************/
  +
  +/* See a description in tls-openssl.c for an explanation of why this exists.
  +
  +Arguments:   a FILE* to print the results to
  +Returns:     nothing
  +*/
  +
  +void
  +tls_version_report(FILE *f)
  +{
  +fprintf(f, "GnuTLS compile-time version: %s\n", LIBGNUTLS_VERSION);
  +fprintf(f, "GnuTLS runtime version: %s\n", gnutls_check_version(NULL));
  +}
  +
   /* End of tls-gnu.c */


  Index: tls-openssl.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/tls-openssl.c,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- tls-openssl.c    10 Jun 2009 07:34:04 -0000    1.14
  +++ tls-openssl.c    14 Oct 2009 13:52:48 -0000    1.15
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/tls-openssl.c,v 1.14 2009/06/10 07:34:04 tom Exp $ */
  +/* $Cambridge: exim/exim-src/src/tls-openssl.c,v 1.15 2009/10/14 13:52:48 nm4 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -1025,4 +1025,28 @@
   tls_active = -1;
   }


  +
  +
  +
  +/*************************************************
  +*         Report the library versions.           *
  +*************************************************/
  +
  +/* There have historically been some issues with binary compatibility in
  +OpenSSL libraries; if Exim (like many other applications) is built against
  +one version of OpenSSL but the run-time linker picks up another version,
  +it can result in serious failures, including crashing with a SIGSEGV.  So
  +report the version found by the compiler and the run-time version.
  +
  +Arguments:   a FILE* to print the results to
  +Returns:     nothing
  +*/
  +
  +void
  +tls_version_report(FILE *f)
  +{
  +fprintf(f, "OpenSSL compile-time version: %s\n", OPENSSL_VERSION_TEXT);
  +fprintf(f, "OpenSSL runtime version: %s\n", SSLeay_version(SSLEAY_VERSION));
  +}
  +
   /* End of tls-openssl.c */