Rebase cups to upstream version 2.4.9

Resolves: RHEL-39938
Resolves: RHEL-25804
This commit is contained in:
Pavol Žáčik 2024-06-12 12:59:36 +02:00
parent 2891bd42a6
commit 363dd52521
No known key found for this signature in database
GPG Key ID: 5B5640AB63D575DE
10 changed files with 123 additions and 401 deletions

1
.gitignore vendored
View File

@ -102,3 +102,4 @@ cups-1.4.4-source.tar.bz2
/cups-2.4.5-source.tar.gz
/cups-2.4.6-source.tar.gz
/cups-2.4.7-source.tar.gz
/cups-2.4.9-source.tar.gz

View File

@ -1,48 +0,0 @@
From c5ad7aaf6c8063a39974c6b4a3cf59b7f912daae Mon Sep 17 00:00:00 2001
From: Bryan Mason <bmason@redhat.com>
Date: Tue, 27 Jun 2023 04:18:46 -0700
Subject: [PATCH 1/2] Use "purge-job" instead of "purge-jobs" when canceling a
single job (#742)
The command "cancel -x <job>" adds "purge-jobs true" to the Cancel-Job
operation; however, the correct attribute to use for Cancel-job is
"purge-job" (singular), not "purge-jobs" (plural). As a result, job
files are not removed from /var/spool/cups when "cancel -x <job>" is
executed.
This patch resolves the issue by adding "purge-job" when the IPP
operation is Cancel-Job and "purge-jobs" for other IPP operations
(Purge-Jobs, Cancel-Jobs, and Cancel-My-Jobs)
---
systemv/cancel.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/systemv/cancel.c b/systemv/cancel.c
index 572f413e1..f5b8e12b5 100644
--- a/systemv/cancel.c
+++ b/systemv/cancel.c
@@ -260,6 +260,7 @@ main(int argc, /* I - Number of command-line arguments */
* attributes-natural-language
* printer-uri + job-id *or* job-uri
* [requesting-user-name]
+ * [purge-job] or [purge-jobs]
*/
request = ippNewRequest(op);
@@ -294,7 +295,12 @@ main(int argc, /* I - Number of command-line arguments */
"requesting-user-name", NULL, cupsUser());
if (purge)
- ippAddBoolean(request, IPP_TAG_OPERATION, "purge-jobs", (char)purge);
+ {
+ if (op == IPP_CANCEL_JOB)
+ ippAddBoolean(request, IPP_TAG_OPERATION, "purge-job", (char)purge);
+ else
+ ippAddBoolean(request, IPP_TAG_OPERATION, "purge-jobs", (char)purge);
+ }
/*
* Do the request and get back a response...
--
2.41.0

View File

@ -1,76 +0,0 @@
From e0c31f4794ef637b74b0a0074364ff407ca40d5a Mon Sep 17 00:00:00 2001
From: Zdenek Dohnal <zdohnal@redhat.com>
Date: Fri, 15 Dec 2023 10:59:54 +0100
Subject: [PATCH] httpAddrConnect2: Check for error if POLLHUP is in valid
revents
Some Linux kernel versions put POLLOUT|POLLHUP into revents when client tries to connect with httpAddrConnect2(), which makes the connection fail.
Let's check the option SO_ERROR before scratching the attempt - if there is no error, remove POLLHUP from revents.
I've re-purposed previously Solaris-only code to be used everywhere if the conditions are met - this should prevent bigger delays than necessary.
Slightly different issue than #827, but with similar symptoms (kernel sending POLLOUT|POLLHUP).
---
CHANGES.md | 2 ++
cups/http-addrlist.c | 43 ++++++++++++++++++++++++++++++-------------
2 files changed, 32 insertions(+), 13 deletions(-)
diff --git a/cups/http-addrlist.c b/cups/http-addrlist.c
index 198d073d0..cffcf184c 100644
--- a/cups/http-addrlist.c
+++ b/cups/http-addrlist.c
@@ -318,21 +318,38 @@ httpAddrConnect2(
{
# ifdef HAVE_POLL
DEBUG_printf(("pfds[%d].revents=%x\n", i, pfds[i].revents));
-# ifdef __sun
- // Solaris connect runs asynchronously returning EINPROGRESS. Following
- // poll() does not detect the socket is not connected and returns
- // POLLIN|POLLOUT. Check the connection status and update error flag.
- int sres, serr;
- socklen_t slen = sizeof(serr);
- sres = getsockopt(fds[i], SOL_SOCKET, SO_ERROR, &serr, &slen);
- if (sres || serr)
+
+# ifdef _WIN32
+ if (((WSAGetLastError() == WSAEINPROGRESS) && (pfds[i].revents & POLLIN) && (pfds[i].revents & POLLOUT)) ||
+ ((pfds[i].revents & POLLHUP) && (pfds[i].revents & (POLLIN|POLLOUT))))
+# else
+ if (((errno == EINPROGRESS) && (pfds[i].revents & POLLIN) && (pfds[i].revents & POLLOUT)) ||
+ ((pfds[i].revents & POLLHUP) && (pfds[i].revents & (POLLIN|POLLOUT))))
+# endif /* _WIN32 */
{
- pfds[i].revents |= POLLERR;
-# ifdef DEBUG
- DEBUG_printf(("1httpAddrConnect2: getsockopt returned: %d with error: %s", sres, strerror(serr)));
-# endif
+ // Some systems generate POLLIN or POLLOUT together with POLLHUP when doing
+ // asynchronous connections. The solution seems to be to use getsockopt to
+ // check the SO_ERROR value and ignore the POLLHUP if there is no error or
+ // the error is EINPROGRESS.
+
+ int sres, /* Return value from getsockopt() - 0, or -1 if error */
+ serr; /* Option SO_ERROR value */
+ socklen_t slen = sizeof(serr); /* Option value size */
+
+ sres = getsockopt(fds[i], SOL_SOCKET, SO_ERROR, &serr, &slen);
+
+ if (sres || serr)
+ {
+ pfds[i].revents |= POLLERR;
+# ifdef DEBUG
+ DEBUG_printf(("1httpAddrConnect2: getsockopt returned: %d with error: %s", sres, strerror(serr)));
+# endif
+ }
+ else if (pfds[i].revents && (pfds[i].revents & POLLHUP) && (pfds[i].revents & (POLLIN | POLLOUT)))
+ {
+ pfds[i].revents &= ~POLLHUP;
+ }
}
-# endif // __sun
if (pfds[i].revents && !(pfds[i].revents & (POLLERR | POLLHUP)))
--
2.43.0

View File

@ -1,64 +0,0 @@
From d60341b3355fd8825bec00792f301ef99d715a93 Mon Sep 17 00:00:00 2001
From: Zdenek Dohnal <zdohnal@redhat.com>
Date: Wed, 3 Apr 2024 10:39:24 +0200
Subject: [PATCH] scheduler: Fix sending response headers to client
Sometimes headers are not correctly copied into response to the client
(some are missing). It happens because `sent_header` is set prematurely
before the actual send happens. The present code in affected `cupsdWriteClient`
scope looks like code remains from CUPS 1.6.3.
With the change, testing via curl gives reliable results all time.
---
scheduler/client.c | 15 ++++-----------
1 file changed, 4 insertions(+), 11 deletions(-)
diff --git a/scheduler/client.c b/scheduler/client.c
index 62ac21c69..e7e312b8e 100644
--- a/scheduler/client.c
+++ b/scheduler/client.c
@@ -2400,23 +2400,12 @@ cupsdWriteClient(cupsd_client_t *con) /* I - Client connection */
httpSetField(con->http, field, value);
if (field == HTTP_FIELD_LOCATION)
- {
con->pipe_status = HTTP_STATUS_SEE_OTHER;
- con->sent_header = 2;
- }
- else
- con->sent_header = 1;
}
else if (!_cups_strcasecmp(con->header, "Status") && value)
- {
con->pipe_status = (http_status_t)atoi(value);
- con->sent_header = 2;
- }
else if (!_cups_strcasecmp(con->header, "Set-Cookie") && value)
- {
httpSetCookie(con->http, value);
- con->sent_header = 1;
- }
}
/*
@@ -2451,6 +2440,8 @@ cupsdWriteClient(cupsd_client_t *con) /* I - Client connection */
cupsdCloseClient(con);
return;
}
+
+ con->sent_header = 1;
}
else
{
@@ -2459,6 +2450,8 @@ cupsdWriteClient(cupsd_client_t *con) /* I - Client connection */
cupsdCloseClient(con);
return;
}
+
+ con->sent_header = 1;
}
}
else
--
2.44.0

View File

@ -1,13 +0,0 @@
diff --git a/scheduler/colorman.c b/scheduler/colorman.c
index 809ed7c..9071271 100644
--- a/scheduler/colorman.c
+++ b/scheduler/colorman.c
@@ -1080,7 +1080,7 @@ colord_create_profile(
dbus_message_iter_get_basic(&args, &profile_path);
cupsdLogMessage(CUPSD_LOG_DEBUG, "Created profile \"%s\".", profile_path);
- cupsArrayAdd(profiles, strdup(profile_path));
+ cupsArrayAdd(profiles, profile_path);
out:

View File

@ -1,7 +1,7 @@
diff -up cups-2.4.1/config.h.in.lspp cups-2.4.1/config.h.in
--- cups-2.4.1/config.h.in.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/config.h.in 2022-02-07 08:14:29.583878197 +0100
@@ -684,6 +684,13 @@ static __inline int _cups_abs(int i) { r
diff -up cups-2.4.8/config.h.in.lspp cups-2.4.8/config.h.in
--- cups-2.4.8/config.h.in.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/config.h.in 2024-05-14 13:15:22.457678901 +0200
@@ -685,6 +685,13 @@ static __inline int _cups_abs(int i) { r
/*
@ -15,9 +15,9 @@ diff -up cups-2.4.1/config.h.in.lspp cups-2.4.1/config.h.in
* Building as a snap (snapcraft.io)?
*/
diff -up cups-2.4.1/config-scripts/cups-lspp.m4.lspp cups-2.4.1/config-scripts/cups-lspp.m4
--- cups-2.4.1/config-scripts/cups-lspp.m4.lspp 2022-02-07 08:14:29.583878197 +0100
+++ cups-2.4.1/config-scripts/cups-lspp.m4 2022-02-07 08:14:29.583878197 +0100
diff -up cups-2.4.8/config-scripts/cups-lspp.m4.lspp cups-2.4.8/config-scripts/cups-lspp.m4
--- cups-2.4.8/config-scripts/cups-lspp.m4.lspp 2024-05-14 13:15:22.457678901 +0200
+++ cups-2.4.8/config-scripts/cups-lspp.m4 2024-05-14 13:15:22.457678901 +0200
@@ -0,0 +1,36 @@
+dnl
+dnl LSPP code for the Common UNIX Printing System (CUPS).
@ -55,9 +55,9 @@ diff -up cups-2.4.1/config-scripts/cups-lspp.m4.lspp cups-2.4.1/config-scripts/c
+ ;;
+ esac
+fi
diff -up cups-2.4.1/configure.ac.lspp cups-2.4.1/configure.ac
--- cups-2.4.1/configure.ac.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/configure.ac 2022-02-07 08:14:29.583878197 +0100
diff -up cups-2.4.8/configure.ac.lspp cups-2.4.8/configure.ac
--- cups-2.4.8/configure.ac.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/configure.ac 2024-05-14 13:15:22.457678901 +0200
@@ -40,6 +40,8 @@ sinclude(config-scripts/cups-container.m
sinclude(config-scripts/cups-startup.m4)
sinclude(config-scripts/cups-defaults.m4)
@ -67,10 +67,10 @@ diff -up cups-2.4.1/configure.ac.lspp cups-2.4.1/configure.ac
dnl See what languages are available and make sure we generate the localization
dnl files as needed...
INSTALL_LANGUAGES=""
diff -up cups-2.4.1/filter/common.c.lspp cups-2.4.1/filter/common.c
--- cups-2.4.1/filter/common.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/filter/common.c 2022-02-07 08:14:29.584878189 +0100
@@ -11,6 +11,12 @@
diff -up cups-2.4.8/filter/common.c.lspp cups-2.4.8/filter/common.c
--- cups-2.4.8/filter/common.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/filter/common.c 2024-05-14 13:15:22.457678901 +0200
@@ -12,6 +12,12 @@
* Include necessary headers...
*/
@ -83,7 +83,7 @@ diff -up cups-2.4.1/filter/common.c.lspp cups-2.4.1/filter/common.c
#include "common.h"
#include <locale.h>
@@ -293,6 +299,18 @@ WriteLabelProlog(const char *label, /* I
@@ -294,6 +300,18 @@ WriteLabelProlog(const char *label, /* I
{
const char *classification; /* CLASSIFICATION environment variable */
const char *ptr; /* Temporary string pointer */
@ -102,7 +102,7 @@ diff -up cups-2.4.1/filter/common.c.lspp cups-2.4.1/filter/common.c
/*
@@ -315,6 +333,124 @@ WriteLabelProlog(const char *label, /* I
@@ -316,6 +334,124 @@ WriteLabelProlog(const char *label, /* I
return;
}
@ -227,7 +227,7 @@ diff -up cups-2.4.1/filter/common.c.lspp cups-2.4.1/filter/common.c
/*
* Set the classification + page label string...
*/
@@ -395,7 +531,10 @@ WriteLabelProlog(const char *label, /* I
@@ -396,7 +532,10 @@ WriteLabelProlog(const char *label, /* I
printf(" %.0f moveto ESPpl show\n", top - 14.0);
puts("pop");
puts("}bind put");
@ -238,10 +238,10 @@ diff -up cups-2.4.1/filter/common.c.lspp cups-2.4.1/filter/common.c
/*
diff -up cups-2.4.1/filter/pstops.c.lspp cups-2.4.1/filter/pstops.c
--- cups-2.4.1/filter/pstops.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/filter/pstops.c 2022-02-07 08:14:29.584878189 +0100
@@ -3170,6 +3170,18 @@ write_label_prolog(pstops_doc_t *doc, /*
diff -up cups-2.4.8/filter/pstops.c.lspp cups-2.4.8/filter/pstops.c
--- cups-2.4.8/filter/pstops.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/filter/pstops.c 2024-05-14 13:15:22.458678907 +0200
@@ -3171,6 +3171,18 @@ write_label_prolog(pstops_doc_t *doc, /*
{
const char *classification; /* CLASSIFICATION environment variable */
const char *ptr; /* Temporary string pointer */
@ -260,7 +260,7 @@ diff -up cups-2.4.1/filter/pstops.c.lspp cups-2.4.1/filter/pstops.c
/*
@@ -3192,6 +3204,124 @@ write_label_prolog(pstops_doc_t *doc, /*
@@ -3193,6 +3205,124 @@ write_label_prolog(pstops_doc_t *doc, /*
return;
}
@ -385,7 +385,7 @@ diff -up cups-2.4.1/filter/pstops.c.lspp cups-2.4.1/filter/pstops.c
/*
* Set the classification + page label string...
*/
@@ -3270,7 +3400,10 @@ write_label_prolog(pstops_doc_t *doc, /*
@@ -3271,7 +3401,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");
@ -396,9 +396,9 @@ diff -up cups-2.4.1/filter/pstops.c.lspp cups-2.4.1/filter/pstops.c
/*
diff -up cups-2.4.1/scheduler/client.c.lspp cups-2.4.1/scheduler/client.c
--- cups-2.4.1/scheduler/client.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/client.c 2022-02-07 08:14:29.585878181 +0100
diff -up cups-2.4.8/scheduler/client.c.lspp cups-2.4.8/scheduler/client.c
--- cups-2.4.8/scheduler/client.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/client.c 2024-05-14 13:15:22.458678907 +0200
@@ -20,12 +20,20 @@
#define _HTTP_NO_PRIVATE
#include "cupsd.h"
@ -420,7 +420,7 @@ diff -up cups-2.4.1/scheduler/client.c.lspp cups-2.4.1/scheduler/client.c
/*
@@ -266,6 +274,59 @@ cupsdAcceptClient(cupsd_listener_t *lis)
@@ -264,6 +272,59 @@ cupsdAcceptClient(cupsd_listener_t *lis)
}
#endif /* HAVE_TCPD_H */
@ -480,7 +480,7 @@ diff -up cups-2.4.1/scheduler/client.c.lspp cups-2.4.1/scheduler/client.c
#ifdef AF_LOCAL
if (httpAddrFamily(httpGetAddress(con->http)) == AF_LOCAL)
{
@@ -559,6 +620,13 @@ cupsdReadClient(cupsd_client_t *con) /*
@@ -565,6 +626,13 @@ cupsdReadClient(cupsd_client_t *con) /*
struct stat filestats; /* File information */
mime_type_t *type; /* MIME type of file */
static unsigned request_id = 0; /* Request ID for temp files */
@ -494,7 +494,7 @@ diff -up cups-2.4.1/scheduler/client.c.lspp cups-2.4.1/scheduler/client.c
status = HTTP_STATUS_CONTINUE;
@@ -1680,6 +1748,73 @@ cupsdReadClient(cupsd_client_t *con) /*
@@ -1712,6 +1780,73 @@ cupsdReadClient(cupsd_client_t *con) /*
fcntl(con->file, F_SETFD, fcntl(con->file, F_GETFD) | FD_CLOEXEC);
}
@ -568,7 +568,7 @@ diff -up cups-2.4.1/scheduler/client.c.lspp cups-2.4.1/scheduler/client.c
if (httpGetState(con->http) != HTTP_STATE_POST_SEND)
{
if (!httpWait(con->http, 0))
@@ -3183,6 +3318,49 @@ is_path_absolute(const char *path) /* I
@@ -3208,6 +3343,49 @@ is_path_absolute(const char *path) /* I
return (1);
}
@ -618,9 +618,9 @@ diff -up cups-2.4.1/scheduler/client.c.lspp cups-2.4.1/scheduler/client.c
/*
* 'pipe_command()' - Pipe the output of a command to the remote client.
diff -up cups-2.4.1/scheduler/client.h.lspp cups-2.4.1/scheduler/client.h
--- cups-2.4.1/scheduler/client.h.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/client.h 2022-02-07 08:14:29.585878181 +0100
diff -up cups-2.4.8/scheduler/client.h.lspp cups-2.4.8/scheduler/client.h
--- cups-2.4.8/scheduler/client.h.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/client.h 2024-05-14 13:15:22.458678907 +0200
@@ -14,6 +14,13 @@
#endif /* HAVE_AUTHORIZATION_H */
@ -635,7 +635,7 @@ diff -up cups-2.4.1/scheduler/client.h.lspp cups-2.4.1/scheduler/client.h
/*
* HTTP client structure...
*/
@@ -64,6 +71,10 @@ struct cupsd_client_s
@@ -66,6 +73,10 @@ struct cupsd_client_s
#ifdef HAVE_AUTHORIZATION_H
AuthorizationRef authref; /* Authorization ref */
#endif /* HAVE_AUTHORIZATION_H */
@ -646,7 +646,7 @@ diff -up cups-2.4.1/scheduler/client.h.lspp cups-2.4.1/scheduler/client.h
};
#define HTTP(con) ((con)->http)
@@ -136,6 +147,10 @@ extern void cupsdStopListening(void);
@@ -138,6 +149,10 @@ extern void cupsdStopListening(void);
extern void cupsdUpdateCGI(void);
extern void cupsdWriteClient(cupsd_client_t *con);
@ -657,9 +657,9 @@ diff -up cups-2.4.1/scheduler/client.h.lspp cups-2.4.1/scheduler/client.h
#ifdef HAVE_TLS
extern int cupsdEndTLS(cupsd_client_t *con);
extern int cupsdStartTLS(cupsd_client_t *con);
diff -up cups-2.4.1/scheduler/conf.c.lspp cups-2.4.1/scheduler/conf.c
--- cups-2.4.1/scheduler/conf.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/conf.c 2022-02-07 08:14:29.585878181 +0100
diff -up cups-2.4.8/scheduler/conf.c.lspp cups-2.4.8/scheduler/conf.c
--- cups-2.4.8/scheduler/conf.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/conf.c 2024-05-14 13:15:22.459678912 +0200
@@ -38,6 +38,9 @@
# define INADDR_NONE 0xffffffff
#endif /* !INADDR_NONE */
@ -691,7 +691,7 @@ diff -up cups-2.4.1/scheduler/conf.c.lspp cups-2.4.1/scheduler/conf.c
/*
@@ -858,6 +868,25 @@ cupsdReadConfiguration(void)
@@ -854,6 +864,25 @@ cupsdReadConfiguration(void)
RunUser = getuid();
@ -717,7 +717,7 @@ diff -up cups-2.4.1/scheduler/conf.c.lspp cups-2.4.1/scheduler/conf.c
cupsdLogMessage(CUPSD_LOG_INFO, "Remote access is %s.",
RemotePort ? "enabled" : "disabled");
@@ -1286,7 +1315,19 @@ cupsdReadConfiguration(void)
@@ -1282,7 +1311,19 @@ cupsdReadConfiguration(void)
cupsdClearString(&Classification);
if (Classification)
@ -737,7 +737,7 @@ diff -up cups-2.4.1/scheduler/conf.c.lspp cups-2.4.1/scheduler/conf.c
/*
* Check the MaxClients setting, and then allocate memory for it...
@@ -3874,6 +3915,18 @@ read_location(cups_file_t *fp, /* I - C
@@ -3881,6 +3922,18 @@ read_location(cups_file_t *fp, /* I - C
return ((FatalErrors & CUPSD_FATAL_CONFIG) ? 0 : linenum);
}
@ -756,9 +756,9 @@ diff -up cups-2.4.1/scheduler/conf.c.lspp cups-2.4.1/scheduler/conf.c
/*
* 'read_policy()' - Read a <Policy name> definition.
diff -up cups-2.4.1/scheduler/conf.h.lspp cups-2.4.1/scheduler/conf.h
--- cups-2.4.1/scheduler/conf.h.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/conf.h 2022-02-07 08:14:29.586878172 +0100
diff -up cups-2.4.8/scheduler/conf.h.lspp cups-2.4.8/scheduler/conf.h
--- cups-2.4.8/scheduler/conf.h.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/conf.h 2024-05-14 13:15:22.459678912 +0200
@@ -242,6 +242,13 @@ VAR char *ServerKeychain VALUE(NULL);
/* Keychain holding cert + key */
#endif /* HAVE_TLS */
@ -783,10 +783,10 @@ diff -up cups-2.4.1/scheduler/conf.h.lspp cups-2.4.1/scheduler/conf.h
/*
* Prototypes...
diff -up cups-2.4.1/scheduler/cupsd.h.lspp cups-2.4.1/scheduler/cupsd.h
--- cups-2.4.1/scheduler/cupsd.h.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/cupsd.h 2022-02-07 08:14:29.586878172 +0100
@@ -8,6 +8,8 @@
diff -up cups-2.4.8/scheduler/cupsd.h.lspp cups-2.4.8/scheduler/cupsd.h
--- cups-2.4.8/scheduler/cupsd.h.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/cupsd.h 2024-05-14 13:15:22.459678912 +0200
@@ -9,6 +9,8 @@
* information.
*/
@ -795,7 +795,7 @@ diff -up cups-2.4.1/scheduler/cupsd.h.lspp cups-2.4.1/scheduler/cupsd.h
/*
* Include necessary headers.
@@ -33,6 +35,14 @@
@@ -34,6 +36,14 @@
# include <unistd.h>
#endif /* _WIN32 */
@ -810,9 +810,9 @@ diff -up cups-2.4.1/scheduler/cupsd.h.lspp cups-2.4.1/scheduler/cupsd.h
#include "mime.h"
#if defined(HAVE_CDSASSL)
diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
--- cups-2.4.1/scheduler/ipp.c.lspp 2022-02-07 08:14:29.559878397 +0100
+++ cups-2.4.1/scheduler/ipp.c 2022-02-07 08:14:29.588878156 +0100
diff -up cups-2.4.8/scheduler/ipp.c.lspp cups-2.4.8/scheduler/ipp.c
--- cups-2.4.8/scheduler/ipp.c.lspp 2024-05-14 13:15:22.447678849 +0200
+++ cups-2.4.8/scheduler/ipp.c 2024-05-14 13:15:22.460678917 +0200
@@ -12,6 +12,9 @@
* information.
*/
@ -848,7 +848,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
static int check_quotas(cupsd_client_t *con, cupsd_printer_t *p);
static void close_job(cupsd_client_t *con, ipp_attribute_t *uri);
static void copy_attrs(ipp_t *to, ipp_t *from, cups_array_t *ra,
@@ -1242,6 +1256,21 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1188,6 +1202,21 @@ add_job(cupsd_client_t *con, /* I - Cl
"time-at-creation",
"time-at-processing"
};
@ -870,7 +870,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
cupsdLogMessage(CUPSD_LOG_DEBUG2, "add_job(%p[%d], %p(%s), %p(%s/%s))",
@@ -1570,6 +1599,106 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1516,6 +1545,106 @@ add_job(cupsd_client_t *con, /* I - Cl
attr = ippFindAttribute(con->request, "requesting-user-name", IPP_TAG_NAME);
@ -977,7 +977,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
if ((job = cupsdAddJob(priority, printer->name)) == NULL)
{
send_ipp_status(con, IPP_INTERNAL_ERROR,
@@ -1578,6 +1707,32 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1524,6 +1653,32 @@ add_job(cupsd_client_t *con, /* I - Cl
return (NULL);
}
@ -1010,7 +1010,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
job->dtype = printer->type & (CUPS_PRINTER_CLASS | CUPS_PRINTER_REMOTE);
job->attrs = con->request;
job->dirty = 1;
@@ -1765,6 +1920,29 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1711,6 +1866,29 @@ add_job(cupsd_client_t *con, /* I - Cl
ippSetString(job->attrs, &attr, 0, printer->job_sheets[0]);
ippSetString(job->attrs, &attr, 1, printer->job_sheets[1]);
}
@ -1040,7 +1040,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
job->job_sheets = attr;
@@ -1795,6 +1973,9 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1741,6 +1919,9 @@ add_job(cupsd_client_t *con, /* I - Cl
"job-sheets=\"%s,none\", "
"job-originating-user-name=\"%s\"",
Classification, job->username);
@ -1050,7 +1050,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
}
else if (attr->num_values == 2 &&
strcmp(attr->values[0].string.text,
@@ -1813,6 +1994,9 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1759,6 +1940,9 @@ add_job(cupsd_client_t *con, /* I - Cl
"job-originating-user-name=\"%s\"",
attr->values[0].string.text,
attr->values[1].string.text, job->username);
@ -1060,7 +1060,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
}
else if (strcmp(attr->values[0].string.text, Classification) &&
strcmp(attr->values[0].string.text, "none") &&
@@ -1833,6 +2017,9 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1779,6 +1963,9 @@ add_job(cupsd_client_t *con, /* I - Cl
"job-originating-user-name=\"%s\"",
attr->values[0].string.text,
attr->values[1].string.text, job->username);
@ -1070,7 +1070,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
}
}
else if (strcmp(attr->values[0].string.text, Classification) &&
@@ -1873,8 +2060,52 @@ add_job(cupsd_client_t *con, /* I - Cl
@@ -1819,8 +2006,52 @@ add_job(cupsd_client_t *con, /* I - Cl
"job-sheets=\"%s\", "
"job-originating-user-name=\"%s\"",
Classification, job->username);
@ -1123,7 +1123,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
/*
* See if we need to add the starting sheet...
@@ -3664,6 +3895,128 @@ check_rss_recipient(
@@ -3647,6 +3878,128 @@ check_rss_recipient(
}
@ -1252,7 +1252,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
/*
* 'check_quotas()' - Check quotas for a printer and user.
*/
@@ -4119,6 +4472,15 @@ copy_banner(cupsd_client_t *con, /* I -
@@ -4102,6 +4455,15 @@ copy_banner(cupsd_client_t *con, /* I -
char attrname[255], /* Name of attribute */
*s; /* Pointer into name */
ipp_attribute_t *attr; /* Attribute */
@ -1268,7 +1268,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
cupsdLogMessage(CUPSD_LOG_DEBUG2,
@@ -4154,6 +4516,85 @@ copy_banner(cupsd_client_t *con, /* I -
@@ -4137,6 +4499,85 @@ copy_banner(cupsd_client_t *con, /* I -
fchmod(cupsFileNumber(out), 0640);
fchown(cupsFileNumber(out), RunUser, Group);
@ -1354,7 +1354,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
/*
* Try the localized banner file under the subdirectory...
@@ -4248,6 +4689,24 @@ copy_banner(cupsd_client_t *con, /* I -
@@ -4231,6 +4672,24 @@ copy_banner(cupsd_client_t *con, /* I -
else
s = attrname;
@ -1379,7 +1379,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
if (!strcmp(s, "printer-name"))
{
cupsFilePuts(out, job->dest);
@@ -6475,6 +6934,22 @@ get_job_attrs(cupsd_client_t *con, /* I
@@ -6681,6 +7140,22 @@ get_job_attrs(cupsd_client_t *con, /* I
exclude = cupsdGetPrivateAttrs(policy, con, printer, job->username);
@ -1402,7 +1402,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
/*
* Copy attributes...
*/
@@ -6873,6 +7348,11 @@ get_jobs(cupsd_client_t *con, /* I - C
@@ -7079,6 +7554,11 @@ get_jobs(cupsd_client_t *con, /* I - C
if (username[0] && _cups_strcasecmp(username, job->username))
continue;
@ -1414,7 +1414,7 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
if (count > 0)
ippAddSeparator(con->response);
@@ -11474,6 +11954,11 @@ validate_user(cupsd_job_t *job, /* I
@@ -11810,6 +12290,11 @@ validate_user(cupsd_job_t *job, /* I
strlcpy(username, get_username(con), userlen);
@ -1426,9 +1426,9 @@ diff -up cups-2.4.1/scheduler/ipp.c.lspp cups-2.4.1/scheduler/ipp.c
/*
* Check the username against the owner...
*/
diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
--- cups-2.4.1/scheduler/job.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/job.c 2022-02-07 08:15:43.118252372 +0100
diff -up cups-2.4.8/scheduler/job.c.lspp cups-2.4.8/scheduler/job.c
--- cups-2.4.8/scheduler/job.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/job.c 2024-05-14 13:16:41.100084985 +0200
@@ -9,6 +9,9 @@
* information.
*/
@ -1469,7 +1469,7 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
cupsdLogMessage(CUPSD_LOG_DEBUG2,
@@ -1063,6 +1082,67 @@ cupsdContinueJob(cupsd_job_t *job) /* I
@@ -1070,6 +1089,67 @@ cupsdContinueJob(cupsd_job_t *job) /* I
if (final_content_type[0])
envp[envc ++] = final_content_type;
@ -1537,8 +1537,8 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
if (Classification && !banner_page)
{
if ((attr = ippFindAttribute(job->attrs, "job-sheets",
@@ -1841,6 +1921,22 @@ cupsdLoadJob(cupsd_job_t *job) /* I - J
ippSetString(job->attrs, &job->reasons, 0, "none");
@@ -1856,6 +1936,22 @@ cupsdLoadJob(cupsd_job_t *job) /* I - J
ippSetString(job->attrs, &job->reasons, 0, "job-completed-successfully");
}
+#ifdef WITH_LSPP
@ -1560,7 +1560,7 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
job->impressions = ippFindAttribute(job->attrs, "job-impressions-completed", IPP_TAG_INTEGER);
job->sheets = ippFindAttribute(job->attrs, "job-media-sheets-completed", IPP_TAG_INTEGER);
job->job_sheets = ippFindAttribute(job->attrs, "job-sheets", IPP_TAG_NAME);
@@ -2249,6 +2345,14 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J
@@ -2268,6 +2364,14 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J
{
char filename[1024]; /* Job control filename */
cups_file_t *fp; /* Job file */
@ -1575,7 +1575,7 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdSaveJob(job=%p(%d)): job->attrs=%p",
@@ -2271,6 +2375,78 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J
@@ -2290,6 +2394,78 @@ cupsdSaveJob(cupsd_job_t *job) /* I - J
fchown(cupsFileNumber(fp), RunUser, Group);
@ -1654,7 +1654,7 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
job->attrs->state = IPP_IDLE;
if (ippWriteIO(fp, (ipp_iocb_t)cupsFileWrite, 1, NULL,
@@ -3970,6 +4146,19 @@ get_options(cupsd_job_t *job, /* I - Jo
@@ -4020,6 +4196,19 @@ get_options(cupsd_job_t *job, /* I - Jo
banner_page)
continue;
@ -1674,7 +1674,7 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
/*
* Otherwise add them to the list...
*/
@@ -4780,6 +4969,18 @@ start_job(cupsd_job_t *job, /* I -
@@ -4834,6 +5023,18 @@ start_job(cupsd_job_t *job, /* I -
cupsd_printer_t *printer) /* I - Printer to print job */
{
const char *filename; /* Support filename */
@ -1693,7 +1693,7 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
ipp_attribute_t *cancel_after = ippFindAttribute(job->attrs,
"job-cancel-after",
IPP_TAG_INTEGER);
@@ -4968,6 +5169,113 @@ start_job(cupsd_job_t *job, /* I -
@@ -5022,6 +5223,113 @@ start_job(cupsd_job_t *job, /* I -
fcntl(job->side_pipes[1], F_SETFD,
fcntl(job->side_pipes[1], F_GETFD) | FD_CLOEXEC);
@ -1807,10 +1807,10 @@ diff -up cups-2.4.1/scheduler/job.c.lspp cups-2.4.1/scheduler/job.c
/*
* Now start the first file in the job...
*/
diff -up cups-2.4.1/scheduler/job.h.lspp cups-2.4.1/scheduler/job.h
--- cups-2.4.1/scheduler/job.h.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/job.h 2022-02-07 08:14:29.590878139 +0100
@@ -7,6 +7,13 @@
diff -up cups-2.4.8/scheduler/job.h.lspp cups-2.4.8/scheduler/job.h
--- cups-2.4.8/scheduler/job.h.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/job.h 2024-05-14 13:15:22.461678922 +0200
@@ -8,6 +8,13 @@
* Licensed under Apache License v2.0. See the file "LICENSE" for more information.
*/
@ -1824,7 +1824,7 @@ diff -up cups-2.4.1/scheduler/job.h.lspp cups-2.4.1/scheduler/job.h
/*
* Constants...
*/
@@ -84,6 +91,10 @@ struct cupsd_job_s /**** Job request *
@@ -85,6 +92,10 @@ struct cupsd_job_s /**** Job request *
int progress; /* Printing progress */
int num_keywords; /* Number of PPD keywords */
cups_option_t *keywords; /* PPD keywords */
@ -1835,9 +1835,9 @@ diff -up cups-2.4.1/scheduler/job.h.lspp cups-2.4.1/scheduler/job.h
};
typedef struct cupsd_joblog_s /**** Job log message ****/
diff -up cups-2.4.1/scheduler/main.c.lspp cups-2.4.1/scheduler/main.c
--- cups-2.4.1/scheduler/main.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/main.c 2022-02-07 08:14:29.590878139 +0100
diff -up cups-2.4.8/scheduler/main.c.lspp cups-2.4.8/scheduler/main.c
--- cups-2.4.8/scheduler/main.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/main.c 2024-05-14 13:15:22.461678922 +0200
@@ -58,6 +58,9 @@
# include <sys/param.h>
#endif /* HAVE_SYS_PARAM_H */
@ -1896,9 +1896,9 @@ diff -up cups-2.4.1/scheduler/main.c.lspp cups-2.4.1/scheduler/main.c
return (!stop_scheduler);
}
diff -up cups-2.4.1/scheduler/printers.c.lspp cups-2.4.1/scheduler/printers.c
--- cups-2.4.1/scheduler/printers.c.lspp 2022-01-27 12:11:42.000000000 +0100
+++ cups-2.4.1/scheduler/printers.c 2022-02-07 08:14:29.591878131 +0100
diff -up cups-2.4.8/scheduler/printers.c.lspp cups-2.4.8/scheduler/printers.c
--- cups-2.4.8/scheduler/printers.c.lspp 2024-04-26 13:38:21.000000000 +0200
+++ cups-2.4.8/scheduler/printers.c 2024-05-14 13:15:22.462678928 +0200
@@ -9,6 +9,8 @@
* information.
*/
@ -1919,7 +1919,7 @@ diff -up cups-2.4.1/scheduler/printers.c.lspp cups-2.4.1/scheduler/printers.c
/*
* Local functions...
@@ -2281,6 +2287,13 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p)
@@ -2184,6 +2190,13 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p)
ipp_attribute_t *attr; /* Attribute data */
char *name, /* Current user/group name */
*filter; /* Current filter */
@ -1933,7 +1933,7 @@ diff -up cups-2.4.1/scheduler/printers.c.lspp cups-2.4.1/scheduler/printers.c
/*
@@ -2405,6 +2418,45 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p)
@@ -2309,6 +2322,45 @@ cupsdSetPrinterAttrs(cupsd_printer_t *p)
attr->values[1].string.text = _cupsStrAlloc(Classification ?
Classification : p->job_sheets[1]);
}

View File

@ -1,38 +0,0 @@
diff -up cups-1.5b1/conf/cups.password-auth.system-auth cups-1.5b1/conf/cups.password-auth
--- cups-1.5b1/conf/cups.password-auth.system-auth 2011-05-23 17:27:27.000000000 +0200
+++ cups-1.5b1/conf/cups.password-auth 2011-05-23 17:27:27.000000000 +0200
@@ -0,0 +1,4 @@
+#%PAM-1.0
+# Use password-auth common PAM configuration for the daemon
+auth include password-auth
+account include password-auth
diff -up cups-1.5b1/conf/cups.system-auth.system-auth cups-1.5b1/conf/cups.system-auth
--- cups-1.5b1/conf/cups.system-auth.system-auth 2011-05-23 17:27:27.000000000 +0200
+++ cups-1.5b1/conf/cups.system-auth 2011-05-23 17:27:27.000000000 +0200
@@ -0,0 +1,3 @@
+#%PAM-1.0
+auth include system-auth
+account include system-auth
diff -up cups-1.5b1/conf/Makefile.system-auth cups-1.5b1/conf/Makefile
--- cups-1.5b1/conf/Makefile.system-auth 2011-05-12 07:21:56.000000000 +0200
+++ cups-1.5b1/conf/Makefile 2011-05-23 17:27:27.000000000 +0200
@@ -90,10 +90,16 @@ install-data:
done
-if test x$(PAMDIR) != x; then \
$(INSTALL_DIR) -m 755 $(BUILDROOT)$(PAMDIR); \
- if test -r $(BUILDROOT)$(PAMDIR)/cups ; then \
- $(INSTALL_DATA) $(PAMFILE) $(BUILDROOT)$(PAMDIR)/cups.N ; \
+ if test -f /etc/pam.d/password-auth; then \
+ $(INSTALL_DATA) cups.password-auth $(BUILDROOT)$(PAMDIR)/cups; \
+ elif test -f /etc/pam.d/system-auth; then \
+ $(INSTALL_DATA) cups.system-auth $(BUILDROOT)$(PAMDIR)/cups; \
else \
- $(INSTALL_DATA) $(PAMFILE) $(BUILDROOT)$(PAMDIR)/cups ; \
+ if test -r $(BUILDROOT)$(PAMDIR)/cups ; then \
+ $(INSTALL_DATA) $(PAMFILE) $(BUILDROOT)$(PAMDIR)/cups.N ; \
+ else \
+ $(INSTALL_DATA) $(PAMFILE) $(BUILDROOT)$(PAMDIR)/cups ; \
+ fi ; \
fi ; \
fi

View File

@ -1,18 +0,0 @@
diff --git a/scheduler/job.c b/scheduler/job.c
index 32f2519..6425305 100644
--- a/scheduler/job.c
+++ b/scheduler/job.c
@@ -1500,11 +1500,11 @@ cupsdDeleteJob(cupsd_job_t *job, /* I - Job */
job->num_files = 0;
}
+ unload_job(job);
+
if (job->history)
free_job_history(job);
- unload_job(job);
-
cupsArrayRemove(Jobs, job);
cupsArrayRemove(ActiveJobs, job);
cupsArrayRemove(PrintingJobs, job);

View File

@ -21,8 +21,8 @@
Summary: CUPS printing system
Name: cups
Epoch: 1
Version: 2.4.7
Release: 12%{?dist}
Version: 2.4.9
Release: 1%{?dist}
# backend/failover.c - BSD-3-Clause
# cups/md5* - Zlib
# scheduler/colorman.c - Apache-2.0 WITH LLVM-exception AND BSD-2-Clause
@ -42,40 +42,37 @@ Source2: macros.cups
# remove after Fedora 40 is EOL and C10S is released
Source3: upgrade_get_document.py.in
# PAM enablement, very old patch, not even git can track when or why
# the patch was added.
Patch1: cups-system-auth.patch
# cups-config from devel package conflicted on multilib arches,
# fixed hack with pkg-config calling for gnutls' libdir variable
Patch2: cups-multilib.patch
Patch1: cups-multilib.patch
# if someone makes a change to banner files, then there will <banner>.rpmnew
# with next update of cups-filters - this patch makes sure the banner file
# changed by user is used and .rpmnew or .rpmsave is ignored
# Note: This could be rewrite with use a kind of #define and send to upstream
Patch3: cups-banners.patch
Patch2: cups-banners.patch
# don't export ssl libs to cups-config - can't find the reason.
Patch4: cups-no-export-ssllibs.patch
Patch3: cups-no-export-ssllibs.patch
# enables old uri usb:/dev/usb/lp0 - leave it here for users of old printers
Patch5: cups-direct-usb.patch
Patch4: cups-direct-usb.patch
# when system workload is high, timeout for cups-driverd can be reached -
# increase the timeout
Patch6: cups-driverd-timeout.patch
Patch5: cups-driverd-timeout.patch
# usb backend didn't get any notification about out-of-paper because of kernel
Patch7: cups-usb-paperout.patch
Patch6: cups-usb-paperout.patch
# uri compatibility with old Fedoras
Patch8: cups-uri-compat.patch
Patch7: cups-uri-compat.patch
# use IP_FREEBIND, because cupsd cannot bind to not yet existing IP address
# by default
Patch9: cups-freebind.patch
Patch8: cups-freebind.patch
# add support of multifile
Patch10: cups-ipp-multifile.patch
Patch9: cups-ipp-multifile.patch
# prolongs web ui timeout
Patch11: cups-web-devices-timeout.patch
Patch10: cups-web-devices-timeout.patch
# failover backend for implementing failover functionality
# TODO: move it to the cups-filters upstream
Patch12: cups-failover-backend.patch
Patch11: cups-failover-backend.patch
# add device id for dymo printer
Patch13: cups-dymo-deviceid.patch
Patch12: cups-dymo-deviceid.patch
%if %{lspp}
# selinux and audit enablement for CUPS - needs work and CUPS upstream wants
@ -84,17 +81,6 @@ Patch100: cups-lspp.patch
%endif
#### UPSTREAM PATCHES (starts with 1000) ####
# https://github.com/OpenPrinting/cups/pull/742
# 2218124 - The command "cancel -x <job>" does not remove job files
Patch1001: 0001-Use-purge-job-instead-of-purge-jobs-when-canceling-a.patch
# https://github.com/OpenPrinting/cups/pull/814
Patch1002: cups-colorman-leak.patch
# https://github.com/OpenPrinting/cups/pull/813/
Patch1003: cups-unload-job-leak.patch
# https://github.com/OpenPrinting/cups/pull/839
Patch1004: 0001-httpAddrConnect2-Check-for-error-if-POLLHUP-is-in-va.patch
# https://github.com/OpenPrinting/cups/pull/927
Patch1005: 0001-scheduler-Fix-sending-response-headers-to-client.patch
##### Patches removed because IMHO they aren't no longer needed
@ -297,44 +283,32 @@ to CUPS daemon. This solution will substitute printer drivers and raw queues in
%prep
%setup -q -n cups-%{VERSION}
# Use the system pam configuration.
%patch -P 1 -p1 -b .system-auth
# Prevent multilib conflict in cups-config script.
%patch -P 2 -p1 -b .multilib
%patch -P 1 -p1 -b .multilib
# Ignore rpm save/new files in the banners directory.
%patch -P 3 -p1 -b .banners
%patch -P 2 -p1 -b .banners
# Don't export SSLLIBS to cups-config.
%patch -P 4 -p1 -b .no-export-ssllibs
%patch -P 3 -p1 -b .no-export-ssllibs
# Allow file-based usb device URIs.
%patch -P 5 -p1 -b .direct-usb
%patch -P 4 -p1 -b .direct-usb
# Increase driverd timeout to 70s to accommodate foomatic (bug #744715).
%patch -P 6 -p1 -b .driverd-timeout
%patch -P 5 -p1 -b .driverd-timeout
# Support for errno==ENOSPACE-based USB paper-out reporting.
%patch -P 7 -p1 -b .usb-paperout
%patch -P 6 -p1 -b .usb-paperout
# Allow the usb backend to understand old-style URI formats.
%patch -P 8 -p1 -b .uri-compat
%patch -P 7 -p1 -b .uri-compat
# Use IP_FREEBIND socket option when binding listening sockets (bug #970809).
%patch -P 9 -p1 -b .freebind
%patch -P 8 -p1 -b .freebind
# Fixes for jobs with multiple files and multiple formats.
%patch -P 10 -p1 -b .ipp-multifile
%patch -P 9 -p1 -b .ipp-multifile
# Increase web interface get-devices timeout to 10s (bug #996664).
%patch -P 11 -p1 -b .web-devices-timeout
%patch -P 10 -p1 -b .web-devices-timeout
# Add failover backend (bug #1689209)
%patch -P 12 -p1 -b .failover
%patch -P 11 -p1 -b .failover
# Added IEEE 1284 Device ID for a Dymo device (bug #747866).
%patch -P 13 -p1 -b .dymo-deviceid
%patch -P 12 -p1 -b .dymo-deviceid
# UPSTREAM PATCHES
# 2218124 - The command "cancel -x <job>" does not remove job files
%patch -P 1001 -p1 -b .purge-job
# https://github.com/OpenPrinting/cups/pull/814
%patch -P 1002 -p1 -b .colorman
# https://github.com/OpenPrinting/cups/pull/813/
%patch -P 1003 -p1 -b .unloadjob
# https://github.com/OpenPrinting/cups/pull/839
%patch -P 1004 -p1 -b .httpaddrconnect-pollhup
# https://github.com/OpenPrinting/cups/pull/927
%patch -P 1005 -p1 -b .sent-headers
%if %{lspp}
@ -809,6 +783,10 @@ rm -f %{cups_serverbin}/backend/smb
%{_mandir}/man7/ippeveps.7.gz
%changelog
* Wed Jun 12 2024 Pavol Zacik <pzacik@redhat.com> - 1:2.4.9-1
- CVE-2024-35235 cups: Cupsd Listen arbitrary chmod 0140777
- RHEL-25804 Rebase CUPS to next upstream version - 2.4.9
* Tue May 07 2024 Zdenek Dohnal <zdohnal@redhat.com> - 1:2.4.7-12
- RHEL-35695 Remove additional license tags

View File

@ -1 +1 @@
SHA512 (cups-2.4.7-source.tar.gz) = 914b574ff6d85de9f3471528b52d4a436c484c441f47651846e1bdfa00aec26774efd416ff466216d2bccf468f8a797b1e0d666b5c82abc87e77550ce8b00d39
SHA512 (cups-2.4.9-source.tar.gz) = c37eb3820a78d070eebe501166339dc693f19b3285774f9d126a6e6d98d6d68feabe68ec3cfbe5afadc86c2cb4feade617ceb3d391c73b0c20fbf292b509cd86