Package: gnubiff Version: 2.2.13-3 Severity: important
In case of very large imap mailbox, imap server will answer a very long line which size if greater than default maximum size of 16384 (security/prevdos_line_length parameter in the expert tab). In that case, an incorrect error message if displayed on console in debug mode (Operation not permitted) which is because of strerror(status) where status is meaningless in that case (socket.cc, Socket::read). A patch aimed to guide the user to the problem in case of very large imap mailbox is provided (the message says to increase security/prevdos_line_length). -- System Information: Debian Release: squeeze/sid APT prefers testing APT policy: (500, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-5-amd64 (SMP w/4 CPU cores) Locale: LANG=C, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Versions of packages gnubiff depends on: ii dpkg 1.15.7.2 Debian package management system ii install-info 4.13a.dfsg.1-5 Manage installed documentation in ii libart-2.0-2 2.3.21-1 Library of functions for 2D graphi ii libatk1.0-0 1.30.0-1 The ATK accessibility toolkit ii libbonobo2-0 2.24.3-1 Bonobo CORBA interfaces library ii libbonoboui2-0 2.24.3-1 The Bonobo UI library ii libc6 2.11.2-2 Embedded GNU C Library: Shared lib ii libcairo2 1.8.10-4 The Cairo 2D vector graphics libra ii libfam0 2.7.0-17 Client library to control the FAM ii libfontconfig1 2.8.0-2.1 generic font configuration library ii libfreetype6 2.4.2-1 FreeType 2 font engine, shared lib ii libgcc1 1:4.4.4-8 GCC support library ii libgconf2-4 2.28.1-3 GNOME configuration database syste ii libglade2-0 1:2.6.4-1 library to load .glade files at ru ii libglib2.0-0 2.24.1-1 The GLib library of C routines ii libgnome2-0 2.30.0-1 The GNOME library - runtime files ii libgnomecanvas2-0 2.30.1-1 A powerful object-oriented display ii libgnomeui-0 2.24.3-1 The GNOME libraries (User Interfac ii libgnomevfs2-0 1:2.24.3-1 GNOME Virtual File System (runtime ii libgtk2.0-0 2.20.1-1 The GTK+ graphical user interface ii libice6 2:1.0.6-1 X11 Inter-Client Exchange library ii liborbit2 1:2.14.18-0.1 libraries for ORBit2 - a CORBA ORB ii libpanel-applet2-0 2.30.2-1 library for GNOME Panel applets ii libpango1.0-0 1.28.1-1 Layout and rendering of internatio ii libpopt0 1.16-1 lib for parsing cmdline parameters ii libsm6 2:1.1.1-1 X11 Session Management library ii libssl0.9.8 0.9.8o-1 SSL shared libraries ii libstdc++6 4.4.4-8 The GNU Standard C++ Library v3 ii libx11-6 2:1.3.3-3 X11 client-side library ii libxml2 2.7.7.dfsg-4 GNOME XML library ii sox 14.3.1-1+b1 Swiss army knife of sound processi Versions of packages gnubiff recommends: ii fam 2.7.0-17 File Alteration Monitor gnubiff suggests no packages. -- no debconf information
diff -ur gnubiff-2.2.13/src/socket.cc b/src/socket.cc --- gnubiff-2.2.13/src/socket.cc 2010-02-06 15:39:37.000000000 +0100 +++ b/src/socket.cc 2010-08-28 17:48:54.000000000 +0200 @@ -401,15 +401,25 @@ line.c_str()); break; default: - g_message ("[%d] RECV ERROR(%s:%d): %s", uin_, hostname_.c_str(), - port_, strerror(status)); + if (cnt <= 0) + g_message ("[%d] RECV ERROR(%s:%d): line too long, " + "security/prevdos_line_length should be increased", + uin_, hostname_.c_str(), port_); + else + g_message ("[%d] RECV ERROR(%s:%d): %s", uin_, + hostname_.c_str(), port_, + strerror(status)); break; } } #endif if (status_ == SOCKET_STATUS_ERROR) { - g_warning (_("[%d] Unable to read from %s on port %d"), uin_, - hostname_.c_str(), port_); + if (cnt <= 0) + g_warning (_("[%d] line too long, security/prevdos_line_length " + "should be increased"), uin_); + else + g_warning (_("[%d] Unable to read from %s on port %d"), + uin_, hostname_.c_str(), port_); close(); }