[Pidgin] #3192: Support for older versions of SSL GnuTLS (ie. on RHEL4)

Pidgin trac at pidgin.im
Tue Sep 18 23:33:44 EDT 2007


#3192: Support for older versions of SSL GnuTLS (ie. on RHEL4)
--------------------------------+-------------------------------------------
 Reporter:  QuLogic             |       Type:  patch
   Status:  new                 |   Priority:  minor
Component:  pidgin (gtk)        |    Version:  2.2.0
 Keywords:  GnuTLS, SSL, RHEL4  |    Pending:  0    
--------------------------------+-------------------------------------------
 Just doing some work to get Pidgin to compile on RHEL4. The main point of
 this ticket is GnuTLS, but I'll write about other RHEL4 issues in case
 anyone needs to know.

 The first fix is to remove `_t` from
 `gnutls_{session,datum,x509_crt,x509_crt_fmt}_t`. The old versions didn't
 have the _t, but the new ones #define the non-_t versions as well as the
 _t versions, so it should work fine. The attached patch `pidgin-gnutls-
 types.patch` fixes this. Also fixes #3106.

 The second problem is that older versions of GnuTLS have an off-by-one
 error when filling out the size of the buffer in the functions
 `gnutls_x509_crt_get_dn`, and `gnutls_x509_crt_get_issuer_dn`. I'm not
 sure whether a similar bug affects `gnutls_x509_crt_get_dn_by_oid`.
 Nevertheless, the attached patch `pidgin-old-gnutls-bugfixes.patch` adds 1
 to the buffer size when using those 3 functions so that these items are
 returned properly. This takes care of some invalid certificate request
 type things, as well as a crash. The crash occurs in
 `x509_certificate_signed_by` when calling `strcmp` with NULL values as
 part of a `purple_debug_info` message. As it's a debug message, I didn't
 fix this bug, since I thought someone who worked on the code would know a
 better fix (ie. what they ''really'' wanted reported).

 Those two fixes allow Pidgin to compile and run (MSN and GTalk) on RHEL4,
 which has a version 1.0.20 of GnuTLS.

 The other issues for RHEL4:
  1. First off, needed to add some G_GNUC_NULL_TERMINATED (in
 `libpurple/plugins/{helloworld,notify_example}.c`), but I think that's
 been committed.
  1. Also needed to add some #includes like in #3144.

-- 
Ticket URL: <http://developer.pidgin.im/ticket/3192>
Pidgin <http://pidgin.im>
Pidgin


More information about the Tracker mailing list