[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#618026: marked as done (pu: package ibid/0.1.0+dfsg-2+squeeze1)



Your message dated Mon, 26 Sep 2011 19:55:21 +0000
with message-id <E1R8HGr-0002ZZ-Ib@franck.debian.org>
and subject line Bug#618026: fixed in ibid 0.1.0+dfsg-2+squeeze1
has caused the Debian Bug report #618026,
regarding pu: package ibid/0.1.0+dfsg-2+squeeze1
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
618026: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=618026
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: ibid
Version: 0.1.0+dfsg-2
Severity: serious
Tags: security upstream patch

Ibid 0.1.1 fixes 3 security issues [0]. They aren't particularly serious, but
should probably be addressed.

[0]: http://ibid.omnia.za.net/docs/0.1.0/changes.html#release-0-1-1-pimpernel-2011-02-24

Remote Execution:
  http://bugs.launchpad.net/bugs/705860
    Permissions were ignored for handlers not using @match. This allowed users
    to perform actions they were not authorised to.

    However, no included plugins were exposed by this, all
    access-restricted handlers had match patterns.

Information Disclosure:

  http://bugs.launchpad.net/bugs/567576
    Occasionally insecure permissions on log files. When the bot spoke
    first (creating a new log file), the log file would be publicly
    readable, even if the message was sent in private.

    Example: If the bot delivered a privmsg memo to a user at the
    beginning of the month, it would create the logfile with public
    readable permissions. If the logfile directory was published by a
    web server, this would make this private conversation log accessible
    to the public.

    Resolution: Now channels must be explicitly configured to have
    publicly readable logs.

  http://bugs.launchpad.net/649383
    If someone received a private message from the bot during a public
    meeting, the message could appear in the meeting minutes.

    Example: a privmsg memo received during a meeting would appear in
    the minutes.

Proposed debdiff with backported fixes attached.

SR

-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/8 CPU cores)
Locale: LANG=en_ZA.UTF-8, LC_CTYPE=en_ZA.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages ibid depends on:
ii  libjs-jquery            1.5.1-1          JavaScript library for dynamic web
ii  python                  2.6.6-3+squeeze5 interactive high-level object-orie
ii  python-beautifulsoup    3.2.0-1          error-tolerant HTML parser for Pyt
ii  python-chardet          2.0.1-1          universal character encoding detec
ii  python-configobj        4.7.2+ds-1       simple but powerful config file re
ii  python-dateutil         1.4.1-3          powerful extensions to the standar
ii  python-html5lib         0.90-1           HTML parser/tokenizer based on the
ii  python-jinja            1.2-3+b1         small but fast and easy to use sta
ii  python-pkg-resources    0.6.14-5         Package Discovery and Resource Acc
ii  python-soappy           0.12.0-4         SOAP Support for Python
ii  python-sqlalchemy       0.6.3-3          SQL toolkit and Object Relational 
ii  python-twisted-core     10.2.0-1         Event-based framework for internet
ii  python-twisted-web      10.2.0-1         An HTTP protocol implementation to
ii  python-twisted-words    10.2.0-1         Chat and Instant Messaging
ii  python-zope.interface [ 3.5.3-1+b1       Interfaces for Python
ii  python2.5               2.5.5-11         An interactive high-level object-o
ii  python2.6               2.6.6-8+b1       An interactive high-level object-o

Versions of packages ibid recommends:
ii  fortune-mod [fortune]       1:1.99.1-4   provides fortune cookies on demand
ii  ipcalc                      0.41-2       parameter calculator for IPv4 addr
ii  iputils-ping                3:20101006-1 Tools to test the reachability of 
ii  iputils-tracepath           3:20101006-1 Tools to trace the network path to
ii  man-db                      2.5.9-4      on-line manual pager
ii  python-dictclient           1.0.3.1      Python client library for DICT (RF
ii  python-dnspython            1.8.0-1      DNS toolkit for Python
ii  python-feedparser           4.1-14       Universal Feed Parser for Python
pn  python-html2text            <none>       (no description available)
ii  python-imdbpy               4.7.0-1      Python package to access the IMDb'
ii  python-twisted-mail         10.2.0-1     An SMTP, IMAP and POP protocol imp
ii  python-wokkel               0.6.3-2      collection of enhancements for Twi
ii  units                       1.87-2       converts between different systems

Versions of packages ibid suggests:
ii  apt-file                   2.4.2         search for files within Debian pac
ii  aptitude                   0.6.3-3.2     terminal-based package manager (te
ii  bc                         1.06.95-2     The GNU bc arbitrary precision cal
ii  bzr                        2.3.0-6       easy to use distributed version co
ii  caca-utils                 0.99.beta17-1 text mode graphics utilities
ii  dictd                      1.12.0+dfsg-3 dictionary server
ii  nmap                       5.21-1        The Network Mapper
ii  python-aalib               0.2-1         Python interface to AAlib, an ASCI
ii  python-dbus                0.83.1-1      simple interprocess messaging syst
ii  python-imaging             1.1.7-2       Python Imaging Library
ii  python-matplotlib          0.99.3-1      Python based plotting system in a 
ii  python-mysqldb             1.2.2-10+b1   A Python interface to MySQL
ii  python-numpy               1:1.4.1-5     Numerical Python adds a fast array
ii  python-objgraph            1.7.0-1       Module for exploring Python object
ii  python-psycopg2            2.2.1-1       Python module for PostgreSQL
ii  python-pyfiglet            0.4+dfsg-2    Python port of the FIGlet specific
ii  python-silc                0.5-1         Python bindings for SILC
ii  python-svn                 1.7.2-4       A(nother) Python interface to Subv
diff -Nru ibid-0.1.0+dfsg/debian/changelog ibid-0.1.0+dfsg/debian/changelog
--- ibid-0.1.0+dfsg/debian/changelog	2010-06-17 19:23:31.000000000 +0200
+++ ibid-0.1.0+dfsg/debian/changelog	2011-03-13 16:02:23.000000000 +0200
@@ -1,3 +1,16 @@
+ibid (0.1.0+dfsg-2+squeeze1) stable-security; urgency=high
+
+  * Fix the following security issues. Fixes backported from 0.1.1 bugfix
+    release.
+    - perms-705860.patch: Enforce access-restriction on handlers without
+      @match patterns. (LP: #705860)
+    - logfile-visibility-567576.patch: Channels must be explicitly configured
+      to have publicly readable logs. (LP: #567576)
+    - meeting-privacy-649383.patch: Don't report private messages from the bot
+      in meeting minutes. (LP: #649383)
+
+ -- Stefano Rivera <stefanor@debian.org>  Sun, 13 Mar 2011 15:50:35 +0200
+
 ibid (0.1.0+dfsg-2) unstable; urgency=low
 
   * Don't leak uid and umask into source tarball.
diff -Nru ibid-0.1.0+dfsg/debian/patches/logfile-visibility-567576.patch ibid-0.1.0+dfsg/debian/patches/logfile-visibility-567576.patch
--- ibid-0.1.0+dfsg/debian/patches/logfile-visibility-567576.patch	1970-01-01 02:00:00.000000000 +0200
+++ ibid-0.1.0+dfsg/debian/patches/logfile-visibility-567576.patch	2011-03-13 16:19:07.000000000 +0200
@@ -0,0 +1,85 @@
+Description: Channels must be explicitly configured to have publicly readable logs.
+ Occasionally insecure permissions on log files. When the bot spoke first
+ (creating a new log file), the log file would be publicly readable, even if
+ the message was sent in private.
+ .
+ Resolution: Now channels must be explicitly configured to have publicly
+ readable logs.
+Bug-Upstream: https://bugs.launchpad.net/ibid/+bug/567576
+Origin: upstream, https://code.launchpad.net/~stefanor/ibid/logfile-visibility-567576-0.1/+merge/36937
+Last-Update: 2011-03-13
+
+--- a/ibid/plugins/log.py
++++ b/ibid/plugins/log.py
+@@ -4,6 +4,8 @@
+ """Logs messages sent and received."""
+ 
+ from datetime import datetime
++import fnmatch
++import logging
+ from os.path import dirname, join, expanduser
+ from os import chmod, makedirs
+ 
+@@ -11,9 +13,11 @@
+ 
+ import ibid
+ from ibid.plugins import Processor, handler
+-from ibid.config import Option, BoolOption
++from ibid.config import Option, BoolOption, ListOption
+ from ibid.event import Event
+ 
++log = logging.getLogger('plugins.log')
++
+ class Log(Processor):
+ 
+     addressed = False
+@@ -38,6 +42,9 @@
+     rename_format = Option('rename_format', 'Format string for rename events',
+             u'%(timestamp)s %(sender_nick)s (%(sender_connection)s) has renamed to %(new_nick)s')
+ 
++    public_logs = ListOption('public_logs',
++            u'List of source:channel globs for channels which should have public logs',
++            [])
+     public_mode = Option('public_mode',
+             u'File Permissions mode for public channels, in octal', '644')
+     private_mode = Option('private_mode',
+@@ -47,6 +54,21 @@
+ 
+     logs = {}
+ 
++    def setup(self):
++        sources = list(set(ibid.config.sources.keys())
++                       | set(ibid.sources.keys()))
++        for glob in self.public_logs:
++            if u':' not in glob:
++                log.warning(u"public_logs configuration values must follow the "
++                            u"format source:channel. \"%s\" doesn't contain a "
++                            u"colon.", glob)
++                continue
++            source_glob = glob.split(u':', 1)[0]
++            if not fnmatch.filter(sources, source_glob):
++                log.warning(u'public_logs includes "%s", but there is no '
++                            u'configured source matching "%s"',
++                            glob, source_glob)
++
+     def get_logfile(self, event):
+         when = event.time
+         if not self.date_utc:
+@@ -70,8 +92,15 @@
+ 
+             file = open(filename, 'a')
+             self.logs[filename] = file
+-            if event.get('public', True):
+-                chmod(filename, int(self.public_mode, 8))
++
++            for glob in self.public_logs:
++                if u':' not in glob:
++                    continue
++                source_glob, channel_glob = glob.split(u':', 1)
++                if (fnmatch.fnmatch(event.source, source_glob)
++                        and fnmatch.fnmatch(event.channel, channel_glob)):
++                    chmod(filename, int(self.public_mode, 8))
++                    break
+             else:
+                 chmod(filename, int(self.private_mode, 8))
+ 
diff -Nru ibid-0.1.0+dfsg/debian/patches/meeting-privacy-649383.patch ibid-0.1.0+dfsg/debian/patches/meeting-privacy-649383.patch
--- ibid-0.1.0+dfsg/debian/patches/meeting-privacy-649383.patch	1970-01-01 02:00:00.000000000 +0200
+++ ibid-0.1.0+dfsg/debian/patches/meeting-privacy-649383.patch	2011-03-13 16:20:08.000000000 +0200
@@ -0,0 +1,21 @@
+Description: Don't report private messages from the bot in meeting minutes.
+ If someone received a private message from the bot during a public meeting,
+ the message could appear in the meeting minutes.
+Origin: upstream, https://code.launchpad.net/~max-rabkin/ibid/meeting-privacy-649383-0.1/+merge/36810
+Bug-Upstream: https://bugs.launchpad.net/ibid/+bug/649383
+Last-Update: 2011-03-13
+
+--- a/ibid/plugins/meetings.py
++++ b/ibid/plugins/meetings.py
+@@ -259,7 +259,10 @@
+                 'message': message,
+                 'time': event.time,
+             })
+-            for response in event.responses:
++        for response in event.responses:
++            if (response['source'], response['target']) in meetings:
++                meeting = meetings[(response['source'], response['target'])]
++
+                 type = 'message'
+                 if response.get('action', False):
+                     type = 'action'
diff -Nru ibid-0.1.0+dfsg/debian/patches/perms-705860.patch ibid-0.1.0+dfsg/debian/patches/perms-705860.patch
--- ibid-0.1.0+dfsg/debian/patches/perms-705860.patch	1970-01-01 02:00:00.000000000 +0200
+++ ibid-0.1.0+dfsg/debian/patches/perms-705860.patch	2011-03-13 16:18:18.000000000 +0200
@@ -0,0 +1,38 @@
+Description: Enforce access-restriction on handlers without @match patterns.
+ Permissions were ignored for handlers not using @match. This allowed users to
+ perform actions they were not authorised to.
+Bug-Upstream: https://bugs.launchpad.net/ibid/+bug/705860
+Origin: upstream, https://code.launchpad.net/~max-rabkin/ibid/perms-705860/+merge/47037
+Last-Update: 2011-03-13
+
+--- a/ibid/plugins/__init__.py
++++ b/ibid/plugins/__init__.py
+@@ -131,19 +131,22 @@
+ 
+         found = False
+         for method in self._get_event_handlers():
++            args = None
+             if not hasattr(method, 'pattern'):
+                 found = True
+-                method(event)
++                args = ()
+             elif hasattr(event, 'message'):
+                 found = True
+                 match = method.pattern.search(
+                         event.message[method.message_version])
+                 if match is not None:
+-                    if (not getattr(method, 'auth_required', False)
+-                            or auth_responses(event, self.permission)):
+-                        method(event, *match.groups())
+-                    elif not getattr(method, 'auth_fallthrough', True):
+-                        event.processed = True
++                    args = match.groups()
++            if args is not None:
++                if (not getattr(method, 'auth_required', False)
++                        or auth_responses(event, self.permission)):
++                    method(event, *args)
++                elif not getattr(method, 'auth_fallthrough', True):
++                    event.processed = True
+ 
+         if not found:
+             raise RuntimeError(u'No handlers found in %s' % self)
diff -Nru ibid-0.1.0+dfsg/debian/patches/series ibid-0.1.0+dfsg/debian/patches/series
--- ibid-0.1.0+dfsg/debian/patches/series	2010-06-17 11:48:50.000000000 +0200
+++ ibid-0.1.0+dfsg/debian/patches/series	2011-03-13 16:15:03.000000000 +0200
@@ -3,3 +3,6 @@
 docs.diff
 separate-data.diff
 fortune-path.diff
+perms-705860.patch
+logfile-visibility-567576.patch
+meeting-privacy-649383.patch

--- End Message ---
--- Begin Message ---
Source: ibid
Source-Version: 0.1.0+dfsg-2+squeeze1

We believe that the bug you reported is fixed in the latest version of
ibid, which is due to be installed in the Debian FTP archive:

ibid_0.1.0+dfsg-2+squeeze1.debian.tar.gz
  to main/i/ibid/ibid_0.1.0+dfsg-2+squeeze1.debian.tar.gz
ibid_0.1.0+dfsg-2+squeeze1.dsc
  to main/i/ibid/ibid_0.1.0+dfsg-2+squeeze1.dsc
ibid_0.1.0+dfsg-2+squeeze1_all.deb
  to main/i/ibid/ibid_0.1.0+dfsg-2+squeeze1_all.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 618026@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Stefano Rivera <stefanor@debian.org> (supplier of updated ibid package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Mon, 26 Sep 2011 15:57:26 +0200
Source: ibid
Binary: ibid
Architecture: source all
Version: 0.1.0+dfsg-2+squeeze1
Distribution: stable
Urgency: medium
Maintainer: Debian Python Modules Team <python-modules-team@lists.alioth.debian.org>
Changed-By: Stefano Rivera <stefanor@debian.org>
Description: 
 ibid       - easily extensible Python IM bot for IRC, Jabber, SILC, campfire,
Closes: 618026
Changes: 
 ibid (0.1.0+dfsg-2+squeeze1) stable; urgency=medium
 .
   * Fix the following security issues. Fixes backported from 0.1.1 bugfix
     release (Closes: #618026):
     - perms-705860.patch: Enforce access-restriction on handlers without
       @match patterns. (LP: #705860)
     - logfile-visibility-567576.patch: Channels must be explicitly configured
       to have publicly readable logs. (LP: #567576)
     - meeting-privacy-649383.patch: Don't report private messages from the bot
       in meeting minutes. (LP: #649383)
   * http-features-fix-545168.patch: Fix the breakage of the http source
     (LP: #545168)
Checksums-Sha1: 
 8f614550ecc7aa17822fc9e269b9eadc356ac38a 2243 ibid_0.1.0+dfsg-2+squeeze1.dsc
 c1307e5f085c8676c53415a02c36aea95db99602 13917 ibid_0.1.0+dfsg-2+squeeze1.debian.tar.gz
 792bcd82745462994a6d1b2a7d3c49c6a6cd2465 307906 ibid_0.1.0+dfsg-2+squeeze1_all.deb
Checksums-Sha256: 
 9fd4f5c74a2ac816fbe32af80ab22d775bbddfb9c9fb0026e849293003ea0cff 2243 ibid_0.1.0+dfsg-2+squeeze1.dsc
 bbf4e9daf7c65a56a9af63b5b3b5a930e1a2b39bb893d899fe4089af34f5b3c1 13917 ibid_0.1.0+dfsg-2+squeeze1.debian.tar.gz
 e188fc5ff2a3fc43016332789d4912c1cb03dc333a67fd8aabd7259fe8eb0a28 307906 ibid_0.1.0+dfsg-2+squeeze1_all.deb
Files: 
 b1d1775f48b952c4343e298a1695a542 2243 net optional ibid_0.1.0+dfsg-2+squeeze1.dsc
 1307d8b4198f82c99aaf97174b06bc49 13917 net optional ibid_0.1.0+dfsg-2+squeeze1.debian.tar.gz
 fdb50f1eed658d813a6387a5c0b173cd 307906 net optional ibid_0.1.0+dfsg-2+squeeze1_all.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iQIcBAEBAgAGBQJOgIYsAAoJEACQ/CG1zRrM8AQP/2Z5UKGMgcdTA9fE6dlb1KfH
VpBQOxBd5HmJY8vDfdxCo6FS9g0oVrY0LpjEjNc3gjNUA/5JA4TE5pDPDXvqn5AC
uoH5gohlbEW8Gvk6VD4pMi8+zTWQXFspbOBLXCZW34Oegn/d/N5LYDUyZsC9Yqoo
6wfLdLNphURfv7hgz9Ybnu6ITe3XvjVRgMA3wzpM89FVjgrht3HGwv1H/fQT6Slv
/ZJchEHWj4g6Kfb7dMCe2ATFrRoxvLgRTMgcHb+slRDtaStRWpGYsekYk6hzPVy1
iHzecv78GYU/iIoDrCSm6uQItxLrhsM+Mp89u7Csy6adQOC43ZWvUhK5SWXwzNwQ
JNhI21iE/9VAQsbvMHC27Yo0p7T9dxIm/AVvNbhAhINAn1vNebhzrLgWgCiIEmTo
cfgwWvJ0s3ej7TcMS0v5iH9nAptth5Erzewcc/3vxcRrzhmE75ApZLXsnTVWz2st
qtTOkhAd9Ec6n+8zWwjd8qoqFpPowo4qKg31wacW9yZJq4s5y5Dz2Nm9p+uGpbhV
/T7gocJ2HAP4z0X8Y3aOeAWgNfOGspy28nF+r5X6lEsdD2437/BmozxfQyCqatSh
dZhx+Yv6dvB041j2dEJokj//F0ylH7E6PXlvwj4PDPIyZjnFp3gXTRQSyxHom1Sf
hcLduNbfRw2wI3mtxMp1
=1ylF
-----END PGP SIGNATURE-----



--- End Message ---

Reply to: