diff --git a/.cvsignore b/.cvsignore index 8e2a7ba..6b6d8ea 100644 --- a/.cvsignore +++ b/.cvsignore @@ -35,3 +35,4 @@ cups-1.3.7-source.tar.bz2 cups-1.3.8-source.tar.bz2 cups-1.3.9-source.tar.bz2 cups-1.4b1-source.tar.bz2 +cups-1.4b2-source.tar.bz2 diff --git a/cups-CVE-2008-5183.patch b/cups-CVE-2008-5183.patch deleted file mode 100644 index 2c670ac..0000000 --- a/cups-CVE-2008-5183.patch +++ /dev/null @@ -1,170 +0,0 @@ -diff -up cups-1.4b1/scheduler/ipp.c.CVE-2008-5183 cups-1.4b1/scheduler/ipp.c ---- cups-1.4b1/scheduler/ipp.c.CVE-2008-5183 2008-12-09 12:16:15.000000000 +0000 -+++ cups-1.4b1/scheduler/ipp.c 2008-12-09 12:17:43.000000000 +0000 -@@ -2392,24 +2392,25 @@ add_job_subscriptions( - if (mask == CUPSD_EVENT_NONE) - mask = CUPSD_EVENT_JOB_COMPLETED; - -- sub = cupsdAddSubscription(mask, cupsdFindDest(job->dest), job, recipient, -- 0); -+ if ((sub = cupsdAddSubscription(mask, cupsdFindDest(job->dest), job, -+ recipient, 0)) != NULL) -+ { -+ sub->interval = interval; - -- sub->interval = interval; -+ cupsdSetString(&sub->owner, job->username); - -- cupsdSetString(&sub->owner, job->username); -+ if (user_data) -+ { -+ sub->user_data_len = user_data->values[0].unknown.length; -+ memcpy(sub->user_data, user_data->values[0].unknown.data, -+ sub->user_data_len); -+ } - -- if (user_data) -- { -- sub->user_data_len = user_data->values[0].unknown.length; -- memcpy(sub->user_data, user_data->values[0].unknown.data, -- sub->user_data_len); -+ ippAddSeparator(con->response); -+ ippAddInteger(con->response, IPP_TAG_SUBSCRIPTION, IPP_TAG_INTEGER, -+ "notify-subscription-id", sub->id); - } - -- ippAddSeparator(con->response); -- ippAddInteger(con->response, IPP_TAG_SUBSCRIPTION, IPP_TAG_INTEGER, -- "notify-subscription-id", sub->id); -- - if (attr) - attr = attr->next; - } -@@ -6668,7 +6669,12 @@ create_subscription( - else - job = NULL; - -- sub = cupsdAddSubscription(mask, printer, job, recipient, 0); -+ if ((sub = cupsdAddSubscription(mask, printer, job, recipient, 0)) == NULL) -+ { -+ send_ipp_status(con, IPP_TOO_MANY_SUBSCRIPTIONS, -+ _("There are too many subscriptions.")); -+ return; -+ } - - if (job) - cupsdLogMessage(CUPSD_LOG_DEBUG, "Added subscription %d for job %d", -diff -up cups-1.4b1/scheduler/subscriptions.c.CVE-2008-5183 cups-1.4b1/scheduler/subscriptions.c ---- cups-1.4b1/scheduler/subscriptions.c.CVE-2008-5183 2008-12-09 12:16:15.000000000 +0000 -+++ cups-1.4b1/scheduler/subscriptions.c 2008-12-09 12:17:43.000000000 +0000 -@@ -341,8 +341,54 @@ cupsdAddSubscription( - * Limit the number of subscriptions... - */ - -- if (cupsArrayCount(Subscriptions) >= MaxSubscriptions) -+ if (MaxSubscriptions > 0 && cupsArrayCount(Subscriptions) >= MaxSubscriptions) -+ { -+ cupsdLogMessage(CUPSD_LOG_DEBUG, -+ "cupsdAddSubscription: Reached MaxSubscriptions %d", -+ MaxSubscriptions); - return (NULL); -+ } -+ -+ if (MaxSubscriptionsPerJob > 0 && job) -+ { -+ int count; /* Number of job subscriptions */ -+ -+ for (temp = (cupsd_subscription_t *)cupsArrayFirst(Subscriptions), -+ count = 0; -+ temp; -+ temp = (cupsd_subscription_t *)cupsArrayNext(Subscriptions)) -+ if (temp->job == job) -+ count ++; -+ -+ if (count >= MaxSubscriptionsPerJob) -+ { -+ cupsdLogMessage(CUPSD_LOG_DEBUG, -+ "cupsdAddSubscription: Reached MaxSubscriptionsPerJob %d " -+ "for job #%d", MaxSubscriptionsPerJob, job->id); -+ return (NULL); -+ } -+ } -+ -+ if (MaxSubscriptionsPerPrinter > 0 && dest) -+ { -+ int count; /* Number of printer subscriptions */ -+ -+ for (temp = (cupsd_subscription_t *)cupsArrayFirst(Subscriptions), -+ count = 0; -+ temp; -+ temp = (cupsd_subscription_t *)cupsArrayNext(Subscriptions)) -+ if (temp->dest == dest) -+ count ++; -+ -+ if (count >= MaxSubscriptionsPerPrinter) -+ { -+ cupsdLogMessage(CUPSD_LOG_DEBUG, -+ "cupsdAddSubscription: Reached " -+ "MaxSubscriptionsPerPrinter %d for %s", -+ MaxSubscriptionsPerPrinter, dest->name); -+ return (NULL); -+ } -+ } - - /* - * Allocate memory for this subscription... -@@ -765,7 +811,6 @@ cupsdLoadAllSubscriptions(void) - cupsdLogMessage(CUPSD_LOG_ERROR, - "Syntax error on line %d of subscriptions.conf.", - linenum); -- break; - } - else if (!strcasecmp(line, "Events")) - { -diff -up cups-1.4b1/test/4.4-subscription-ops.test.CVE-2008-5183 cups-1.4b1/test/4.4-subscription-ops.test ---- cups-1.4b1/test/4.4-subscription-ops.test.CVE-2008-5183 2007-07-09 21:34:48.000000000 +0100 -+++ cups-1.4b1/test/4.4-subscription-ops.test 2008-12-09 12:17:43.000000000 +0000 -@@ -116,6 +116,32 @@ - EXPECT notify-events - DISPLAY notify-events - } -+{ -+ # The name of the test... -+ NAME "Check MaxSubscriptions limits" -+ -+ # The operation to use -+ OPERATION Create-Printer-Subscription -+ RESOURCE / -+ -+ # The attributes to send -+ GROUP operation -+ ATTR charset attributes-charset utf-8 -+ ATTR language attributes-natural-language en -+ ATTR uri printer-uri $method://$hostname:$port/printers/Test1 -+ -+ GROUP subscription -+ ATTR uri notify-recipient-uri testnotify:// -+ ATTR keyword notify-events printer-state-changed -+ ATTR integer notify-lease-duration 5 -+ -+ # What statuses are OK? -+ STATUS client-error-too-many-subscriptions -+ -+ # What attributes do we expect? -+ EXPECT attributes-charset -+ EXPECT attributes-natural-language -+} - - # - # End of "$Id: 4.4-subscription-ops.test 6635 2007-07-09 20:34:48Z mike $" -diff -up cups-1.4b1/test/run-stp-tests.sh.CVE-2008-5183 cups-1.4b1/test/run-stp-tests.sh ---- cups-1.4b1/test/run-stp-tests.sh.CVE-2008-5183 2008-10-02 00:56:42.000000000 +0100 -+++ cups-1.4b1/test/run-stp-tests.sh 2008-12-09 12:17:43.000000000 +0000 -@@ -326,6 +326,7 @@ PassEnv LOCALEDIR - DocumentRoot $root/doc - RequestRoot /tmp/cups-$user/spool - TempDir /tmp/cups-$user/spool/temp -+MaxSubscriptions 3 - MaxLogSize 0 - AccessLog /tmp/cups-$user/log/access_log - ErrorLog /tmp/cups-$user/log/error_log diff --git a/cups-build.patch b/cups-build.patch index 25b9714..4fa4611 100644 --- a/cups-build.patch +++ b/cups-build.patch @@ -1,18 +1,18 @@ -diff -up cups-1.4b1/Makedefs.in.build cups-1.4b1/Makedefs.in ---- cups-1.4b1/Makedefs.in.build 2008-10-04 06:57:54.000000000 +0100 -+++ cups-1.4b1/Makedefs.in 2008-11-11 16:36:30.000000000 +0000 -@@ -123,7 +123,7 @@ ARCHFLAGS = @ARCHFLAGS@ - ARFLAGS = @ARFLAGS@ +diff -up cups-1.4b2/Makedefs.in.build cups-1.4b2/Makedefs.in +--- cups-1.4b2/Makedefs.in.build 2008-11-11 00:57:12.000000000 +0000 ++++ cups-1.4b2/Makedefs.in 2008-12-16 11:30:09.000000000 +0000 +@@ -124,7 +124,7 @@ ARFLAGS = @ARFLAGS@ BACKLIBS = @BACKLIBS@ + BANNERTOPS = @BANNERTOPS@ CFLAGS = @CPPFLAGS@ @CFLAGS@ -COMMONLIBS = @LIBS@ +COMMONLIBS = @LIBS@ $(DNSSDLIBS) CUPSDLIBS = @CUPSDLIBS@ CXXFLAGS = @CPPFLAGS@ @CXXFLAGS@ CXXLIBS = @CXXLIBS@ -diff -up cups-1.4b1/scheduler/dirsvc.c.build cups-1.4b1/scheduler/dirsvc.c ---- cups-1.4b1/scheduler/dirsvc.c.build 2008-11-11 16:36:38.000000000 +0000 -+++ cups-1.4b1/scheduler/dirsvc.c 2008-11-11 16:39:09.000000000 +0000 +diff -up cups-1.4b2/scheduler/dirsvc.c.build cups-1.4b2/scheduler/dirsvc.c +--- cups-1.4b2/scheduler/dirsvc.c.build 2008-10-08 05:26:38.000000000 +0100 ++++ cups-1.4b2/scheduler/dirsvc.c 2008-12-16 11:30:09.000000000 +0000 @@ -1948,7 +1948,7 @@ cupsdUpdateDNSSDName(void) WebIFRef = DNSSDRef; diff --git a/cups-lspp.patch b/cups-lspp.patch index 233b0d1..766556e 100644 --- a/cups-lspp.patch +++ b/cups-lspp.patch @@ -1,6 +1,6 @@ -diff -up cups-1.4b1/config.h.in.lspp cups-1.4b1/config.h.in ---- cups-1.4b1/config.h.in.lspp 2008-09-08 23:03:01.000000000 +0100 -+++ cups-1.4b1/config.h.in 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/config.h.in.lspp cups-1.4b2/config.h.in +--- cups-1.4b2/config.h.in.lspp 2008-09-08 23:03:01.000000000 +0100 ++++ cups-1.4b2/config.h.in 2008-12-16 11:50:59.000000000 +0000 @@ -619,6 +619,13 @@ #undef HAVE_TCPD_H @@ -15,9 +15,9 @@ diff -up cups-1.4b1/config.h.in.lspp cups-1.4b1/config.h.in #endif /* !_CUPS_CONFIG_H_ */ /* -diff -up /dev/null cups-1.4b1/config-scripts/cups-lspp.m4 ---- /dev/null 2008-11-11 08:58:48.466006417 +0000 -+++ cups-1.4b1/config-scripts/cups-lspp.m4 2008-11-11 16:53:28.000000000 +0000 +diff -up /dev/null cups-1.4b2/config-scripts/cups-lspp.m4 +--- /dev/null 2008-12-16 09:52:24.540063413 +0000 ++++ cups-1.4b2/config-scripts/cups-lspp.m4 2008-12-16 11:50:59.000000000 +0000 @@ -0,0 +1,36 @@ +dnl +dnl LSPP code for the Common UNIX Printing System (CUPS). @@ -55,9 +55,9 @@ diff -up /dev/null cups-1.4b1/config-scripts/cups-lspp.m4 + ;; + esac +fi -diff -up cups-1.4b1/configure.in.lspp cups-1.4b1/configure.in ---- cups-1.4b1/configure.in.lspp 2008-08-04 21:55:13.000000000 +0100 -+++ cups-1.4b1/configure.in 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/configure.in.lspp cups-1.4b2/configure.in +--- cups-1.4b2/configure.in.lspp 2008-11-14 19:32:22.000000000 +0000 ++++ cups-1.4b2/configure.in 2008-12-16 11:50:59.000000000 +0000 @@ -42,6 +42,8 @@ sinclude(config-scripts/cups-pap.m4) sinclude(config-scripts/cups-pdf.m4) sinclude(config-scripts/cups-scripting.m4) @@ -67,10 +67,10 @@ diff -up cups-1.4b1/configure.in.lspp cups-1.4b1/configure.in INSTALL_LANGUAGES="" UNINSTALL_LANGUAGES="" LANGFILES="" -diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure ---- cups-1.4b1/configure.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/configure 2008-11-11 16:53:28.000000000 +0000 -@@ -827,6 +827,8 @@ PHP +diff -up cups-1.4b2/configure.lspp cups-1.4b2/configure +--- cups-1.4b2/configure.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/configure 2008-12-16 11:52:31.000000000 +0000 +@@ -829,6 +829,8 @@ PHP PHPCONFIG PHPDIR PYTHON @@ -79,15 +79,15 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure INSTALL_LANGUAGES UNINSTALL_LANGUAGES LIBOBJS -@@ -1455,6 +1457,7 @@ Optional Features: - --enable-raw-printing enable raw printing by default, default=auto +@@ -1459,6 +1461,7 @@ Optional Features: + --enable-texttops build with default text filter, default=auto --enable-pap build with AppleTalk support, default=auto --enable-pdftops build pdftops filter, default=auto + --enable-lspp turn on auditing and label support, default=no Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] -@@ -4647,7 +4650,7 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>& +@@ -4651,7 +4654,7 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>& else ac_cv_header_stdc=no fi @@ -96,7 +96,7 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure fi -@@ -4668,7 +4671,7 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>& +@@ -4672,7 +4675,7 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>& else ac_cv_header_stdc=no fi @@ -105,7 +105,7 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure fi -@@ -10323,10 +10326,10 @@ case "$uname" in +@@ -10327,10 +10330,10 @@ case "$uname" in ;; Linux* | GNU*) # Linux and GNU Hurd @@ -120,7 +120,7 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure MAN8DIR=8 ;; *) -@@ -18305,7 +18308,7 @@ cat >>confdefs.h <<_ACEOF +@@ -18309,7 +18312,7 @@ cat >>confdefs.h <<_ACEOF _ACEOF ;; esac @@ -129,7 +129,7 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure if test $ac_cv_sys_file_offset_bits = unknown; then { echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6; } -@@ -18426,7 +18429,7 @@ cat >>confdefs.h <<_ACEOF +@@ -18430,7 +18433,7 @@ cat >>confdefs.h <<_ACEOF _ACEOF ;; esac @@ -138,7 +138,7 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure fi fi -@@ -20327,6 +20330,412 @@ fi +@@ -20495,6 +20498,412 @@ fi @@ -551,7 +551,7 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure INSTALL_LANGUAGES="" UNINSTALL_LANGUAGES="" LANGFILES="" -@@ -21284,13 +21693,15 @@ PHP!$PHP$ac_delim +@@ -21455,13 +21864,15 @@ PHP!$PHP$ac_delim PHPCONFIG!$PHPCONFIG$ac_delim PHPDIR!$PHPDIR$ac_delim PYTHON!$PYTHON$ac_delim @@ -563,14 +563,14 @@ diff -up cups-1.4b1/configure.lspp cups-1.4b1/configure LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF -- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 23; then -+ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 25; then +- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 25; then ++ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 27; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 -diff -up cups-1.4b1/cups/cups.h.lspp cups-1.4b1/cups/cups.h ---- cups-1.4b1/cups/cups.h.lspp 2008-09-25 00:08:34.000000000 +0100 -+++ cups-1.4b1/cups/cups.h 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/cups/cups.h.lspp cups-1.4b2/cups/cups.h +--- cups-1.4b2/cups/cups.h.lspp 2008-12-10 05:03:11.000000000 +0000 ++++ cups-1.4b2/cups/cups.h 2008-12-16 11:50:59.000000000 +0000 @@ -15,6 +15,9 @@ * This file is subject to the Apple OS-Developed Software exception. */ @@ -581,7 +581,7 @@ diff -up cups-1.4b1/cups/cups.h.lspp cups-1.4b1/cups/cups.h #ifndef _CUPS_CUPS_H_ # define _CUPS_CUPS_H_ -@@ -83,6 +86,12 @@ extern "C" { +@@ -84,6 +87,12 @@ extern "C" { # define CUPS_WHICHJOBS_COMPLETED 1 @@ -594,9 +594,9 @@ diff -up cups-1.4b1/cups/cups.h.lspp cups-1.4b1/cups/cups.h /* * Types and structures... */ -diff -up cups-1.4b1/data/Makefile.lspp cups-1.4b1/data/Makefile ---- cups-1.4b1/data/Makefile.lspp 2008-10-15 19:21:56.000000000 +0100 -+++ cups-1.4b1/data/Makefile 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/data/Makefile.lspp cups-1.4b2/data/Makefile +--- cups-1.4b2/data/Makefile.lspp 2008-11-12 19:30:57.000000000 +0000 ++++ cups-1.4b2/data/Makefile 2008-12-16 11:50:59.000000000 +0000 @@ -25,7 +25,10 @@ BANNERS = \ secret \ standard \ @@ -609,9 +609,9 @@ diff -up cups-1.4b1/data/Makefile.lspp cups-1.4b1/data/Makefile CHARMAPS = \ euc-cn.txt \ -diff -up /dev/null cups-1.4b1/data/mls ---- /dev/null 2008-11-11 08:58:48.466006417 +0000 -+++ cups-1.4b1/data/mls 2008-11-11 16:53:28.000000000 +0000 +diff -up /dev/null cups-1.4b2/data/mls +--- /dev/null 2008-12-16 09:52:24.540063413 +0000 ++++ cups-1.4b2/data/mls 2008-12-16 11:50:59.000000000 +0000 @@ -0,0 +1,261 @@ +%!PS-Adobe-3.0 +%%BoundingBox: 0 0 612 792 @@ -874,9 +874,9 @@ diff -up /dev/null cups-1.4b1/data/mls +% End of "$Id: mls_template,v 1.1 2005/06/27 18:44:46 colmo Exp $". +% +%%EOF -diff -up /dev/null cups-1.4b1/data/selinux ---- /dev/null 2008-11-11 08:58:48.466006417 +0000 -+++ cups-1.4b1/data/selinux 2008-11-11 16:53:28.000000000 +0000 +diff -up /dev/null cups-1.4b2/data/selinux +--- /dev/null 2008-12-16 09:52:24.540063413 +0000 ++++ cups-1.4b2/data/selinux 2008-12-16 11:50:59.000000000 +0000 @@ -0,0 +1,261 @@ +%!PS-Adobe-3.0 +%%BoundingBox: 0 0 612 792 @@ -1139,9 +1139,9 @@ diff -up /dev/null cups-1.4b1/data/selinux +% End of "$Id: mls_template,v 1.1 2005/06/27 18:44:46 colmo Exp $". +% +%%EOF -diff -up /dev/null cups-1.4b1/data/te ---- /dev/null 2008-11-11 08:58:48.466006417 +0000 -+++ cups-1.4b1/data/te 2008-11-11 16:53:28.000000000 +0000 +diff -up /dev/null cups-1.4b2/data/te +--- /dev/null 2008-12-16 09:52:24.540063413 +0000 ++++ cups-1.4b2/data/te 2008-12-16 11:50:59.000000000 +0000 @@ -0,0 +1,261 @@ +%!PS-Adobe-3.0 +%%BoundingBox: 0 0 612 792 @@ -1404,9 +1404,9 @@ diff -up /dev/null cups-1.4b1/data/te +% End of "$Id: mls_template,v 1.1 2005/06/27 18:44:46 colmo Exp $". +% +%%EOF -diff -up cups-1.4b1/filter/common.c.lspp cups-1.4b1/filter/common.c ---- cups-1.4b1/filter/common.c.lspp 2007-07-11 22:46:42.000000000 +0100 -+++ cups-1.4b1/filter/common.c 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/filter/common.c.lspp cups-1.4b2/filter/common.c +--- cups-1.4b2/filter/common.c.lspp 2007-07-11 22:46:42.000000000 +0100 ++++ cups-1.4b2/filter/common.c 2008-12-16 11:50:59.000000000 +0000 @@ -30,6 +30,12 @@ * Include necessary headers... */ @@ -1575,10 +1575,10 @@ diff -up cups-1.4b1/filter/common.c.lspp cups-1.4b1/filter/common.c /* -diff -up cups-1.4b1/filter/pstops.c.lspp cups-1.4b1/filter/pstops.c ---- cups-1.4b1/filter/pstops.c.lspp 2008-09-24 00:44:33.000000000 +0100 -+++ cups-1.4b1/filter/pstops.c 2008-11-11 16:53:28.000000000 +0000 -@@ -3233,6 +3233,18 @@ write_label_prolog(pstops_doc_t *doc, /* +diff -up cups-1.4b2/filter/pstops.c.lspp cups-1.4b2/filter/pstops.c +--- cups-1.4b2/filter/pstops.c.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/filter/pstops.c 2008-12-16 11:50:59.000000000 +0000 +@@ -3232,6 +3232,18 @@ write_label_prolog(pstops_doc_t *doc, /* { const char *classification; /* CLASSIFICATION environment variable */ const char *ptr; /* Temporary string pointer */ @@ -1597,7 +1597,7 @@ diff -up cups-1.4b1/filter/pstops.c.lspp cups-1.4b1/filter/pstops.c /* -@@ -3255,6 +3267,124 @@ write_label_prolog(pstops_doc_t *doc, /* +@@ -3254,6 +3266,124 @@ write_label_prolog(pstops_doc_t *doc, /* return; } @@ -1722,7 +1722,7 @@ diff -up cups-1.4b1/filter/pstops.c.lspp cups-1.4b1/filter/pstops.c /* * Set the classification + page label string... */ -@@ -3333,7 +3463,10 @@ write_label_prolog(pstops_doc_t *doc, /* +@@ -3332,7 +3462,10 @@ write_label_prolog(pstops_doc_t *doc, /* doc_printf(doc, " %.0f moveto ESPpl show\n", top - 14.0); doc_puts(doc, "pop\n"); doc_puts(doc, "}bind put\n"); @@ -1733,10 +1733,10 @@ diff -up cups-1.4b1/filter/pstops.c.lspp cups-1.4b1/filter/pstops.c /* -diff -up cups-1.4b1/Makedefs.in.lspp cups-1.4b1/Makedefs.in ---- cups-1.4b1/Makedefs.in.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/Makedefs.in 2008-11-11 16:53:28.000000000 +0000 -@@ -145,7 +145,7 @@ LIBCUPSORDER = @LIBCUPSORDER@ +diff -up cups-1.4b2/Makedefs.in.lspp cups-1.4b2/Makedefs.in +--- cups-1.4b2/Makedefs.in.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/Makedefs.in 2008-12-16 11:50:59.000000000 +0000 +@@ -146,7 +146,7 @@ LIBCUPSORDER = @LIBCUPSORDER@ LIBCUPSIMAGEORDER = @LIBCUPSIMAGEORDER@ LINKCUPS = @LINKCUPS@ $(SSLLIBS) LINKCUPSIMAGE = @LINKCUPSIMAGE@ @@ -1745,7 +1745,7 @@ diff -up cups-1.4b1/Makedefs.in.lspp cups-1.4b1/Makedefs.in OPTIM = @OPTIM@ OPTIONS = PAMLIBS = @PAMLIBS@ -@@ -256,7 +256,7 @@ DBUSDIR = @DBUSDIR@ +@@ -258,7 +258,7 @@ DBUSDIR = @DBUSDIR@ # Rules... # @@ -1754,9 +1754,9 @@ diff -up cups-1.4b1/Makedefs.in.lspp cups-1.4b1/Makedefs.in .SUFFIXES: .1 .1.gz .1m .1m.gz .3 .3.gz .5 .5.gz .7 .7.gz .8 .8.gz .a .c .cxx .h .man .o .32.o .64.o .gz .c.o: -diff -up cups-1.4b1/scheduler/client.c.lspp cups-1.4b1/scheduler/client.c ---- cups-1.4b1/scheduler/client.c.lspp 2008-10-27 22:47:12.000000000 +0000 -+++ cups-1.4b1/scheduler/client.c 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/client.c.lspp cups-1.4b2/scheduler/client.c +--- cups-1.4b2/scheduler/client.c.lspp 2008-11-17 16:29:05.000000000 +0000 ++++ cups-1.4b2/scheduler/client.c 2008-12-16 11:50:59.000000000 +0000 @@ -41,6 +41,7 @@ * pipe_command() - Pipe the output of a command to the remote client. * write_file() - Send a file via HTTP. @@ -1858,7 +1858,7 @@ diff -up cups-1.4b1/scheduler/client.c.lspp cups-1.4b1/scheduler/client.c status = HTTP_CONTINUE; -@@ -2091,6 +2157,67 @@ cupsdReadClient(cupsd_client_t *con) /* +@@ -2125,6 +2191,67 @@ cupsdReadClient(cupsd_client_t *con) /* fchmod(con->file, 0640); fchown(con->file, RunUser, Group); fcntl(con->file, F_SETFD, fcntl(con->file, F_GETFD) | FD_CLOEXEC); @@ -1926,7 +1926,7 @@ diff -up cups-1.4b1/scheduler/client.c.lspp cups-1.4b1/scheduler/client.c } if (con->http.state != HTTP_POST_SEND) -@@ -4402,6 +4529,50 @@ make_certificate(cupsd_client_t *con) /* +@@ -4436,6 +4563,50 @@ make_certificate(cupsd_client_t *con) /* #endif /* HAVE_SSL */ @@ -1977,9 +1977,9 @@ diff -up cups-1.4b1/scheduler/client.c.lspp cups-1.4b1/scheduler/client.c /* * 'pipe_command()' - Pipe the output of a command to the remote client. */ -diff -up cups-1.4b1/scheduler/client.h.lspp cups-1.4b1/scheduler/client.h ---- cups-1.4b1/scheduler/client.h.lspp 2008-09-11 02:54:11.000000000 +0100 -+++ cups-1.4b1/scheduler/client.h 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/client.h.lspp cups-1.4b2/scheduler/client.h +--- cups-1.4b2/scheduler/client.h.lspp 2008-09-11 02:54:11.000000000 +0100 ++++ cups-1.4b2/scheduler/client.h 2008-12-16 11:50:59.000000000 +0000 @@ -18,6 +18,13 @@ #endif /* HAVE_AUTHORIZATION_H */ @@ -2015,9 +2015,9 @@ diff -up cups-1.4b1/scheduler/client.h.lspp cups-1.4b1/scheduler/client.h /* -diff -up cups-1.4b1/scheduler/conf.c.lspp cups-1.4b1/scheduler/conf.c ---- cups-1.4b1/scheduler/conf.c.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/scheduler/conf.c 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/conf.c.lspp cups-1.4b2/scheduler/conf.c +--- cups-1.4b2/scheduler/conf.c.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/scheduler/conf.c 2008-12-16 11:50:59.000000000 +0000 @@ -27,6 +27,7 @@ * read_configuration() - Read a configuration file. * read_location() - Read a definition. @@ -2127,9 +2127,9 @@ diff -up cups-1.4b1/scheduler/conf.c.lspp cups-1.4b1/scheduler/conf.c /* * 'read_policy()' - Read a definition. -diff -up cups-1.4b1/scheduler/conf.h.lspp cups-1.4b1/scheduler/conf.h ---- cups-1.4b1/scheduler/conf.h.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/scheduler/conf.h 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/conf.h.lspp cups-1.4b2/scheduler/conf.h +--- cups-1.4b2/scheduler/conf.h.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/scheduler/conf.h 2008-12-16 11:50:59.000000000 +0000 @@ -233,6 +233,12 @@ VAR char *ServerKey VALUE(NULL); VAR int SSLOptions VALUE(CUPSD_SSL_NONE); /* SSL/TLS options */ @@ -2153,9 +2153,9 @@ diff -up cups-1.4b1/scheduler/conf.h.lspp cups-1.4b1/scheduler/conf.h /* * Prototypes... -diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c ---- cups-1.4b1/scheduler/ipp.c.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/scheduler/ipp.c 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/ipp.c.lspp cups-1.4b2/scheduler/ipp.c +--- cups-1.4b2/scheduler/ipp.c.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/scheduler/ipp.c 2008-12-16 11:50:59.000000000 +0000 @@ -41,6 +41,7 @@ * cancel_all_jobs() - Cancel all print jobs. * cancel_job() - Cancel a print job. @@ -2360,8 +2360,8 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c CUPS_PRINTER_REMOTE); job->attrs = con->request; @@ -1743,6 +1897,29 @@ add_job(cupsd_client_t *con, /* I - Cl - attr->values[0].string.text = _cupsStrAlloc(printer->job_sheets[0]); - attr->values[1].string.text = _cupsStrAlloc(printer->job_sheets[1]); + attr->values[0].string.text = _cupsStrRetain(printer->job_sheets[0]); + attr->values[1].string.text = _cupsStrRetain(printer->job_sheets[1]); } +#ifdef WITH_LSPP + else @@ -2472,7 +2472,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c /* * See if we need to add the starting sheet... -@@ -4186,6 +4416,103 @@ check_rss_recipient( +@@ -4187,6 +4417,103 @@ check_rss_recipient( } @@ -2576,7 +2576,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c /* * 'check_quotas()' - Check quotas for a printer and user. */ -@@ -4714,6 +5041,15 @@ copy_banner(cupsd_client_t *con, /* I - +@@ -4736,6 +5063,15 @@ copy_banner(cupsd_client_t *con, /* I - char attrname[255], /* Name of attribute */ *s; /* Pointer into name */ ipp_attribute_t *attr; /* Attribute */ @@ -2592,7 +2592,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c cupsdLogMessage(CUPSD_LOG_DEBUG2, -@@ -4749,6 +5085,82 @@ copy_banner(cupsd_client_t *con, /* I - +@@ -4771,6 +5107,82 @@ copy_banner(cupsd_client_t *con, /* I - fchmod(cupsFileNumber(out), 0640); fchown(cupsFileNumber(out), RunUser, Group); @@ -2675,7 +2675,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c /* * Try the localized banner file under the subdirectory... -@@ -4843,6 +5255,24 @@ copy_banner(cupsd_client_t *con, /* I - +@@ -4865,6 +5277,24 @@ copy_banner(cupsd_client_t *con, /* I - else s = attrname; @@ -2700,7 +2700,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c if (!strcmp(s, "printer-name")) { cupsFilePuts(out, job->dest); -@@ -6745,6 +7175,22 @@ get_job_attrs(cupsd_client_t *con, /* I +@@ -6782,6 +7212,22 @@ get_job_attrs(cupsd_client_t *con, /* I return; } @@ -2723,7 +2723,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c /* * Copy attributes... */ -@@ -6955,6 +7401,11 @@ get_jobs(cupsd_client_t *con, /* I - C +@@ -6997,6 +7443,11 @@ get_jobs(cupsd_client_t *con, /* I - C if (count > 0) ippAddSeparator(con->response); @@ -2735,7 +2735,7 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c count ++; cupsdLogMessage(CUPSD_LOG_DEBUG2, "get_jobs: count = %d", count); -@@ -11250,6 +11701,11 @@ validate_user(cupsd_job_t *job, /* I +@@ -11314,6 +11765,11 @@ validate_user(cupsd_job_t *job, /* I strlcpy(username, get_username(con), userlen); @@ -2747,10 +2747,10 @@ diff -up cups-1.4b1/scheduler/ipp.c.lspp cups-1.4b1/scheduler/ipp.c /* * Check the username against the owner... */ -diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c ---- cups-1.4b1/scheduler/job.c.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/scheduler/job.c 2008-11-11 16:53:28.000000000 +0000 -@@ -60,6 +60,9 @@ +diff -up cups-1.4b2/scheduler/job.c.lspp cups-1.4b2/scheduler/job.c +--- cups-1.4b2/scheduler/job.c.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/scheduler/job.c 2008-12-16 11:50:59.000000000 +0000 +@@ -62,6 +62,9 @@ * update_job_attrs() - Update the job-printer-* attributes. */ @@ -2760,7 +2760,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c /* * Include necessary headers... */ -@@ -69,6 +72,14 @@ +@@ -71,6 +74,14 @@ #include #include @@ -2775,7 +2775,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c /* * Local globals... -@@ -1151,6 +1162,23 @@ cupsdLoadJob(cupsd_job_t *job) /* I - J +@@ -1176,6 +1187,23 @@ cupsdLoadJob(cupsd_job_t *job) /* I - J return; } @@ -2799,7 +2799,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c job->sheets = ippFindAttribute(job->attrs, "job-media-sheets-completed", IPP_TAG_INTEGER); job->job_sheets = ippFindAttribute(job->attrs, "job-sheets", IPP_TAG_NAME); -@@ -1508,6 +1536,13 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J +@@ -1537,6 +1565,13 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J { char filename[1024]; /* Job control filename */ cups_file_t *fp; /* Job file */ @@ -2813,7 +2813,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdSaveJob(job=%p(%d)): job->attrs=%p", -@@ -1526,6 +1561,76 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J +@@ -1555,6 +1590,76 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J fchmod(cupsFileNumber(fp), 0600); fchown(cupsFileNumber(fp), RunUser, Group); @@ -2890,7 +2890,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c job->attrs->state = IPP_IDLE; if (ippWriteIO(fp, (ipp_iocb_t)cupsFileWrite, 1, NULL, -@@ -2511,6 +2616,21 @@ start_job(cupsd_job_t *job, /* I - +@@ -2545,6 +2650,21 @@ start_job(cupsd_job_t *job, /* I - /* RIP_MAX_CACHE env variable */ static char *options = NULL;/* Full list of options */ static int optlength = 0; /* Length of option buffer */ @@ -2912,7 +2912,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c cupsdLogJob(job, CUPSD_LOG_DEBUG2, "start_job: file = %d/%d", -@@ -2783,6 +2903,106 @@ start_job(cupsd_job_t *job, /* I - +@@ -2817,6 +2937,106 @@ start_job(cupsd_job_t *job, /* I - fcntl(job->side_pipes[1], F_GETFL) | O_NONBLOCK); } @@ -3019,7 +3019,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c /* * Determine if we are printing a banner page or not... */ -@@ -2920,6 +3140,18 @@ start_job(cupsd_job_t *job, /* I - +@@ -2954,6 +3174,18 @@ start_job(cupsd_job_t *job, /* I - banner_page) continue; @@ -3038,7 +3038,7 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c /* * Otherwise add them to the list... */ -@@ -3169,6 +3401,67 @@ start_job(cupsd_job_t *job, /* I - +@@ -3203,6 +3435,67 @@ start_job(cupsd_job_t *job, /* I - } } @@ -3106,9 +3106,9 @@ diff -up cups-1.4b1/scheduler/job.c.lspp cups-1.4b1/scheduler/job.c if (Classification && !banner_page) { if ((attr = ippFindAttribute(job->attrs, "job-sheets", -diff -up cups-1.4b1/scheduler/job.h.lspp cups-1.4b1/scheduler/job.h ---- cups-1.4b1/scheduler/job.h.lspp 2008-08-28 21:38:13.000000000 +0100 -+++ cups-1.4b1/scheduler/job.h 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/job.h.lspp cups-1.4b2/scheduler/job.h +--- cups-1.4b2/scheduler/job.h.lspp 2008-08-28 21:38:13.000000000 +0100 ++++ cups-1.4b2/scheduler/job.h 2008-12-16 11:50:59.000000000 +0000 @@ -13,6 +13,13 @@ * file is missing or damaged, see the license at "http://www.cups.org/". */ @@ -3134,9 +3134,9 @@ diff -up cups-1.4b1/scheduler/job.h.lspp cups-1.4b1/scheduler/job.h } cupsd_job_t; -diff -up cups-1.4b1/scheduler/main.c.lspp cups-1.4b1/scheduler/main.c ---- cups-1.4b1/scheduler/main.c.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/scheduler/main.c 2008-11-11 16:53:28.000000000 +0000 +diff -up cups-1.4b2/scheduler/main.c.lspp cups-1.4b2/scheduler/main.c +--- cups-1.4b2/scheduler/main.c.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/scheduler/main.c 2008-12-16 11:50:59.000000000 +0000 @@ -35,6 +35,8 @@ * usage() - Show scheduler usage. */ @@ -3192,7 +3192,7 @@ diff -up cups-1.4b1/scheduler/main.c.lspp cups-1.4b1/scheduler/main.c /* * Set the timezone info... */ -@@ -1200,6 +1227,11 @@ main(int argc, /* I - Number of comm +@@ -1212,6 +1239,11 @@ main(int argc, /* I - Number of comm cupsdStopSelect(); @@ -3204,9 +3204,9 @@ diff -up cups-1.4b1/scheduler/main.c.lspp cups-1.4b1/scheduler/main.c return (!stop_scheduler); } -diff -up cups-1.4b1/scheduler/printers.c.lspp cups-1.4b1/scheduler/printers.c ---- cups-1.4b1/scheduler/printers.c.lspp 2008-11-11 16:53:28.000000000 +0000 -+++ cups-1.4b1/scheduler/printers.c 2008-11-11 17:00:31.000000000 +0000 +diff -up cups-1.4b2/scheduler/printers.c.lspp cups-1.4b2/scheduler/printers.c +--- cups-1.4b2/scheduler/printers.c.lspp 2008-12-16 11:50:59.000000000 +0000 ++++ cups-1.4b2/scheduler/printers.c 2008-12-16 11:50:59.000000000 +0000 @@ -52,6 +52,8 @@ * write_xml_string() - Write a string with XML escaping. */ @@ -3227,7 +3227,7 @@ diff -up cups-1.4b1/scheduler/printers.c.lspp cups-1.4b1/scheduler/printers.c /* * 'cupsdAddPrinter()' - Add a printer to the system. -@@ -2081,6 +2087,13 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p) +@@ -2115,6 +2121,13 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p) { /* No authentication */ "none" }; @@ -3241,7 +3241,7 @@ diff -up cups-1.4b1/scheduler/printers.c.lspp cups-1.4b1/scheduler/printers.c DEBUG_printf(("cupsdSetPrinterAttrs: entering name = %s, type = %x\n", p->name, -@@ -2226,6 +2239,42 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p) +@@ -2260,6 +2273,42 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p) attr->values[1].string.text = _cupsStrAlloc(Classification ? Classification : p->job_sheets[1]); } @@ -3284,7 +3284,7 @@ diff -up cups-1.4b1/scheduler/printers.c.lspp cups-1.4b1/scheduler/printers.c } p->raw = 0; -@@ -4606,7 +4655,6 @@ write_irix_state(cupsd_printer_t *p) /* +@@ -4650,7 +4699,6 @@ write_irix_state(cupsd_printer_t *p) /* } #endif /* __sgi */ diff --git a/cups.spec b/cups.spec index 8c34eee..00b67a8 100644 --- a/cups.spec +++ b/cups.spec @@ -1,4 +1,4 @@ -%define pre b1 +%define pre b2 %define initdir /etc/rc.d/init.d %define use_alternatives 1 %define lspp 1 @@ -7,7 +7,7 @@ Summary: Common Unix Printing System Name: cups Version: 1.4 -Release: 0.%{pre}.6%{?dist} +Release: 0.%{pre}.1%{?dist} License: GPLv2 Group: System Environment/Daemons Source: ftp://ftp.easysw.com/pub/cups/test//cups-%{version}%{?pre}-source.tar.bz2 @@ -28,7 +28,6 @@ Patch1: cups-no-gzip-man.patch Patch2: cups-1.1.16-system-auth.patch Patch3: cups-multilib.patch Patch4: cups-str2831.patch -Patch5: cups-CVE-2008-5183.patch Patch6: cups-banners.patch Patch7: cups-serverbin-compat.patch Patch8: cups-no-export-ssllibs.patch @@ -169,7 +168,6 @@ module. %patch2 -p1 -b .system-auth %patch3 -p1 -b .multilib %patch4 -p1 -b .str2831 -%patch5 -p1 -b .CVE-2008-5183 %patch6 -p1 -b .banners %patch7 -p1 -b .serverbin-compat %patch8 -p1 -b .no-export-ssllibs @@ -410,6 +408,8 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/cups/model %dir %{_datadir}/cups/templates %config(noreplace) %{_datadir}/cups/templates/*.tmpl +%config(noreplace) %{_datadir}/cups/templates/es/*.tmpl +%{_datadir}/locale/* %{_datadir}/ppd %dir %attr(1770,root,lp) /var/spool/cups/tmp %dir %attr(0710,root,lp) /var/spool/cups @@ -450,6 +450,10 @@ rm -rf $RPM_BUILD_ROOT %{_libdir}/php/modules/*.so %changelog +* Tue Dec 16 2008 Tim Waugh 1:1.4-0.b2.1 +- 1.4b2. +- No longer need CVE-2008-5183 patch. + * Sat Dec 13 2008 Tim Waugh 1:1.4-0.b1.6 - Start cupsd at priority 25: after avahi-daemon but before haldaemon (bug #468709). diff --git a/sources b/sources index 78e62e2..970f7f1 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ b0bb017098e8e76b8a25e666c41ce540 postscript.ppd.gz -ddb969a6c5db86f3524ec265cb06ed35 cups-1.4b1-source.tar.bz2 +23f540e6145e4ab3298700d9f496bcd1 cups-1.4b2-source.tar.bz2