]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Kerberos credentials could get truncated when printing to a shared printer.
authormsweet <msweet@7a7537e8-13f0-0310-91df-b6672ffda945>
Fri, 26 Apr 2013 16:18:20 +0000 (16:18 +0000)
committermsweet <msweet@7a7537e8-13f0-0310-91df-b6672ffda945>
Fri, 26 Apr 2013 16:18:20 +0000 (16:18 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@10963 7a7537e8-13f0-0310-91df-b6672ffda945

13 files changed:
CHANGES-1.6.txt
doc/help/man-client.conf.html
doc/help/man-cups-deviced.html
doc/help/man-cups-driverd.html
doc/help/man-cups-files.conf.html
doc/help/man-cups-lpd.html
doc/help/man-cups-snmp.html
doc/help/man-cupsd.conf.html
doc/help/man-cupsd.html
doc/help/man-lpoptions.html
scheduler/ipp.c
scheduler/job.c
scheduler/main.c

index 7a409a845200f30d5834fc7f0f3ca9191f056801..3ab641b19c2a6bf854f791d588cb66d6666ee610 100644 (file)
@@ -5,6 +5,8 @@ CHANGES IN CUPS V1.6.3
 
        - The configure script now prefers Clang over GCC.
        - Fixed a compile problem on AIX (STR #4307)
+       - Kerberos credentials could get truncated when printing to a shared
+         printer.
        - Printing using "ipps" URIs was not encrypted.
        - Insecure ICC profiles prevented installation of user profiles for a
          printer on OS X.
index ee9324460df9c52f40f3a3817f2da0ed82b6ba74..dfcac80f6ebb7ec6b88ad037420b57279b4361a6 100644 (file)
@@ -11,7 +11,7 @@
 client.conf - client configuration file for cups
 <h2 class="title"><a name="DESCRIPTION">Description</a></h2>
 The <i>client.conf</i> file configures the CUPS client and is
-normally located in the <i>/etc/cups</i> or <i>~/.cups</i>
+normally located in the <i>/private/etc/cups</i> or <i>~/.cups</i>
 directory. Each line in the file can be a configuration
 directive, a blank line, or a comment. Comment lines start with
 the # character.
index 1940f642d24a952b961426e33df4febdcc445b7e..a64b7a707794fa46dcbc911804b480d5a07578e2 100644 (file)
@@ -14,7 +14,7 @@ cups-deviced - cups device daemon
 </b><i>request-id limit user-id options
 </i><h2 class="title"><a name="DESCRIPTION">Description</a></h2>
 <i>cups-deviced</i> polls the backends in
-<i>/usr/lib/cups/backend</i> for a list of available devices.
+<i>/usr/libexec/cups/backend</i> for a list of available devices.
 It is run by <a href='man-cupsd.html?TOPIC=Man+Pages'>cupsd(8)</a> in response to a
 <i>CUPS-Get-Devices</i> request. The output format is an IPP
 response message. The <i>request-id</i> argument is the request ID
index e161435b6f5ce4b0d6e87d67c78842d7d4a25083..1fe85727225a75ab96fc38dff91fd84a74d51403 100644 (file)
@@ -36,7 +36,7 @@ accordingly.
 <h2 class="title"><a name="DRIVERS">Drivers</a></h2>
 Drivers can be static PPD files under the
 <i>/usr/share/cups/model</i> directory or programs under the
-<i>/usr/lib/cups/driver</i> directory. Static PPD files must
+<i>/usr/libexec/cups/driver</i> directory. Static PPD files must
 conform to the Adobe PPD File Format Specification version 4.3
 and may be compressed using the <i>gzip(1)</i> program. Driver
 programs must implement the command-line interface shown in the
index 8c3a610fd4449f14da44aa49a4aeb4bf8571d828..2d686e9e2cd2a0c655a57be084a4042b6693812e 100644 (file)
@@ -12,7 +12,7 @@ cups-files.conf - file and directory configuration file for cups
 <h2 class="title"><a name="DESCRIPTION">Description</a></h2>
 The <i>cups-files.conf</i> file configures the files and directories used by the
 CUPS scheduler, <a href='man-cupsd.html?TOPIC=Man+Pages'>cupsd(8)</a>.  It is normally located in the
-<i>/etc/cups</i> directory.
+<i>/private/etc/cups</i> directory.
 <p>Each line in the file can be a configuration directive, a blank line,
 or a comment. Comment lines start with the # character.
 <h2 class="title"><a name="DIRECTIVES">Directives</a></h2>
index fc891605ab6a20e19432fb3a063575a90b8a5ac7..69f098db4bd079fee3b27211239d21f2811e4a62 100644 (file)
@@ -27,7 +27,7 @@ add the following line to the <i>inetd.conf</i> file to enable the
 <br>
 <pre>
 
-    printer stream tcp nowait lp /usr/lib/cups/daemon/cups-lpd cups-lpd \
+    printer stream tcp nowait lp /usr/libexec/cups/daemon/cups-lpd cups-lpd \
         -o document-format=application/octet-stream
 </pre>
 <p><p><b>Note:</b> If you are using Solaris 10 or higher, you must run
@@ -46,7 +46,7 @@ named <i>/etc/xinetd.d/cups</i> containing the following lines:
         user = lp
        group = sys
        passenv =
-        server = /usr/lib/cups/daemon/cups-lpd
+        server = /usr/libexec/cups/daemon/cups-lpd
        server_args = -o document-format=application/octet-stream
     }
 </pre>
index 9b80a8f7f982ddefc88ff279cce465ffd38ff9f1..c354a6206b3db0a6c1506f355235652e198200f1 100644 (file)
@@ -10,7 +10,7 @@
 <h2 class="title"><a name="NAME">Name</a></h2>
 snmp - cups snmp backend
 <h2 class="title"><a name="SYNOPSIS">Synopsis</a></h2>
-<b>/usr/lib/cups/backend/snmp
+<b>/usr/libexec/cups/backend/snmp
 </b><i>ip-address-or-hostname
 </i><br>
 <b>lpinfo -v --include-schemes snmp
@@ -34,7 +34,7 @@ The CUPS SNMP backend uses the information from the Host, Printer, and Port
 Monitor MIBs along with some vendor private MIBs and intelligent port probes to
 determine the correct device URI and make and model for each printer.
 <h2 class="title"><a name="CONFIGURATION">Configuration</a></h2>
-The SNMP backend reads the /etc/cups/snmp.conf configuration file, if
+The SNMP backend reads the /private/etc/cups/snmp.conf configuration file, if
 present, to set the default broadcast address, community name, and logging
 level. The configuration file is documented in <a href='man-cups-snmp.conf.html?TOPIC=Man+Pages'>cups-snmp.conf(5)</a>. The
 DebugLevel value can be overridden using the CUPS_DEBUG_LEVEL environment
index 995fda2dcf74a0973e40b1b00ef08078bb092c06..032b8db87261206bb364bebec5af83f13f8d9718 100644 (file)
@@ -11,7 +11,7 @@
 cupsd.conf - server configuration file for cups
 <h2 class="title"><a name="DESCRIPTION">Description</a></h2>
 The <i>cupsd.conf</i> file configures the CUPS scheduler, <a href='man-cupsd.html?TOPIC=Man+Pages'>cupsd(8)</a>.  It
-is normally located in the <i>/etc/cups</i> directory. <b>Note:</b>
+is normally located in the <i>/private/etc/cups</i> directory. <b>Note:</b>
 File, directory, and user configuration directives that used to be allowed in
 the <i>cupsd.conf</i> file are now stored in the <a href='man-cups-files.conf.html?TOPIC=Man+Pages'>cups-files.conf(5)</a> instead
 in order to prevent certain types of privilege escalation attacks.
index b292cba208da054d3d1d2f68fffaa7a755d5c5c0..6df5475fc5b409bc955cdac1309d696c82740cef 100644 (file)
@@ -18,7 +18,7 @@ cupsd - cups scheduler
 <i>cupsd</i> is the scheduler for CUPS. It implements a printing system based
 upon the Internet Printing Protocol, version 2.1.  If no options are specified
 on the command-line then the default configuration file
-<i>/etc/cups/cupsd.conf</i> will be used.
+<i>/private/etc/cups/cupsd.conf</i> will be used.
 <h2 class="title"><a name="OPTIONS">Options</a></h2>
 <dl>
 <dt>-c config-file
index c5c2fa7ca76f8fd4dff20d17b29010cdf5ba422a..c342652cc07a8f04aec81d4082a6f0382e6e721a 100644 (file)
@@ -118,14 +118,14 @@ standard output.
 <h2 class="title"><a name="ROOT_ACCOUNT_OPTIONS">Root Account Options</a></h2>
 When run by the root user, <i>lpoptions</i> gets and sets default
 options and instances for <i>all users</i> in the
-/etc/cups/lpoptions file.
+/private/etc/cups/lpoptions file.
 <h2 class="title"><a name="COMPATIBILITY">Compatibility</a></h2>
 The <i>lpoptions</i> command is unique to CUPS.
 <h2 class="title"><a name="FILES">Files</a></h2>
 ~/.cups/lpoptions - user defaults and instances created by non-root
 users.
 <br>
-/etc/cups/lpoptions - system-wide defaults and instances
+/private/etc/cups/lpoptions - system-wide defaults and instances
 created by the root user.
 <h2 class="title"><a name="SEE_ALSO">See Also</a></h2>
 <a href='man-cancel.html?TOPIC=Man+Pages'>cancel(1)</a>, <a href='man-lp.html?TOPIC=Man+Pages'>lp(1)</a>, <a href='man-lpadmin.html?TOPIC=Man+Pages'>lpadmin(8)</a>, <a href='man-lpr.html?TOPIC=Man+Pages'>lpr(1)</a>,
index 60232325f53dc25a339baa08549b4a9098579f9b..83041d64b3a222759cc988a55d20aa4e5a8073f6 100644 (file)
@@ -9043,7 +9043,7 @@ save_auth_info(
   fchown(cupsFileNumber(fp), 0, 0);
   fchmod(cupsFileNumber(fp), 0400);
 
-  cupsFilePuts(fp, "CUPSD-AUTH-V2\n");
+  cupsFilePuts(fp, "CUPSD-AUTH-V3\n");
 
   for (i = 0;
        i < (int)(sizeof(job->auth_env) / sizeof(job->auth_env[0]));
@@ -9061,9 +9061,15 @@ save_auth_info(
             i < (int)(sizeof(job->auth_env) / sizeof(job->auth_env[0]));
         i ++)
     {
-      httpEncode64_2(line, sizeof(line), auth_info->values[i].string.text,
-                     strlen(auth_info->values[i].string.text));
-      cupsFilePutConf(fp, dest->auth_info_required[i], line);
+      if (strcmp(dest->auth_info_required[i], "negotiate"))
+      {
+       httpEncode64_2(line, sizeof(line), auth_info->values[i].string.text,
+                      strlen(auth_info->values[i].string.text));
+       cupsFilePutConf(fp, dest->auth_info_required[i], line);
+      }
+      else
+       cupsFilePutConf(fp, dest->auth_info_required[i],
+                       auth_info->values[i].string.text);
 
       if (!strcmp(dest->auth_info_required[i], "username"))
         cupsdSetStringf(job->auth_env + i, "AUTH_USERNAME=%s",
index b013b674f5cc100972cfb42919a3f8124031f83e..3e17ba9e29ca988adefde980c278916e81973e48 100644 (file)
@@ -1956,7 +1956,7 @@ cupsdLoadJob(cupsd_job_t *job)            /* I - Job */
 
 
       if (cupsFileGets(fp, line, sizeof(line)) &&
-          !strcmp(line, "CUPSD-AUTH-V2"))
+          !strcmp(line, "CUPSD-AUTH-V3"))
       {
         i = 0;
         while (cupsFileGetConf(fp, line, sizeof(line), &value, &linenum))
@@ -1965,8 +1965,11 @@ cupsdLoadJob(cupsd_job_t *job)           /* I - Job */
           * Decode value...
           */
 
-         bytes = sizeof(data);
-         httpDecode64_2(data, &bytes, value);
+          if (strcmp(line, "negotiate") && strcmp(line, "uid"))
+          {
+           bytes = sizeof(data);
+           httpDecode64_2(data, &bytes, value);
+         }
 
          /*
           * Assign environment variables...
@@ -1987,7 +1990,7 @@ cupsdLoadJob(cupsd_job_t *job)            /* I - Job */
          else if (!strcmp(line, "password"))
            cupsdSetStringf(job->auth_env + i, "AUTH_PASSWORD=%s", data);
          else if (!strcmp(line, "negotiate"))
-           cupsdSetStringf(job->auth_env + i, "AUTH_NEGOTIATE=%s", data);
+           cupsdSetStringf(job->auth_env + i, "AUTH_NEGOTIATE=%s", value);
          else
            continue;
 
index e6583680ddc6c96ab06f3d59394f00d1d0ce157f..5a8da815e5a99ef22127ea7106d69b0c182fc886 100644 (file)
@@ -1285,7 +1285,7 @@ cupsdSetStringf(char       **s,           /* O - New string */
                 const char *f,         /* I - Printf-style format string */
                ...)                    /* I - Additional args as needed */
 {
-  char         v[4096];                /* Formatting string value */
+  char         v[65536 + 64];          /* Formatting string value */
   va_list      ap;                     /* Argument pointer */
   char         *olds;                  /* Old string */