[Pkg-cups-devel] r123 - in cupsys/branches/cups-1.2/debian: . patches

Martin Pitt mpitt at costa.debian.org
Wed Apr 5 12:26:34 UTC 2006


Author: mpitt
Date: Wed Apr  5 12:26:33 2006
New Revision: 123

Added:
   cupsys/branches/cups-1.2/debian/patches/06_disable_backend_setuid.dpatch   (contents, props changed)
Modified:
   cupsys/branches/cups-1.2/debian/changelog
   cupsys/branches/cups-1.2/debian/patches/00list
Log:
* Add debian/patches/06_disable_backend_setuid.dpatch: Remove the uid
  changing in scheduler/cups-deviced.c which was introduced recently in
  upstream. It totally breaks device node access (e. g. /dev/lp0 is root:lp
  0660, which is inaccessible for a process which runs as lp:root).



Modified: cupsys/branches/cups-1.2/debian/changelog
==============================================================================
--- cupsys/branches/cups-1.2/debian/changelog	(original)
+++ cupsys/branches/cups-1.2/debian/changelog	Wed Apr  5 12:26:33 2006
@@ -43,8 +43,12 @@
   * debian/libcupsys2-dev.files, debian/libcupsimage2-dev.files: Remove static
     library; upstream does not build them any more, and they are useless
     anyway.
+  * Add debian/patches/06_disable_backend_setuid.dpatch: Remove the uid
+    changing in scheduler/cups-deviced.c which was introduced recently in
+    upstream. It totally breaks device node access (e. g. /dev/lp0 is root:lp
+    0660, which is inaccessible for a process which runs as lp:root).
 
- -- Martin Pitt <mpitt at debian.org>  Wed,  5 Apr 2006 12:40:55 +0200
+ -- Martin Pitt <mpitt at debian.org>  Wed,  5 Apr 2006 14:25:28 +0200
 
 cupsys (1.1.99.b1.r4885-1) experimental; urgency=low
 

Modified: cupsys/branches/cups-1.2/debian/patches/00list
==============================================================================
--- cupsys/branches/cups-1.2/debian/patches/00list	(original)
+++ cupsys/branches/cups-1.2/debian/patches/00list	Wed Apr  5 12:26:33 2006
@@ -4,6 +4,7 @@
 03_clean.dpatch
 04_freebsd.dpatch
 05_avoidunknowngroup.dpatch
+06_disable_backend_setuid.dpatch
 07_removecvstag.dpatch
 08_cupsd.conf.conf.d.dpatch
 #09_runasuser_fixes.dpatch

Added: cupsys/branches/cups-1.2/debian/patches/06_disable_backend_setuid.dpatch
==============================================================================
--- (empty file)
+++ cupsys/branches/cups-1.2/debian/patches/06_disable_backend_setuid.dpatch	Wed Apr  5 12:26:33 2006
@@ -0,0 +1,34 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 06_disable_backend_setuid.dpatch by  <mpitt at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+ at DPATCH@
+diff -urNad cupsys~/scheduler/cups-deviced.c cupsys/scheduler/cups-deviced.c
+--- cupsys~/scheduler/cups-deviced.c	2006-03-08 13:12:12.000000000 +0100
++++ cupsys/scheduler/cups-deviced.c	2006-04-05 14:18:19.000000000 +0200
+@@ -210,23 +210,6 @@
+       continue;
+ 
+    /*
+-    * Change effective users depending on the backend permissions...
+-    */
+-
+-    if (!getuid())
+-    {
+-     /*
+-      * Backends without permissions for normal users run as root,
+-      * all others run as the unprivileged user...
+-      */
+-
+-      if (!(dent->fileinfo.st_mode & (S_IRWXG | S_IRWXO)))
+-        seteuid(0);
+-      else
+-        seteuid(normal_user);
+-    }
+-
+-   /*
+     * Run the backend with no arguments and collect the output...
+     */
+ 



More information about the Pkg-cups-devel mailing list