RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1430882 - The -h option is overridden by _cupsSetDefaults settings when the IPP port is not given
Summary: The -h option is overridden by _cupsSetDefaults settings when the IPP port is...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: cups
Version: 7.3
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Zdenek Dohnal
QA Contact: Petr Sklenar
URL:
Whiteboard:
Depends On:
Blocks: 1420851 1465887 1465928
TreeView+ depends on / blocked
 
Reported: 2017-03-09 18:52 UTC by Bryan Mason
Modified: 2021-06-10 12:02 UTC (History)
3 users (show)

Fixed In Version: cups-1.6.3-31.el7
Doc Type: No Doc Update
Doc Text:
undefined
Clone Of:
Environment:
Last Closed: 2018-04-10 13:41:08 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Possible patch adapted from upstream (1.77 KB, patch)
2017-03-09 18:52 UTC, Bryan Mason
no flags Details | Diff
Proposed patch (954 bytes, patch)
2017-09-22 12:42 UTC, Zdenek Dohnal
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
CUPS Bugs and Features 4675 0 None None None 2017-03-09 18:52:22 UTC
Red Hat Product Errata RHBA-2018:0782 0 None None None 2018-04-10 13:42:14 UTC

Description Bryan Mason 2017-03-09 18:52:23 UTC
Created attachment 1261676 [details]
Possible patch adapted from upstream

Description of problem:

  The "-h" option to "lp*" commands (like lpstat) is ignored if
  ServerName is set in client.conf and the port isn't specified in the
  argument to the "-h" option.


Version-Release number of selected component (if applicable):

  cups-1.6.3-26

How reproducible:

  100%

Steps to Reproduce:

  1. Set "ServerName <some-host>" in /etc/cups/client.conf
  2. run "lpstat -h <another-host> -p"

Actual results:

  The printer list from <another-host>.

Expected results:

  The printer list from <some-host>.

Additional info:

  # cat /etc/cups/client.conf 
  # Empty

  # lpstat -a
  lpstat: No destinations added.

  # lpstat -h rhel73-test -p
  printer pass is idle.  enabled since Thu 09 Mar 2017 10:30:04 AM PST

  # lpstat -h rhel68-test -p
  printer fail is idle.  enabled since Thu 09 Mar 2017 10:31:18 AM PST

  # echo "ServerName rhel68-test" > /etc/cups/client.conf 
  # cat /etc/cups/client.conf
  ServerName rhel68-test

  # lpstat -h rhel73-test -p
  printer fail is idle.  enabled since Thu 09 Mar 2017 10:31:18 AM PST

  # lpstat -h rhel73-test:631 -p
  printer pass is idle.  enabled since Thu 09 Mar 2017 10:30:04 AM PST

  This is the same as cups.org STR #4675 which was resolved with
  https://github.com/apple/cups/commit/4b9daaf451a59d1eb1c99aac32d4e3cb19416397

  I've adapted that patch for RHEL 7.3 and attached.
  The patch fixes the issue in my testing:

  [root@sf01799390 cupsrpms]# yum update *.rpm
  ...
  Updated:
    cups.x86_64 1:1.6.3-26.el7_3.sf01799390.1
    cups-client.x86_64 1:1.6.3-26.el7_3.sf01799390.1
    cups-filesystem.noarch 1:1.6.3-26.el7_3.sf01799390.1
    cups-libs.x86_64 1:1.6.3-26.el7_3.sf01799390.1
      
  Complete!

  # lpstat -h rhel73-test -p
  printer pass is idle.  enabled since Thu 09 Mar 2017 10:30:04 AM PST

Comment 6 Zdenek Dohnal 2017-09-22 12:42:13 UTC
Created attachment 1329577 [details]
Proposed patch

Comment 16 errata-xmlrpc 2018-04-10 13:41:08 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:0782


Note You need to log in before you can comment on or make changes to this bug.