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

Bug#360788: marked as done (lprng prints garbage when using libnss-ldap)



Your message dated Tue, 01 Aug 2006 04:47:11 -0700
with message-id <E1G7siN-0006gf-4n@spohr.debian.org>
and subject line Bug#360788: fixed in lprng 3.8.28-5
has caused the attached Bug report 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 I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---
Package: lprng
Version: 3.8.28-2
Severity: important
Tags: patch



Lpd closes all file descriptors after forking, including
the persistant LDAP and syslog sockets used by libnss-ldap.  
It then happens to re-use one of these for the socket to the printer.  
The effect is that LDAP queries and/or syslog messages get
routed directly to the printer.  

The flow of events in lpd is as follows: 
1) Make_passthrough() forks
2) child calls Full_daemon_perms() - This creates new sockets for LDAP.
3) child calls close_on_exec()     - This closes the LDAP descriptor
4) child continues and later reuses the LDAP descriptor.

The fix is to call  Full_daemon_perms() after the close_on_exec().

--- lprng-3.8.28/src/common/linelist.c.dist     2006-04-04
11:06:09.000000000 -0500
+++ lprng-3.8.28/src/common/linelist.c  2006-04-04 12:35:52.000000000
-0500
@@ -2755,6 +2755,7 @@
                } else {
                        Full_user_perms();
                }
+               close_on_exec(passfd->count);
                for( i = 0; i < passfd->count; ++i ){
                        fd = Cast_ptr_to_int(passfd->list[i]);
                        if( dup2(fd,i) == -1 ){
@@ -2764,7 +2765,6 @@
                                exit(JFAIL);
                        }
                }
-               close_on_exec(passfd->count);
                execve(cmd.list[0],cmd.list,env.list);
                SNPRINTF(error,sizeof(error))
                        "Make_passthrough: pid %d, execve '%s' failed -
'%s'\n", getpid(),




-- System Information:
Debian Release: 3.1
Architecture: i386 (i686)
Kernel: Linux 2.6.14.3.dell2850.120105
Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1)

Versions of packages lprng depends on:
ii  debconf                   1.4.30.13      Debian configuration management sy
ii  libc6                     2.3.2.ds1-22   GNU C Library: Shared libraries an
ii  libcomerr2                1.37-2sarge1   common error description library
ii  libkrb53                  1.3.6-2sarge2  MIT Kerberos runtime libraries
ii  libssl0.9.7               0.9.7e-3sarge1 SSL shared libraries

-- debconf information:
* lprng/start_lpd: true
  lprng/twolpd_perms:
  lprng/twolpd_conf:
  lprng/setuid_tools: false


--- End Message ---
--- Begin Message ---
Source: lprng
Source-Version: 3.8.28-5

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

lprng-doc_3.8.28-5_all.deb
  to pool/main/l/lprng/lprng-doc_3.8.28-5_all.deb
lprng_3.8.28-5.diff.gz
  to pool/main/l/lprng/lprng_3.8.28-5.diff.gz
lprng_3.8.28-5.dsc
  to pool/main/l/lprng/lprng_3.8.28-5.dsc
lprng_3.8.28-5_i386.deb
  to pool/main/l/lprng/lprng_3.8.28-5_i386.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 360788@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Craig Small <csmall@debian.org> (supplier of updated lprng 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.7
Date: Tue, 18 Jul 2006 11:11:02 +1000
Source: lprng
Binary: lprng lprng-doc
Architecture: source i386 all
Version: 3.8.28-5
Distribution: unstable
Urgency: low
Maintainer: Craig Small <csmall@debian.org>
Changed-By: Craig Small <csmall@debian.org>
Description: 
 lprng      - lpr/lpd printer spooling system
 lprng-doc  - lpr/lpd printer spooling system (documentation)
Closes: 311774 358628 360788 368482 377249
Changes: 
 lprng (3.8.28-5) unstable; urgency=low
 .
   * close fds before LDAP sockets Closes: #360788
   * Check configuration file location only with old prev versions
   * preinst has POSIX checks Closes: #358628
   * lp.1 optios->options Closes: #368482
   * README and lpd.conf.8 mention unix_socket_path Closes: #311774
   * Updated nl.po Closes: #377249
   * Standards version 3.7.2
Files: 
 4f97ea48d29b231c7e92a533e60f12cd 729 net extra lprng_3.8.28-5.dsc
 68a4f7a93858be0c06f13c14d6f18579 43487 net extra lprng_3.8.28-5.diff.gz
 02988a35b28ed2ff0f6264c3019fd3cc 3213720 doc extra lprng-doc_3.8.28-5_all.deb
 4d5a759f7485a89d862886515477a684 1813188 net extra lprng_3.8.28-5_i386.deb

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

iD8DBQFEzzvvx2zlrBLK36URAr4PAJ0ZrwJqavxe5ot2wqX62eDfPS1OkgCeO2fD
yo4dHwRyODvRBNJLTAHdn4g=
=UM46
-----END PGP SIGNATURE-----


--- End Message ---

Reply to: